Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Diagnostics Redux #57

Closed
dmlloyd opened this issue Sep 24, 2020 · 0 comments
Closed

Diagnostics Redux #57

dmlloyd opened this issue Sep 24, 2020 · 0 comments
Assignees
Labels
area: compiler An issue which relates the compiler area area: driver An issue relating to the driver area: toolchain An issue which relates to the tool chain API or one of its implementations kind: task 📋 A task to fulfill an implementation requirement
Milestone

Comments

@dmlloyd
Copy link
Collaborator

dmlloyd commented Sep 24, 2020

The diagnostics/error reporting API is a mess. It should:

  • Be independent of logging
  • Support error/warn/notice/info levels
  • Be aware of source location (only one level is necessary; related messages can follow)
  • Support error codes for each type of problem (likely reuse i18n infrastructure for this, see Logging infrastructure #11)
  • Propagate through all stages in such a way that:
    • C probes may correspond to original source file/line in such a way that C probe errors may be relayed into the main diagnostic context
    • Backend compilation errors correspond to original source whenever possible
  • Employ (or at least examine) best practices established by long-lived existent static compilers such as gcc, clang as well as modern languages like rust, go etc.
  • Take advantage of diagnostic location information on nodes (?)

This piece is fundamental enough that an informal design proposal should be the first deliverable.

@dmlloyd dmlloyd added kind: task 📋 A task to fulfill an implementation requirement area: compiler An issue which relates the compiler area area: toolchain An issue which relates to the tool chain API or one of its implementations area: driver An issue relating to the driver labels Sep 24, 2020
@dmlloyd dmlloyd added this to the 0.1.0 milestone Sep 24, 2020
@dmlloyd dmlloyd self-assigned this Sep 25, 2020
@dmlloyd dmlloyd closed this as completed Oct 23, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: compiler An issue which relates the compiler area area: driver An issue relating to the driver area: toolchain An issue which relates to the tool chain API or one of its implementations kind: task 📋 A task to fulfill an implementation requirement
Projects
None yet
Development

No branches or pull requests

1 participant