Skip to content

Warn about precedence of metadata over binary operators #83

@serjek

Description

@serjek

Consider example:

@:constant var timeOffset:Float = @byDefault Date.now().getTimezoneOffset()/(-60);

If overriden during model init this will give a warning
... has extra field timeOffset

Real problem is the precedence of metadata over binary operators, which is fixed by wrapping data:

@:constant var timeOffset:Float = @byDefault (Date.now().getTimezoneOffset()/(-60));

Coconut should give a warning when metadata is detected with binary operators.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions