Commit Graph

572 Commits

Author SHA1 Message Date
Andrew Morris
a7ced2eb76 Fix nested function declarations 2023-03-24 15:31:24 +11:00
Andrew Morris
bb2c49d9a7 Fix p5 by (correctly) skipping declares 2023-03-24 15:15:22 +11:00
Andrew Morris
91f9e1c3dd Almost working 2023-03-24 14:42:27 +11:00
Andrew Morris
9efd517980 Only bind register captures 2023-03-24 14:40:31 +11:00
Andrew Morris
5931d8a8f9 Only allocate register for capture if original name is a register 2023-03-24 14:32:12 +11:00
Andrew Morris
57a95798cd Include more expressions 2023-03-24 14:16:15 +11:00
Andrew Morris
c811d0944e Improve diagnostic 2023-03-24 14:02:20 +11:00
Andrew Morris
e2886d209d Include prop_key of object patterns 2023-03-24 13:45:00 +11:00
Andrew Morris
64cad76081 Only process scope of local exports 2023-03-24 13:17:34 +11:00
Andrew Morris
d3391028ba Include ModuleDecl::ExportNamed 2023-03-24 12:47:28 +11:00
Andrew Morris
5f5398b566 Ignore non-register captures, set self.owner_id correctly 2023-03-24 12:32:21 +11:00
Andrew Morris
1164de3f3f Include member.prop 2023-03-24 11:41:39 +11:00
Andrew Morris
745ebd03b7 Prefer relative paths in CLI output 2023-03-24 11:31:31 +11:00
Andrew Morris
6a87fbb2c2 Include non-mutations in assignment 2023-03-24 11:16:48 +11:00
Andrew Morris
fe2e281d0b Improve diagnostic 2023-03-24 10:55:08 +11:00
Andrew Morris
f878dbbae9 Insert each mutation as a ref 2023-03-24 10:19:44 +11:00
Andrew Morris
026c3e1619 Lookup returns option, enabling diagnostics, include ref when inserting name 2023-03-24 10:06:19 +11:00
Andrew Morris
ec14f657e9 wiiiip 2023-03-24 09:24:17 +11:00
Andrew Morris
64e79cf13b oof wip 2023-03-23 21:14:05 +11:00
Andrew Morris
1d1c4496b3 wip 2023-03-23 21:14:00 +11:00
Andrew Morris
b95c32f45b Avoid allocating special registers in RegAllocator 2023-03-23 19:38:01 +11:00
Andrew Morris
b273bf1091 associate values during scope analysis, add .lookup 2023-03-23 19:35:42 +11:00
Andrew Morris
e86b2b6127 More tests and fixes 2023-03-23 17:17:27 +11:00
Andrew Morris
ba68ef697a Test exceptions 2023-03-23 15:48:33 +11:00
Andrew Morris
2e500692bf Compile try-catch 2023-03-23 14:12:35 +11:00
Andrew Morris
473f061373 Add tryCatchFinally concept 2023-03-23 11:15:38 +11:00
Andrew Morris
45294cec47 Avoid throwing when register is void 2023-03-23 10:30:57 +11:00
Andrew Morris
56b35e06e2 Add finallyWithoutThrow concept 2023-03-23 10:14:34 +11:00
Andrew Morris
ad478c0c4b Catch exceptions using .catch_setting 2023-03-23 10:11:10 +11:00
Andrew Morris
0daaf0f650 Implement stack unwinding 2023-03-23 09:57:40 +11:00
Andrew Morris
337c5c5296 Add set_catch, unset_catch instructions 2023-03-23 09:35:33 +11:00
Andrew Morris
56f6ce5922 Add limited comment support in assembly 2023-03-23 08:59:57 +11:00
Andrew Morris
d21de90730 exception concepts 2023-03-22 16:37:11 +11:00
Andrew Morris
55fceb80cb Store mutations by span 2023-03-22 14:39:32 +11:00
Andrew Morris
7594eeeadd Replace capture_finder with scope_analysis data 2023-03-22 14:27:06 +11:00
Andrew Morris
120cede42d Add capture test 2023-03-22 09:34:03 +11:00
Andrew Morris
a046a8e4fc Fix bigint + type error 2023-03-21 16:47:54 +11:00
Andrew Morris
660518b083 Update readme 2023-03-21 16:44:57 +11:00
Andrew Morris
feeb0594de Emit type and range errors 2023-03-21 16:44:41 +11:00
Andrew Morris
e657604cbe Error builtin 2023-03-21 16:06:53 +11:00
Andrew Morris
e94876fc68 Update status 2023-03-21 14:34:49 +11:00
Andrew Morris
f43e83cffe Compile throw expressions 2023-03-21 14:29:38 +11:00
Andrew Morris
8b535f4f03 Throw instruction 2023-03-21 14:16:23 +11:00
Andrew Morris
cfb72fdbcd Dedupe InstructionByte 2023-03-21 14:00:33 +11:00
Andrew Morris
20d81f5324 Add label to uncaught exceptions 2023-03-21 13:52:11 +11:00
Andrew Morris
f75b0c7152 Convert most vm panics into exceptions 2023-03-21 13:45:22 +11:00
Andrew Morris
a59b577cd3 Make NativeFunction use exceptions (panics not converted though) 2023-03-21 12:07:04 +11:00
Andrew Morris
79534a8d38 Enable testing exceptions with test_output 2023-03-21 11:23:05 +11:00
Andrew Morris
215139e98b Exceptions for binary ops 2023-03-21 11:14:44 +11:00
Andrew Morris
11b547db15 Set up frame steps for exceptions 2023-03-21 09:51:25 +11:00