Skip to content

Missing position in kind mismatch (during effect desugaring) #1215

@rajdakin

Description

@rajdakin

The following code:

sig f : Comp({}, Bool)
fun f() { () }

fails with the error:

:0: Kind mismatch: Type argument 1 for type constructor Comp has kind Row, but an argument of kind Type was expected. 
In:
<dummy>

which does not contain any location information. This is due to these lines:

let pos = SourceCode.Position.dummy in

raise
(Errors.type_application_kind_mismatch pos tycon i
(PrimaryKind.to_string (fst k))
(PrimaryKind.to_string pk_row))

Note that the dummy position is also present elsewhere in this file; I did not try to find an example which makes use of that fact.

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