1
0
mirror of https://gitlab.com/camelot/kickc.git synced 2024-11-29 18:49:42 +00:00
Commit Graph

2688 Commits

Author SHA1 Message Date
jespergravgaard
0d73070f37 Fixed problem with aliased intermediate memory variables. #666 2021-06-07 21:15:07 +02:00
jespergravgaard
194e851f0d Intermediate variables are now affected by the var_model. Closes #666 2021-06-06 23:34:29 +02:00
jespergravgaard
78e378a8e1 #666 Moved intermediate variable creation into VariableBuilder in preparation for fix of memory area. 2021-06-06 22:23:14 +02:00
jespergravgaard
1715e4f5ba Added a few fragments 2021-06-06 21:41:35 +02:00
Jesper Gravgaard
843baa6fb2 #666 working on memory model for intermediate vars 2021-06-06 12:19:05 +02:00
Jesper Gravgaard
fcb23cbf59 Added some fragments. Preparing for VariableBuilder being used for intermediate variables. 2021-06-05 09:46:47 +02:00
jespergravgaard
a24cc6267a Fixed tests. 2021-05-19 09:01:54 +02:00
jespergravgaard
5de7578bc6 Minor code clean-up. 2021-05-17 08:34:38 +02:00
jespergravgaard
fef4a88204 Minor code clean-up. 2021-05-17 08:32:33 +02:00
jespergravgaard
3d87387ae3 Updated test data. #121 2021-05-16 20:10:40 +02:00
jespergravgaard
f14dfe4252 Moved stack call parameter assignments out of pass 0. Added address-of handling for procedures converting them to stack call if they have parameters. #121 2021-05-16 10:19:21 +02:00
jespergravgaard
55e5e6bca2 Added a test for OutputFileManager. This fixes the problem with -o not being honored always. Closes #644 2021-05-15 12:38:53 +02:00
jespergravgaard
867a816eae Implemented OutputFileManager which ensures that the output directory, basename and extension follows well defined rules. Closes #663 2021-05-15 11:17:17 +02:00
jespergravgaard
f67c2712d3 Fixed support for address-of on arrays. Closes #662 2021-05-14 00:01:58 +02:00
jespergravgaard
1d44ceb206 Implemented real standard C type syntax - both for declarations and casts. Removed support for the non-standard pointer to function syntax. Closes #661 2021-05-13 11:57:17 +02:00
jespergravgaard
3ad844ada1 Fixed problem with auto-casting parameters. Closes #299 2021-05-13 11:42:07 +02:00
jespergravgaard
541b92c55b Implemented support for complex casts and parsing complex type names for sizeof(). #121 2021-05-13 10:26:33 +02:00
jespergravgaard
2ffa6e3ca8 Standard C type parsing now works! #121 2021-05-12 08:58:10 +02:00
jespergravgaard
a56016fea2 erged with original 121 branch 2021-05-11 23:27:25 +02:00
jespergravgaard
35fdd06abf Added missing test files and fixed a test. #121 2021-05-11 23:19:29 +02:00
jespergravgaard
d1b7d45372 Implemented function pointer types in standard C syntax. #121 2021-05-11 23:11:51 +02:00
jespergravgaard
9c006cf015 Removed support for auto-casting integers to pointers. Closes #659 2021-05-11 13:40:56 +02:00
jespergravgaard
d4b8820b1c Removed support for auto-casting integers to pointers. Closes #659 2021-05-11 13:36:45 +02:00
jespergravgaard
497fd2b89f Removed most of the support for auto-casting integers to pointers. #659 2021-05-10 21:27:14 +02:00
jespergravgaard
a076fde1f0 Added missing fragments from @Flight_Control. Also demonstrates problem with auto-casting integers to pointers. Closes #656 2021-05-09 10:37:14 +02:00
jespergravgaard
0174743e94 Added missing fragments from @Flight_Control. 2021-05-08 20:24:17 +02:00
jespergravgaard
799f681991 Fixed problem with constantifying struct initializers. Closes #653 2021-05-08 13:33:17 +02:00
jespergravgaard
823f2d7804 Working on type parser rewrite 2021-05-08 13:12:04 +02:00
jespergravgaard
09d11f220b Converted DeclFunction to use declarator. #121 2021-05-03 00:50:10 +02:00
jespergravgaard
d59c5315ec Converted ParamDecl to use declarator. #121 2021-05-03 00:24:37 +02:00
jespergravgaard
7fb310296d Converted typedef to use declarator. #121 2021-05-02 21:11:03 +02:00
jespergravgaard
fafc9a5765 Converted ranged for to use declarator. Removed support for ranged for without type. #121 2021-05-02 17:39:07 +02:00
jespergravgaard
f0970364b5 Parser now based on declarator - allowing for more advanced pointer/array syntax. Preparing for declarator-based functions. #121 2021-05-02 14:28:03 +02:00
jespergravgaard
6400ef4d88 Simplified VariableDeclaration by removing VariableDeclType. Type qualifiers are now entirely embedded inside SymbolType. #121 2021-05-01 13:08:08 +02:00
jespergravgaard
78209db593 Variable printing now in C syntax. #121 2021-04-30 17:26:46 +02:00
jespergravgaard
8fd8bb1832 Removed const/volatile from Variable. #121 2021-04-30 16:21:38 +02:00
jespergravgaard
38d62b5759 Merge remote-tracking branch 'origin/master' 2021-04-30 15:39:40 +02:00
jespergravgaard
6e0cacc908 Moved const/volatile to SymbolType. #121 2021-04-30 15:39:29 +02:00
jespergravgaard
37ad98913f working on type qualifiers 2021-04-24 08:05:16 +02:00
Jesper Gravgaard
7e6c97779b Fixed problem with NPE when removing unused code can leave global constants referencing removed variables. Closes #650 2021-04-21 19:34:18 +02:00
jespergravgaard
8b2186e634 Added volatile/const booleans to SymbolType. So far they are always false! 2021-04-16 08:54:02 +02:00
jespergravgaard
5b82ae95ea Merged with master - ArraySpec moved to SystemTypePointer. 2021-04-12 22:00:49 +02:00
jespergravgaard
e78cd72417 Merge remote-tracking branch 'origin/master' into 121-pointer-to-function 2021-04-12 21:47:35 +02:00
Jesper Gravgaard
76edc3b8c8 Moved ArraySpec to SymbolTypePointer. 2021-04-12 20:57:46 +02:00
jespergravgaard
40d2b3b361 Updated parser syntax to work for any C-types - including pointers to functions. See section 5.12 in K&R for test cases. Pass0 will break! #121 2021-04-07 00:18:33 +02:00
Jesper Gravgaard
66b3daa62f Added example of work-around for passing parameters to call by pointer function. 2021-04-06 21:58:12 +02:00
jespergravgaard
6fe60c6ad5 Added WORD0/1 and fragments. #221 2021-04-06 00:18:49 +02:00
jespergravgaard
510935eee7 Added BYTE0/1/2/3 fragments. #221 2021-04-05 02:19:29 +02:00
jespergravgaard
9443fd5c46 Added BYTE0/1/2/3 support in ilist initializers. #221 2021-04-05 02:02:30 +02:00
jespergravgaard
299671109b Added initial support for special BYTE2() and BYTE3() unary operators giving access to specific bytes. #221 2021-04-05 01:14:35 +02:00