mirror of
https://github.com/golang/go
synced 2024-11-25 05:27:57 -07:00
Don't use fallthrough in a type switch.
R=rsc http://go/go-review/1018005
This commit is contained in:
parent
fb12ad063e
commit
b534eb462b
@ -111,12 +111,10 @@ func (w *World) CompileExpr(e ast.Expr) (Code, os.Error) {
|
||||
// nothing
|
||||
case *idealFloatType:
|
||||
// nothing
|
||||
case *MultiType:
|
||||
if len(t.Elems) == 0 {
|
||||
default:
|
||||
if tm, ok := t.(*MultiType); ok && len(tm.Elems) == 0 {
|
||||
return &stmtCode{w, code{ec.exec}}, nil;
|
||||
}
|
||||
fallthrough;
|
||||
default:
|
||||
eval = genAssign(ec.t, ec);
|
||||
}
|
||||
return &exprCode{w, ec, eval}, nil;
|
||||
|
Loading…
Reference in New Issue
Block a user