Commit Graph

4 Commits

Author SHA1 Message Date
Dave Yarwood
0d74a7caaa work around edge cases where the source context is missing 2021-01-25 21:02:12 -05:00
Dave Yarwood
b3956dde60 scaffolding for better user-facing error messages 2021-01-16 15:27:22 -05:00
Dave Yarwood
e0d11b1ec2 include source context EVERYWHERE
This provides filename/line/column context for any error I could possibly find.
To achieve this, I made it so that all ScoreUpdates have source context, so when
updating the score results in an error, we can print out the line and column
number corresponding to the error.

It's a bit more complicated than that, because score updates are nestable (e.g.
event sequences can contain cram expressions can contain chords, etc.), which
essentially gives us a stacktrace whenever a score update results in an error. I
punted on giving the user the full stacktrace, in favor of doing something
simpler and just showing the bottom-most error, because that's probably going to
be the line and column number that's the most helpful.
2020-11-14 20:34:04 -05:00
Dave Yarwood
f961abfd3c reorganize source context stuff a bit 2020-10-29 20:42:46 -04:00