lexer: Keep entire source file in memory.
authorBen Pfaff <blp@cs.stanford.edu>
Mon, 22 Nov 2021 19:45:48 +0000 (11:45 -0800)
committerBen Pfaff <blp@cs.stanford.edu>
Mon, 6 Dec 2021 17:05:31 +0000 (09:05 -0800)
commit8233b7bfd0604d83a27385ecd7d397b9c891a4f2
tree10a15f552fb9f41d7974ae4fdc2452eec0afd7d6
parent861528a56e8fcb470285a2ee0bb87d716f652174
lexer: Keep entire source file in memory.

Previously, the lexer tried to keep only part of each source file in
memory, the part that wasn't fully parsed yet.  With this commit, the
lexer holds the entire file in memory, even parts that are no longer
needed.  This should make it easier to produce better error messages.
src/language/lexer/lexer.c