Skip to content

Commit 05b5883

Browse files
johnniwinthercommit-bot@chromium.org
authored andcommitted
[cfe] Add documentation to some Generator implementations
Change-Id: I0a57b08da639557376b1b6f666d2d8aa6344f59c Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/109711 Reviewed-by: Dan Rubel <[email protected]>
1 parent c9c0f56 commit 05b5883

File tree

2 files changed

+213
-31
lines changed

2 files changed

+213
-31
lines changed

pkg/front_end/lib/src/fasta/kernel/body_builder.dart

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -208,6 +208,18 @@ abstract class BodyBuilder extends ScopeListener<JumpTarget>
208208
/// second in the formal parameter scope.
209209
bool inInitializer = false;
210210

211+
/// Set to `true` when we are parsing a field initializer either directly
212+
/// or within an initializer list.
213+
///
214+
/// For instance in `<init>` in
215+
///
216+
/// var foo = <init>;
217+
/// class Class {
218+
/// var bar = <init>;
219+
/// Class() : <init>;
220+
/// }
221+
///
222+
/// This is used to determine whether instance properties are available.
211223
bool inFieldInitializer = false;
212224

213225
bool inCatchClause = false;

0 commit comments

Comments
 (0)