Skip to content
This repository was archived by the owner on Jan 3, 2026. It is now read-only.
This repository was archived by the owner on Jan 3, 2026. It is now read-only.

Find a more reliable source origin for diagnostic #30

@stevefan1999

Description

@stevefan1999

Coming from m-labs/artiq#1671:

It seems like one of the issue stems from here:

if len(set(map(lambda x: x.source_buffer,
[location] + highlights))) > 1:
raise ValueError("location and highlights must refer to the same source buffer")

And indeed the evaluation of the expression shows there are more than 2 elements.

Screenshot from 2021-12-20 16-55-49

While the source is clearly different, and it kind of makes sense for the compiler to throw an error like this, shouldn't we find a better source of determining the source origin?
Screenshot from 2021-12-20 16-59-22

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions