-
224533ea8a
Add last-expression-return-value to functions as well
master
Alek Ratzloff
2024-10-21 15:59:36 -07:00
-
46c38de20c
Add block expressions and if expressions
Alek Ratzloff
2024-10-21 15:39:48 -07:00
-
7bce6f8e23
Add \0 string escape
Alek Ratzloff
2024-10-19 20:01:28 -07:00
-
283eaa1ebe
Add index assignment and augmented assignment
Alek Ratzloff
2024-10-18 22:03:10 -07:00
-
43891bd2a3
Add snake_case converter to AST generator
Alek Ratzloff
2024-10-16 10:34:30 -07:00
-
f7d863abb5
Suppress pylint warnings in tools/genast.py
Alek Ratzloff
2024-10-16 10:10:06 -07:00
-
1b145e8f73
Fix bug that disabled the creation of recursive functions
Alek Ratzloff
2024-10-16 09:37:58 -07:00
-
14e2e4d008
Remove unused Vm::frame_stack_mut() function
Alek Ratzloff
2024-10-15 19:09:04 -07:00
-
8ef30a1376
Remove Nop instruction
Alek Ratzloff
2024-10-15 19:06:41 -07:00
-
e8461cd58b
Add map tests
Alek Ratzloff
2024-10-15 19:02:55 -07:00
-
2ec122016c
Add map literals
Alek Ratzloff
2024-10-15 19:01:21 -07:00
-
07a59c8930
Update empty Map to_repr to match syntax
Alek Ratzloff
2024-10-15 19:00:07 -07:00
-
c286937e0a
Maybe fix lexer lexeme issue once and for all
Alek Ratzloff
2024-10-15 14:04:15 -07:00
-
9452a720cc
Add type to Obj instantiation, and fix mutable borrow
Alek Ratzloff
2024-10-15 13:54:45 -07:00
-
3263656668
Add Map __eq__, contains, and get methods
Alek Ratzloff
2024-10-14 20:13:43 -07:00
-
4cdc48537c
Add Map type, add hashbrown crate dependency
Alek Ratzloff
2024-10-14 19:05:27 -07:00
-
c6e242c39d
Change up how function calls are handled
Alek Ratzloff
2024-10-11 16:22:19 -07:00
-
3fd0ba3a0b
Remove BaseObj and fix Object::equals
Alek Ratzloff
2024-10-10 20:30:24 -07:00
-
6143437626
Add arity check to Obj.__call__/Obj::do_call
Alek Ratzloff
2024-10-07 17:21:29 -07:00
-
40a10fa00e
Add Obj.__init__ and Obj.__call__, fix how __call__ works on Ty
Alek Ratzloff
2024-10-07 15:24:06 -07:00
-
16ab9d718b
Add augmented assignment operators for set statements
Alek Ratzloff
2024-10-07 11:05:39 -07:00
-
365bee0554
Implement augmented assignment operators
Alek Ratzloff
2024-10-07 10:23:15 -07:00
-
8179611c23
Add slightly more readable error messages in the compiler
Alek Ratzloff
2024-10-06 20:26:14 -07:00
-
b21a02f12f
Move utility visitors out of compiler.rs
Alek Ratzloff
2024-10-04 20:26:18 -07:00
-
17408a8695
Implement
import a, b, c from foo syntax
Alek Ratzloff
2024-10-04 20:11:06 -07:00
-
c176efb13a
Add some tests for modules
Alek Ratzloff
2024-10-04 11:11:46 -07:00
-
19dd90755d
Fix EOF error in parser
Alek Ratzloff
2024-10-04 11:07:42 -07:00
-
c5f95f4d87
Add Vm::exit_module
Alek Ratzloff
2024-10-04 10:50:40 -07:00
-
f0de5f7850
WIP: Add imports and modules
Alek Ratzloff
2024-10-04 10:11:49 -07:00
-
4a7644b84a
Update AST generator to be more structured
Alek Ratzloff
2024-10-03 11:37:00 -07:00
-
3fb3bf7f91
Squash dead code warning for Method::self_binding
Alek Ratzloff
2024-10-01 09:31:27 -07:00
-
80448899d8
Remove nightly features
Alek Ratzloff
2024-09-30 21:58:21 -07:00
-
a7d7d8e564
Add List.extend and List.to_list, plus some more tests
Alek Ratzloff
2024-09-30 19:53:31 -07:00
-
a370d3a56f
Add List::len method
Alek Ratzloff
2024-09-30 17:46:03 -07:00
-
e5756d6f1a
Don't always assume that an assignment statement will result in a constant
Alek Ratzloff
2024-09-30 17:39:41 -07:00
-
8d1cd710b0
Add tests for string indexing and converting lists to strings
Alek Ratzloff
2024-09-30 17:36:36 -07:00
-
9ec12774fd
Check type equality when inserting a constant
Alek Ratzloff
2024-09-30 17:33:43 -07:00
-
32b11f1d86
Add Str::index and Str::to_list
Alek Ratzloff
2024-09-30 16:49:48 -07:00
-
dab474a037
Add lists
Alek Ratzloff
2024-09-30 16:33:58 -07:00
-
0a21f01ea7
Add RUSTFLAGS=-Awarnings to runtests.sh
Alek Ratzloff
2024-09-30 16:32:52 -07:00
-
8be3586e42
Fix bug in print and println builtins
Alek Ratzloff
2024-09-30 16:28:52 -07:00
-
43183d6553
Most object types get their own file now
Alek Ratzloff
2024-09-30 15:15:41 -07:00
-
724a6b6f99
Add Nil constructor and tests
Alek Ratzloff
2024-09-30 12:48:45 -07:00
-
3d0da0ec85
Add do_call macro, implement Bool builtins, add tests
Alek Ratzloff
2024-09-30 12:41:13 -07:00
-
b9429d7c19
Add __call__, __init__, and fix a few stack bugs
Alek Ratzloff
2024-09-30 12:13:25 -07:00
-
ac6dad9dbd
Change to_repr/to_str implementation story
Alek Ratzloff
2024-09-27 08:10:09 -07:00
-
2f84f2c5bb
Fix minor format stnank with genast.py
Alek Ratzloff
2024-09-26 11:09:07 -07:00
-
9d5d094c5b
Big Object naming refactor
Alek Ratzloff
2024-09-26 11:07:12 -07:00
-
3a9bee0e35
Shuffle object implementation stuff
Alek Ratzloff
2024-09-26 10:52:47 -07:00
-
645105c2c5
Remove kebab-case from parser. It was not being used.
Alek Ratzloff
2024-09-26 10:47:53 -07:00
-
1dd058ae18
Add binary and hex number parsing
Alek Ratzloff
2024-09-26 10:03:54 -07:00
-
cd9617d2fd
Add a few more conversion methods to Int, Float, Str
Alek Ratzloff
2024-09-26 09:25:09 -07:00
-
0d126b8ba3
Add FloatInst method implementations and tests
Alek Ratzloff
2024-09-26 09:03:13 -07:00
-
f020155453
Add integration tests
Alek Ratzloff
2024-09-25 11:42:51 -07:00
-
38a2064b08
Re-shuffle Obj::type_inst and BaseObjInst::type_inst
Alek Ratzloff
2024-09-25 10:27:53 -07:00
-
2203957ebb
Typesystem global instance churn, again
Alek Ratzloff
2024-09-25 10:22:03 -07:00
-
6c64697cde
Include some TODOs for functions
Alek Ratzloff
2024-09-25 09:04:37 -07:00
-
f35053a6c1
Fix some bugs uncovered by testing
Alek Ratzloff
2024-09-25 08:48:11 -07:00
-
11a5a1247e
Fix mix-up in the parser
Alek Ratzloff
2024-09-24 17:16:47 -07:00
-
c8d670ba59
Implement IntInst methods
Alek Ratzloff
2024-09-24 16:57:22 -07:00
-
890467e02c
Compiler emits return instructions
Alek Ratzloff
2024-09-24 16:53:41 -07:00
-
ebd5bf96c3
Implement Str methods
Alek Ratzloff
2024-09-24 14:47:44 -07:00
-
a5d106bdfd
Add not_implemented_{un,bin} functions, cleanup unused "not implemented" functions
Alek Ratzloff
2024-09-24 12:46:45 -07:00
-
ef83796ccc
Implement BaseObjInst::eq and ::neq
Alek Ratzloff
2024-09-24 12:38:13 -07:00
-
8f9d634a15
Reorder derives, I guess
Alek Ratzloff
2024-09-24 12:37:46 -07:00
-
56001856be
Manually implement Debug for MethodInst
Alek Ratzloff
2024-09-24 12:30:26 -07:00
-
3e769e9c48
Compile RHS of binary expressions (oopsie)
Alek Ratzloff
2024-09-24 12:27:53 -07:00
-
4b5d2af117
Move builtin object methods from src/obj.rs to src/builtins.rs
Alek Ratzloff
2024-09-24 11:50:51 -07:00
-
3a7c04686a
Add function yielding and resuming
Alek Ratzloff
2024-09-24 11:34:07 -07:00
-
d69a60f42c
Fix tests that were broken from the last commit
Alek Ratzloff
2024-09-24 09:05:31 -07:00
-
078aef70ea
Split up src/obj.rs
Alek Ratzloff
2024-09-24 09:03:34 -07:00
-
d699ad2ff5
Move MethodInst stack mangling to MethodInst::call
Alek Ratzloff
2024-09-24 08:44:05 -07:00
-
3545488ef8
Add TODO notice on a sorta-important scoping bug
Alek Ratzloff
2024-09-24 08:37:29 -07:00
-
fe586526df
Fix get_attr_lazy
Alek Ratzloff
2024-09-23 21:48:44 -07:00
-
9c4898ff8d
Add base object function stubs(!)
Alek Ratzloff
2024-09-23 21:34:10 -07:00
-
0d04090a99
Implement vtables and method resolution
Alek Ratzloff
2024-09-23 20:59:00 -07:00
-
8b931e9d12
Revamp object system, start using
gc crate
Alek Ratzloff
2024-09-23 18:12:32 -07:00
-
24b06851c7
WIP: move mutability to be internal to the object instead of the pointer
Alek Ratzloff
2024-09-22 20:40:15 -07:00
-
16f3dc960c
Base initial commit
Alek Ratzloff
2024-09-20 16:04:30 -07:00
-
ccf6c9e939
Update visitor methods to return a Result<(), Box<dyn Error>>
Alek Ratzloff
2024-09-20 16:03:37 -07:00
-
0c3e8bd4c0
Add tools and .gitignore
Alek Ratzloff
2024-09-16 14:07:53 -07:00