| Commit-Queue | +1 |
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
/// The primary constructor of this element.Clarify what it means if this getter returns `null`, e.g.:
```suggestion
/// The primary constructor of this element, or `null` if this element has no
/// primary constructor.
```
void nonLateInstanceField_enter({The name of this method, and its type signature, suggest that it should be called whenever entering a non-late instance field, regardless of whether there are primary constructor parameters. But the call site in `VariableDeclarationResolver.resolve` only calls it if `primaryConstructorParameters` is non-null.
I suggest either:
Or:
List<FormalParameterElementImpl>? primaryConstructorParameters;The name suggests that this value will be non-null whenever there are primary constructor parameters. But the behavior below is that this value will be non-null whenever there are primary constructor parameters *that are in scope*. How about renaming this to `inScopePrimaryConstructorParameters`?
List<FormalParameterElementImpl>? primaryConstructorParameters,The name suggests that this value will be non-null whenever there are primary constructor parameters. But the behavior at the call site is that this value will be non-null whenever there are primary constructor parameters *that are in scope*. How about renaming this to `inScopePrimaryConstructorParameters`?
List<FormalParameterElementImpl>? primaryConstructorParameters;The name suggests that this value will be non-null whenever there are primary constructor parameters. But the behavior below is that this value will be non-null whenever there are primary constructor parameters *that are in scope*. How about renaming this to `inScopePrimaryConstructorParameters`?
List<FormalParameterElementImpl>? primaryConstructorParameters;The name suggests that this value will be non-null whenever there are primary constructor parameters. But the behavior below is that this value will be non-null whenever there are primary constructor parameters *that are in scope*. How about renaming this to `inScopePrimaryConstructorParameters`?
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
Clarify what it means if this getter returns `null`, e.g.:
```suggestion
/// The primary constructor of this element, or `null` if this element has no
/// primary constructor.
```
Done
The name of this method, and its type signature, suggest that it should be called whenever entering a non-late instance field, regardless of whether there are primary constructor parameters. But the call site in `VariableDeclarationResolver.resolve` only calls it if `primaryConstructorParameters` is non-null.
I suggest either:
- Change the name to something that reflects the fact that the methods purpose is to declare primary constructor parameters (e.g. `declarePrimaryConstructorParameters()`),
- Make the `primaryConstructorParameters` argument non-nullable,
- And remove the `if` test on line 330.
Or:
- Remove the `if` test at the call site (line 63 of `variable_declaration_resolver.dart`) so that this method is always called.
Done
List<FormalParameterElementImpl>? primaryConstructorParameters;The name suggests that this value will be non-null whenever there are primary constructor parameters. But the behavior below is that this value will be non-null whenever there are primary constructor parameters *that are in scope*. How about renaming this to `inScopePrimaryConstructorParameters`?
Done
List<FormalParameterElementImpl>? primaryConstructorParameters,The name suggests that this value will be non-null whenever there are primary constructor parameters. But the behavior at the call site is that this value will be non-null whenever there are primary constructor parameters *that are in scope*. How about renaming this to `inScopePrimaryConstructorParameters`?
Done
List<FormalParameterElementImpl>? primaryConstructorParameters;The name suggests that this value will be non-null whenever there are primary constructor parameters. But the behavior below is that this value will be non-null whenever there are primary constructor parameters *that are in scope*. How about renaming this to `inScopePrimaryConstructorParameters`?
Done
List<FormalParameterElementImpl>? primaryConstructorParameters;The name suggests that this value will be non-null whenever there are primary constructor parameters. But the behavior below is that this value will be non-null whenever there are primary constructor parameters *that are in scope*. How about renaming this to `inScopePrimaryConstructorParameters`?
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
| Code-Review | +1 |
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
| Commit-Queue | +2 |
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
DeCo. Use primary initializer scope for field initializers.
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |