Commit Graph

33 Commits

Author SHA1 Message Date
ValKmjolnir cbb3906536 add cmakelists.txt 2023-05-06 21:12:40 +08:00
ValKmjolnir c6becf864d optimize codegen 2023-03-09 23:00:25 +08:00
ValKmjolnir dd804ee9f9 update error report for parser&codegen 2023-03-08 23:53:02 +08:00
ValKmjolnir 053dbf24b4 add multi-line error report and span 2023-03-08 01:12:01 +08:00
ValKmjolnir b28e85a7a1 little optimization 2022-11-30 01:11:26 +08:00
ValKmjolnir 34e29e398a 🎨 change code format 2022-11-26 22:49:22 +08:00
ValKmjolnir 7c075a6071 move lvalue check from parse to codegen 2022-11-20 17:06:13 +08:00
ValKmjolnir 58b10b99a7 🎨 improve error report 2022-11-19 22:47:19 +08:00
ValKmjolnir be42d47c93 🐛 fix ast print bug & delete some macros 2022-10-30 18:40:03 +08:00
ValKmjolnir d3fd8ce336 🎨 improve code format
delete option -v, --version, -l, --lex
2022-10-30 01:26:26 +08:00
ValKmjolnir b5828137f2 🎨 improve format of code 2022-10-28 23:28:15 +08:00
ValKmjolnir 1a0f81214f 🔥 change class name.
nasal_lexer -> lexer
nasal_parse -> parse
nasal_codegen -> codegen
nasal_vm -> vm
nasal_gc -> gc
nasal_dbg -> debugger
nasal_import -> linker
nas_ref -> var
2022-10-21 01:29:29 +08:00
ValKmjolnir 4bdfa9cb61 🚀 import information output of dbg, vm and codegen 2022-09-11 17:22:00 +08:00
ValKmjolnir 0f59028c82 improve error output info generated by codegen. 2022-09-05 00:41:36 +08:00
ValKmjolnir f70ce082fd 🎨 improve error log output format. 2022-09-02 02:04:03 +08:00
ValKmjolnir 28fc1eb850 📝 use bold font in test/watchdog.nas 2022-09-01 00:04:14 +08:00
ValKmjolnir 2da3be7fc4 🚀 change cpp standard to c++14 & add command line colorful info output.
and fix a bug that program may crash if there's an error when coroutine is running
2022-08-31 23:24:41 +08:00
ValKmjolnir fb00ddc19a 🚀 add colorful error info print. 2022-08-31 00:56:19 +08:00
ValKmjolnir 6318f7e9e8 optimize header file, now modules could generate smaller dynamic libs. 2022-08-24 22:08:47 +08:00
ValKmjolnir 4ab8a730a6 📝 change int in code to i32, optimize code. 2022-07-31 02:19:29 +08:00
ValKmjolnir 9c779b871f optimize code & chdir will not trigger crash if failed to call 2022-07-30 19:17:33 +08:00
ValKmjolnir 49a7ed28e9 🚀 change std::string to string, change identifiers' name, -o is now a function available in debug mode. 2022-07-23 17:00:25 +08:00
ValKmjolnir 65fe7daff6 📝 change name of used types 2022-07-23 12:35:21 +08:00
ValKmjolnir 4499bf7bac 📝 change makefile and update output format of --opcnt and --detail 2022-07-06 11:57:40 +08:00
ValKmjolnir beba975ff0 change format of error info
parser now can report exact place where is lacking ';' or ','
2022-06-30 23:15:10 +08:00
ValKmjolnir 949a248120 use effective way to check if file exists 2022-04-21 20:51:47 +08:00
ValKmjolnir b010fde8b1 fixed bug when -O0 the program crashes with code 01.
add `nasal_err():error(0){}` in `nasal_err.h:47` as the constructor.
2022-02-14 17:40:19 +08:00
ValKmjolnir de0a6d9388 change name of enum:ast_hashmember->ast_pair, ast_new_iter->ast_iter
change ast_hashmember to ast_pair is because this type in fact is the same as std::pair<std::string,nasal_ref> in C++
2022-01-31 17:22:44 +08:00
ValKmjolnir 6601912de4 bug fixed in nasal_vec::print and nasal_hash::print
if vec's or hash's size is 0, a bug will occur because ++depth. now the ++depth has been put behind the size()
2022-01-29 19:51:43 +08:00
ValKmjolnir a51b7fe11a optimize codes 2022-01-16 22:48:00 +08:00
ValKmjolnir 2ff88b7073 add test file 'turingmachine.nas' & change output format of ast & bug fixed 2021-12-28 20:23:47 +08:00
ValKmjolnir 37b0d7f12a bug fixed 2021-12-25 15:56:08 +08:00
ValKmjolnir 1ae354c0cf lexer,parser,import,codegen use the same error module. 2021-12-23 21:15:50 +08:00