Skip to content

Process.argv doesn't have a reified type #56

@nex3

Description

@nex3

The Process.argv getter declares a reified type of List<String>, but because the array in question comes from JS, it doesn't have a reified String type argument. This causes it to throw an error at runtime when passed to pure Dart code that expects a List<String>.

Once dart-lang/sdk#30554 is fixed, it will be possible to modify the argv getter so that it casts the array when accessed from Dart. Until then, it's probably best to make the static type just List so that we get appropriate static errors.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions