Skip to content

Check generated features against SDK constraint of user #361

Open
@dcharkes

Description

@dcharkes

@jonasfj suggested that we should check the SDK constraint for the package we're generating to and give an error if we generate dart:ffi code that does not work on the oldest version.

  • Unions should only work for SDK constraint 2.14 and higher.
  • Packed structs and inline arrays should only work for SDK constraint 2.13 and higher.
  • etc.

Then we tell our users to bump their SDK version to the one that the generated code will work for so that they don't accidentally upload code to pub which contains dart:ffi constructs that will only work on the latest stable release while their pubspec says it would work on older stable releases.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions