[oslcomp] Reworked source location to include column numbers
Description
Touched up lexer and parser so that for each AST node created the start/end line and columns are recorded. A new object called SrcLoc has been introduced that records the filename together with these 4 numbers, and the code has been updated to make direct use of this new entity.
Diagnostics from the compiler are now followed by a print out of where the error occurred, and a "squiggle underline" pointing at the diagnosed offender.
Defect: at the moment, the print out uses before-preprocessing code, while the lexer can only track locations after preprocessing. This means that if macros are involved that alter the spacing, the squiggles will be in the wrong place. Until we get a preprocessing frontend that tells us about the pre-substitution locations, this cannot be fixed.
Tests
No new tests have been added
Checklist:
- [x] I have read the contribution guidelines.
- [x] I have updated the documentation, if applicable.
- [x] I have ensured that the change is tested somewhere in the testsuite (adding new test cases if necessary).
- [x] My code follows the prevailing code style of this project. If I haven't already run clang-format v17 before submitting, I definitely will look at the CI test that runs clang-format and fix anything that it highlights as being nonconforming.