annotate-snippets-rs
annotate-snippets-rs copied to clipboard
Allow adding non-`Level` context to `Annotation`s
Currently, an Annotation is created with a Level. We emulate rustc's "context" style by using a Level::Info but this isn't accurate (and adds a prefix).
Proposal: Add a new enum with states:
enum Unnamed {
Message, // in rustc terms, "primary"
Context, // in rustc terms, "secondary"
Level(Level), // new to rustc but maintains our current API
// Added, // for when we support suggestions
// Removed, // for when we support suggestions
}
We could then create Annotations off of this
I originally called this Style but this is less of a stole and more of a purpose or role of the annotation. Still unsure what to call it.