Commit Graph

84 Commits

Author SHA1 Message Date
ValKmjolnir b92930cb71 bug fix & optimize test code & add lib function: subvec, floor, abs, isfunc, isghost, isint, isnum, isscalar, isstr, isvec, vecindex(unfinished) 2022-04-04 18:38:25 +08:00
ValKmjolnir 1adeb2ed77 update test/md5compare.nas & optimize test/md5.nas 2022-03-31 19:31:00 +08:00
ValKmjolnir 51e9b0b5ab add math.pow 2022-03-27 16:14:55 +08:00
ValKmjolnir 1d5e2f5654 add unix.waitpid 2022-03-16 18:44:38 +08:00
ValKmjolnir b61e7dfcb3 update docs & fix bug in nasal_builtin.h 2022-03-16 15:30:34 +08:00
ValKmjolnir 7ef9dd9371 change enum obj_type to nasal_obj::obj_type 2022-03-15 22:51:14 +08:00
ValKmjolnir 19db83a7f0 add destructors for obj_file, obj_dylib, obj_dir & bug fix 2022-03-13 00:11:50 +08:00
ValKmjolnir 34a59db9c4 add destructor for obj_file & change arguments in test/tetris.nas 2022-03-12 23:37:16 +08:00
ValKmjolnir 4bbeaa10b5 visual update 2022-03-10 16:05:49 +08:00
ValKmjolnir 88ed64caf2 change nasal_ref value option functions' output types from pointers to references 2022-03-09 22:54:54 +08:00
ValKmjolnir 8309a6211a add unix.fork&unix.pipe(do not work on windows platform) 2022-03-09 19:03:12 +08:00
ValKmjolnir c00f1a2103 delete lstk&fstk, store local address and function on stack and in vm registers 2022-03-08 17:30:40 +08:00
ValKmjolnir 5ac882c01e update num->string algorithm, now the to_string will output strings with no tailing zeros 2022-03-08 13:40:27 +08:00
ValKmjolnir b786dd0209 safer stl/module.nas & add stl/file.nas encapsulated from lib.nas/io 2022-03-06 15:17:39 +08:00
ValKmjolnir 15c5fbb1fb add module.nas to safely use dylib 2022-03-05 21:52:29 +08:00
ValKmjolnir 9eddf0b3cf try fix bug 'use of undeclared identifier 'environ'' on MacOS 2022-03-05 19:24:33 +08:00
ValKmjolnir ebb601abbf add unix.environ() & use LPCWSTR in dylib.dlopen on Windows platform 2022-03-05 19:15:52 +08:00
ValKmjolnir 7d602cf6ca update 2022-03-01 14:36:05 +08:00
ValKmjolnir 2be7324cde change parameter name in native function split. 2022-02-17 23:34:58 +08:00
ValKmjolnir 0d5b0fa57d now local values are stored on stack. upvalue is generated when creating a new function in local scope.
may include some bugs inside. but all test files has passed the test so i decide to push it.
2022-02-12 23:12:30 +08:00
ValKmjolnir 6908e509ac add notes in lib.nas & add runtime.gc() & add total instruction count in '-o'. 2022-02-09 15:53:09 +08:00
ValKmjolnir 666feae851 change increment arguments to a more efficiency level & change gc.nil, gc.one, gc.zero to constant nil, one, zero 2022-02-04 01:51:30 +08:00
ValKmjolnir 93c0c47762 change error info of native function __builtin_import 2022-01-31 14:48:51 +08:00
ValKmjolnir dfee0d713d change native function num()
num now returns nil if the argument is not a number or numerable string.
2022-01-27 21:41:06 +08:00
ValKmjolnir 454fe1cfa3 add notes of some native functions in lib.nas 2022-01-26 23:51:25 +08:00
ValKmjolnir a51b7fe11a optimize codes 2022-01-16 22:48:00 +08:00
ValKmjolnir 82181b7af4 add debugger framework
with function:backtrace,run,help,show global/local/upvalue,exit
2021-12-20 21:33:22 +08:00
ValKmjolnir e706214854 bug fixed & add os.platform 2021-12-08 18:46:32 +08:00
ValKmjolnir ab6c194d71 add dylib.dlopen dylib.dlsym dylib.dlclose dylib.dlcall
now you could add your own modules into nasal without changing the source code!
2021-12-03 19:31:03 +08:00
ValKmjolnir cabce9370a delete ret stack/ add math.lg
now return address is stored on value stack
2021-12-02 22:23:22 +08:00
ValKmjolnir aeefaebcec add unix.opendir unix.readdir unix.closedir 2021-10-31 23:11:04 +08:00
ValKmjolnir 6b4116aece add unix.time unix.chdir unix.sleep unix.getcwd unix.getenv 2021-10-29 19:52:49 +08:00
ValKmjolnir d13e8084e5 add bits lib 2021-10-28 21:49:08 +08:00
ValKmjolnir b131a3ea9e add io lib & bug fixed 2021-10-27 23:05:25 +08:00
ValKmjolnir 101714986d optimize nasal_ast and fix bug in opr_slc2 2021-10-20 20:54:23 +08:00
ValKmjolnir a7b1851967 optimize code structure 2021-10-16 21:08:57 +08:00
ValKmjolnir 645a652830 change function name and cli format 2021-10-14 23:22:28 +08:00
ValKmjolnir 3ab5f00097 optimize source code 2021-10-12 18:26:10 +08:00
ValKmjolnir 42a330cda7 vm_nil,vm_num changed to no-gcobject 2021-10-08 23:18:26 +08:00
Li Haokun 87d5740125 add fg constants & change int(), num() 2021-09-02 19:10:49 +08:00
Li Haokun e7afc86d97 add isnan 2021-08-27 17:43:01 +08:00
ValKmjolnir b2f09ec855 closure bugs fixed 2021-08-17 01:18:35 +08:00
ValKmjolnir 49e9412915 use same indentation 2021-08-09 21:30:18 +08:00
Li Haokun e9bd033883 update 2021-08-09 19:13:39 +08:00
ValKmjolnir 143a59c735 update 2021-08-09 01:02:27 +08:00
Li Haokun a6fe835ed4 variables can be used before definition
change program to command line
change trace back info
change print function of nasal_vec and nasal_hash
2021-08-03 18:55:11 +08:00
Li Haokun 1a180ae01a update 2021-07-19 17:04:45 +08:00
Li Haokun d9d7a1edfc add trace back info 2021-07-16 17:18:13 +08:00
ValKmjolnir d7ba29e02c delete slice_stack 2021-07-07 14:46:46 +08:00
ValKmjolnir ee9afe1cf1 change instruction dispatch to computed-goto
bug fixed
prepare for version 7.0
2021-06-26 14:53:10 +08:00