Skip to content

Selective Field Import #3121

@q-uint

Description

@q-uint

It seems you can not import a file that uses selective field imports.


src
├── X.mo
└── Y.mo
// X.mo
import { Array_init = init } = "mo:⛔";
// Y.mo
import X "X";

Error

src/X.mo:1.8-1.29: type error [M0015], only trivial patterns allowed in static expressions

Context

$(vessel bin)/moc --check $(vessel sources) src/Y.mo
  • vessel 0.6.2
  • Motoko compiler 0.6.21 (source wahvzdqw-grg3wqkh-0n8s7fj6-f4rxx0rh)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions