From 00d81cee73b0f34f0d5d2e0f8b12a621b95f9561 Mon Sep 17 00:00:00 2001 From: Erik Ernst Date: Wed, 19 Aug 2020 18:33:49 +0200 Subject: [PATCH] Added null-shorting rule to treat selector `!` like other selectors --- accepted/future-releases/nnbd/feature-specification.md | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/accepted/future-releases/nnbd/feature-specification.md b/accepted/future-releases/nnbd/feature-specification.md index 2e4b41093c..77677a52b7 100644 --- a/accepted/future-releases/nnbd/feature-specification.md +++ b/accepted/future-releases/nnbd/feature-specification.md @@ -6,6 +6,9 @@ Status: Draft ## CHANGELOG +2020.08.19 + - Include selector `!` among the null-shorting constructs. + 2020.08.06 - Specify error for uninitialized final instance variable in class with no generative constructors. @@ -1157,6 +1160,8 @@ continuation. - `SHORT[EXP(e1), fn[x] => x[EXP(e2)]]` - If `e1` translates to `F` then `e1[e2]` translates to: - `PASSTHRU[F, fn[x] => x[EXP(e2)]]` +- If `e` translates to `F` then `e!` translates to: + - `PASSTHRU[F, fn[x] => x!]` - The assignment `e1?.f = e2` translates to: - `SHORT[EXP(e1), fn[x] => x.f = EXP(e2)]` - The other assignment operators are handled equivalently.