Commit b534eb46 authored by Ian Lance Taylor's avatar Ian Lance Taylor

Don't use fallthrough in a type switch.

R=rsc
http://go/go-review/1018005
parent fb12ad06
...@@ -111,12 +111,10 @@ func (w *World) CompileExpr(e ast.Expr) (Code, os.Error) { ...@@ -111,12 +111,10 @@ func (w *World) CompileExpr(e ast.Expr) (Code, os.Error) {
// nothing // nothing
case *idealFloatType: case *idealFloatType:
// nothing // nothing
case *MultiType: default:
if len(t.Elems) == 0 { if tm, ok := t.(*MultiType); ok && len(tm.Elems) == 0 {
return &stmtCode{w, code{ec.exec}}, nil; return &stmtCode{w, code{ec.exec}}, nil;
} }
fallthrough;
default:
eval = genAssign(ec.t, ec); eval = genAssign(ec.t, ec);
} }
return &exprCode{w, ec, eval}, nil; return &exprCode{w, ec, eval}, nil;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment