Commit cae604f7 authored by Russ Cox's avatar Russ Cox

cmd/gc: must not inline panic, recover

R=lvd, gri
CC=golang-dev
https://golang.org/cl/5731061
parent 5ab9d2be
......@@ -182,6 +182,8 @@ ishairy(Node *n, int *budget)
case OCALLFUNC:
case OCALLINTER:
case OCALLMETH:
case OPANIC:
case ORECOVER:
if(debug['l'] < 4)
return 1;
break;
......
......@@ -31,3 +31,9 @@ func f1() {
}
f()
}
func f2() {} // ERROR "can inline f2"
// No inline for panic, recover.
func f3() { panic(1) }
func f4() { recover() }
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