Repository navigation
v2.33.1 - Review fixes for 2.33.0
Fixes from a review of 2.33.0.
- Casts as receivers lost their parentheses in generated code.
(x as A).vcame out asx as A.vin Dart, TypeScript and Kotlin, and as
(A) x.vin Java and C#. A compound receiver is now always parenthesized,
which also fixes(a + b).field. v++/--von a bare getter/setter pair was silently lost. It wrote
to a temporary. It now goes through the setter, and with a getter but no
setter it is an error.- A super argument could go to the wrong parameter. This happened when an
initializing formal for an inherited field came first:
B(this.x, super.y)passedxasy. A formal the superclass constructor
has no parameter for is no longer passed to it. - Java, JavaScript, TypeScript:
super(v);as a constructor's first
statement now delegates. It runs on the same instance and replaces the
implicitsuper(), which had been added on top of it and failed with an
error about arguments the program never omitted. Javathis(v);redirects,
and Java constructor overloads are resolved by argument signature. x as int ?? 5didn't parse. The?of??was read as a nullable
type.- JavaScript/TypeScript
x is doublewas true for integers. It is now
false, matching the VM: anintis not adouble. - Java
instanceofon a primitive operand didn't compile. A test against
Integer,Double,NumberorBooleannow boxes the operand:
((Object) (1 + 2)) instanceof Integer. - Less repeated work. The superclass-constructor policy and a missing
bare-getter lookup are now cached instead of being recomputed on every
instantiation or read.