From 89bb0404106835679d20433d8c2667bfb1868fbd Mon Sep 17 00:00:00 2001 From: sgrekhov Date: Thu, 28 Nov 2024 12:22:21 +0200 Subject: [PATCH] Update example in Static access shorthand proposal --- working/3616 - enum value shorthand/proposal-simple-lrhn.md | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/working/3616 - enum value shorthand/proposal-simple-lrhn.md b/working/3616 - enum value shorthand/proposal-simple-lrhn.md index 63ce8d124..a330be799 100644 --- a/working/3616 - enum value shorthand/proposal-simple-lrhn.md +++ b/working/3616 - enum value shorthand/proposal-simple-lrhn.md @@ -53,7 +53,10 @@ That means you can write things like the following (with the intended meaning as comments, specification to achieve that below): ```dart -Endian littleEndian = .little; // -> Endian.little (enum value) +// -> HttpClientResponseCompressionState.compressed (enum value) +HttpClientResponseCompressionState state = .compressed; + +Endian littleEndian = .little; // -> Endian.little (constant) Endian hostEndian = .host; // -> Endian.host (getter) // -> Endian.little, Endian.big, Endian.host Endian endian = firstWord == 0xFEFF ? .little : firstWord = 0xFFFE ? .big : .host;