| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
The analyzer produces this diagnostic when the declaration of an instance
method named `factory` will be interpreted as a constructor declaration
after the `primary_constructors` feature is enabled.The analyzer produces this diagnostic when the declaration of an instance method named `factory` is interpreted as a constructor declaration after the `primary_constructors` feature is enabled.
This problem only impacts declarations where there's no return type and
the name of the method is either the first token or is preceded only by
`external`, `augment`, or `augment external`. The last two will only be
valid after the `augmentations` feature is enabled.This issue only affects declarations that lack a return type and where the method name is the first token or is preceded only by `external`, `augment`, or `augment external`. The `augment` and `augment external` keywords are valid only after the `augmentations` feature is enabled.
If the name could reasonably be changed, then rename the method:Rename the method if the name can be changed:
If the name can't reasonably be changed, then add a return type:Add a return type if the name must remain `factory`:
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
| Commit-Queue | +1 |
The analyzer produces this diagnostic when the declaration of an instance
method named `factory` will be interpreted as a constructor declaration
after the `primary_constructors` feature is enabled.The analyzer produces this diagnostic when the declaration of an instance method named `factory` is interpreted as a constructor declaration after the `primary_constructors` feature is enabled.
Done
This problem only impacts declarations where there's no return type and
the name of the method is either the first token or is preceded only by
`external`, `augment`, or `augment external`. The last two will only be
valid after the `augmentations` feature is enabled.This issue only affects declarations that lack a return type and where the method name is the first token or is preceded only by `external`, `augment`, or `augment external`. The `augment` and `augment external` keywords are valid only after the `augmentations` feature is enabled.
Done
If the name could reasonably be changed, then rename the method:Rename the method if the name can be changed:
This breaks the if-then format used in every other piece of diagnostic documentation, so I didn't apply it. But I did replace "could reasonably" with "can".
If the name can't reasonably be changed, then add a return type:Add a return type if the name must remain `factory`:
Same here. I updated the wording while retaining the if-then structure.
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
If the name could reasonably be changed, then rename the method:Brian WilkersonRename the method if the name can be changed:
This breaks the if-then format used in every other piece of diagnostic documentation, so I didn't apply it. But I did replace "could reasonably" with "can".
Done
If the name can't reasonably be changed, then add a return type:Brian WilkersonAdd a return type if the name must remain `factory`:
Same here. I updated the wording while retaining the if-then structure.
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
| Code-Review | +1 |
| Commit-Queue | +1 |
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
| Commit-Queue | +1 |
| 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. |
| Commit-Queue | +2 |
I'm going to land this, but I'm happy to update the docs if there are further changes desired.
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
Add documentation for the deprecated_factory_method warning
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |