-- functionextraction_extract_return_init_5_2 -- | |
package extract | |
func _() string { | |
x := 1 | |
//@mark(exSt5, "if") | |
shouldReturn, returnValue := newFunction(x) | |
if shouldReturn { | |
return returnValue | |
} //@mark(exEn5, "}") | |
x = 2 | |
return "b" | |
//@extractfunc(exSt5, exEn5) | |
} | |
func newFunction(x int) (bool, string) { | |
if x == 0 { | |
x = 3 | |
return true, "a" | |
} | |
return false, "" | |
} | |