Re: Flow scoping

2019-01-04 Thread Remi Forax
> De: "Tagir Valeev" > À: "Brian Goetz" > Cc: "amber-spec-experts" > Envoyé: Vendredi 4 Janvier 2019 15:07:44 > Objet: Re: Flow scoping > Hello! >> This is certainly this intuition that guided us here; it should be possible >> to >> freely refactor >> if (e) >> throw x; >> else { stuff }

Re: Flow scoping

2019-01-04 Thread Tagir Valeev
Hello! > This is certainly this intuition that guided us here; it should be > possible to freely refactor > > if (e) > throw x; > else { stuff } > > to > > if (e) throw x; > stuff; > > and it would be sad if we could not. For the record: I heavily support this. If

Re: Flow scoping

2019-01-04 Thread Doug Lea
On 1/2/19 1:53 PM, Brian Goetz wrote: > The hard ones (and the potentially controversial ones) were the last two — > regarding use _after_ the declaring statement: > > ``` > public void test() { > if (!(a instanceof String v)) > throw new NotAStringException("a"); > if