Skip to content

Make error messages from clones caused by low level details more actionable #863

@oskgo

Description

@oskgo

Some errors caused by clones emit messages that only mention low level details not directly visible in the clone that caused the issue, which makes it hard to tell what should be done to fix it.

Ideally we should give explanations that relate to the clone itself in addition to the low level cause.

Example:

The following code should emit an error like "_f cannot be instantiated by an operator depending on the declared operator _h because a module (M) in T0 depends on it"

theory TO.

type _T.
type T = _T.
op _f: T.
op f: T = _f.

module M = {proc main() = {return f;}}.

end TO.

theory Thy.
section.

declare type _T.
type T = _T.
declare op _h: T.

op _g = _h.

clone include TO with
type _T <- _T,
type T <- T,
op _f <- _g.

Ref: #749

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