Tristan B. Velloza Kildaire
f571115c23
Added some possible todos, might not need to do any of them but I also might
2022-04-13 09:50:24 +02:00
Tristan B. Velloza Kildaire
1322c0f790
BinaryOperatorExpression now has a proper toString()
2022-04-13 09:49:42 +02:00
Tristan B. Velloza Kildaire
1f8f248219
Added support for the ampersand operator
2022-04-13 09:49:20 +02:00
Tristan B. Velloza Kildaire
15a848756b
Added support for binary/boolean operators in the unary and binary operator cases
2022-04-13 09:45:06 +02:00
Tristan B. Velloza Kildaire
e9a60380b6
Pointer type now only requires you provide it the data type of the data being pointed to.
...
The name of the type will be automatically constructed as `dataType*` (if `dataType` was the type of the data being pointed to)
2022-04-13 09:35:46 +02:00
Tristan B. Velloza Kildaire
6412241185
Added a test case to test pointer handles
2022-04-12 16:17:40 +02:00
Tristan B. Velloza Kildaire
15826a2cab
Updated test case to include a variable access
2022-04-12 16:17:29 +02:00
Tristan B. Velloza Kildaire
cc2cdf2c30
Throw a parsing error when attempting to use anything but a +, * or - as a unary operator
2022-04-12 13:03:40 +02:00
Tristan B. Velloza Kildaire
250d4997e9
Added unit test for simple_function_call
2022-04-12 11:12:02 +02:00
Tristan B. Velloza Kildaire
2ed6a4834d
Cleaned up
2022-04-12 11:11:54 +02:00
Tristan B. Velloza Kildaire
c02a574ffa
Updated test case to test new unary operator expression support
2022-04-12 10:54:12 +02:00
Tristan B. Velloza Kildaire
aff0da5116
Added codegen/typecheck support for unary operator expressions
2022-04-12 10:54:04 +02:00
Tristan B. Velloza Kildaire
1b51d9923e
Added support to the dependency tree generator for unary operator expressions
2022-04-12 10:53:44 +02:00
Tristan B. Velloza Kildaire
ef9018db89
Added UnaryOperatorExpression (finished it)
2022-04-12 10:53:17 +02:00
Tristan B. Velloza Kildaire
1e202fe788
Added Unary Oprator Instruction
2022-04-12 10:52:18 +02:00
Tristan B. Velloza Kildaire
414d9de902
Updated test case
2022-04-08 01:18:57 +02:00
Tristan B. Velloza Kildaire
cd54753359
cleaned up
2022-04-08 01:18:12 +02:00
Tristan B. Velloza Kildaire
190f64c0e8
cleaned up
2022-04-08 01:15:31 +02:00
Tristan B. Velloza Kildaire
b5c4ca44ee
Updated test case
2022-04-08 01:12:55 +02:00
Tristan B. Velloza Kildaire
d79b9eee5c
Debugging things
2022-04-08 01:12:52 +02:00
Tristan B. Velloza Kildaire
1841ca48d9
Recursively descnend upon function argument expressions
2022-04-08 01:12:34 +02:00
Tristan B. Velloza Kildaire
c28a297064
Added toString() to FunctionCall that includes uniqueness number AND funciton's name
2022-04-08 01:08:57 +02:00
Tristan B. Velloza Kildaire
1b002382d5
BinaryOperatorExpressions are meant to evaluate to a value, they MUST be ValueInstructions
2022-04-08 00:34:50 +02:00
Tristan B. Velloza Kildaire
ba63f85df9
Binary operator expressions now work
2022-02-20 16:37:45 +02:00
Tristan B. Velloza Kildaire
6222aabc8b
Pop types off for Binary Operator typechecking
2022-02-20 16:21:29 +02:00
Tristan B. Velloza Kildaire
de31585bcc
Cleaned up
2022-02-20 16:05:15 +02:00
Tristan B. Velloza Kildaire
475983dd95
Cleaned up
2022-02-20 16:04:53 +02:00
Tristan B. Velloza Kildaire
da9bc742e5
Constrain FuncCallInstr evaluation (for arguyments) to only being value-deriving instructions
2022-02-20 15:36:22 +02:00
Tristan B. Velloza Kildaire
492074119d
Added sub-instructions to FuncCallInstr being built
2022-02-20 15:35:34 +02:00
Tristan B. Velloza Kildaire
3cac1b496d
Fixed addInfo for FuncCallInstr instruction
2022-02-20 15:35:18 +02:00
Tristan B. Velloza Kildaire
18eba51144
Remove uneeded reversal code
2022-02-20 14:28:31 +02:00
Tristan B. Velloza Kildaire
4677cacdf1
I think it works now as the types are in the same order as instructions
...
So I guess that works
2022-02-20 14:27:56 +02:00
Tristan B. Velloza Kildaire
76f0d6e1a9
Changed `addType(Type)` to add types to the front of the type queue
...
Added `addTypeB(Type)` to add Types to the end of the type queue
2022-02-20 14:24:05 +02:00
Tristan B. Velloza Kildaire
4b53823d9c
Added `isTypesEmpty()`
2022-02-20 12:09:10 +02:00
Tristan B. Velloza Kildaire
abe72f45a7
WIP
2022-02-19 11:54:00 +02:00
Tristan B. Velloza Kildaire
a84e0dfe20
Some stuff, working on getting function calls working
2022-02-18 14:32:45 +02:00
Tristan B. Velloza Kildaire
71efb7ae8f
Fixed dependency generation for function call paremeters (expressions)
2022-02-16 07:31:22 +02:00
Tristan B. Velloza Kildaire
aa5e82fe09
Added stub funccallinstr add to sotp segmentation fault on funciton calls being processed
2022-02-15 15:04:16 +02:00
Tristan B. Velloza Kildaire
5641c7f164
Added the ability to perform ONLY tokenization (lexing)
2022-01-20 10:54:21 +02:00
Tristan B. Velloza Kildaire
b5488d5c92
Stuff
2022-01-20 10:43:12 +02:00
Tristan B. Velloza Kildaire
49de425e45
Static initialization for classes, including class memory allocation and then static variable (member) initialization has now been implemented for the code generator
2021-11-11 12:48:49 +02:00
Tristan B. Velloza Kildaire
3a32ecfea5
Or do it like that
2021-11-11 12:31:42 +02:00
Tristan B. Velloza Kildaire
a45d2bc30b
Variable's name is full path so resolve from the module
2021-11-11 12:30:40 +02:00
Tristan B. Velloza Kildaire
263bf5edb7
Bug fixed
...
Should not be parent of, but rather should be the class itself
2021-11-11 10:07:25 +02:00
Tristan B. Velloza Kildaire
3da50e9eab
Got some sort of class allocator node created, now to re-order it by using Context to be able to know when the StaticVariableDeclaration is within class.
...
This then generates code to allocate space for the class, once done we can be assured the declarations (placed after it now) will be assigning to properly allocated space (paged and maped for example)
2021-11-10 17:15:27 +02:00
Tristan B. Velloza Kildaire
cae3cfe88c
Updated
2021-11-10 17:01:17 +02:00
Tristan B. Velloza Kildaire
c58bf07bb1
WIP: Trying to get literal encoding working (but it is currently broken)
2021-11-10 17:01:12 +02:00
Tristan B. Velloza Kildaire
6ed33a8051
Done with work for today, good refactoring, now to work on class static initoialization.
...
Instance initialization and unique-ness, and same for Functions with their "FunctionData" will come later
2021-11-10 17:00:56 +02:00
Tristan B. Velloza Kildaire
cb6fb5f86f
Removed unused commented blocks of code
2021-11-10 16:45:08 +02:00
Tristan B. Velloza Kildaire
020847cb76
Added nested class static initialization to test case
2021-11-10 16:44:46 +02:00