Irmen de Jong
fc5889ec0b
kotlin 2.2.10, kotest
2025-08-19 01:04:24 +02:00
Irmen de Jong
bc58a25765
allow sizeof(^^type) to return the size of a pointer
2025-08-02 11:33:15 +02:00
Irmen de Jong
d5cc414221
Merge branch 'master' into structs
...
# Conflicts:
# codeOptimizers/src/prog8/optimizer/StatementOptimizer.kt
# compiler/src/prog8/compiler/astprocessing/CodeDesugarer.kt
# compilerAst/src/prog8/ast/antlr/Antlr2Kotlin.kt
# examples/test.p8
2025-06-02 20:52:50 +02:00
Irmen de Jong
15fc3b6c04
replace old antlr2kotlin code with the new visitor-based translator
2025-06-02 01:56:07 +02:00
Irmen de Jong
112ca3cc53
allow sizeof(&thing), add sys.SIZEOF_POINTER
2025-05-29 15:58:29 +02:00
Irmen de Jong
33b3a1664c
replace sizeof(list^^) with sizeof(List) to allow it to compile. Same with simple pointers.
2025-05-29 14:13:42 +02:00
Irmen de Jong
8a0c02e264
Merge branch 'refs/heads/master' into structs
...
# Conflicts:
# codeCore/src/prog8/code/target/NormalMemSizer.kt
# codeCore/src/prog8/code/target/VMTarget.kt
# compiler/src/prog8/compiler/BuiltinFunctions.kt
# compilerAst/src/prog8/ast/antlr/Antlr2Kotlin.kt
# examples/test.p8
2025-05-29 13:42:16 +02:00
Irmen de Jong
3b1b0985c1
make sizeof(float) work, so you don't have to use sys.SIZEOF_FLOAT anymore etc.
...
define sys.SIZEOF_FLOAT in terms of sizeof(float)
2025-05-29 12:38:03 +02:00
Irmen de Jong
db6c887795
Merge branch 'master' into structs
...
# Conflicts:
# compiler/test/ast/TestVariousCompilerAst.kt
2025-05-21 00:27:45 +02:00
Irmen de Jong
cf7bea0985
cleanup RTS insertion and ast postprocessing before assembly generation
2025-05-21 00:19:50 +02:00
Irmen de Jong
696bf636ed
better parsing of directive names results in better error messages when an invalid one is found
2025-05-02 00:41:42 +02:00
Irmen de Jong
3770a4fe0c
easier datatype notation by just using the type objects directly
2025-03-18 23:33:04 +01:00
Irmen de Jong
7668a3c660
use kotest tempdir instead of hardcoded output directory
2025-03-14 01:18:33 +01:00
Irmen de Jong
4daa909f32
fix path normalization problems,
...
allow ~ in srcdirs compiler flag
2024-12-26 17:42:20 +01:00
Irmen de Jong
131d5ceb4f
avoid re-reading all source files when sourcelines are requested in the asm
2024-12-21 00:06:18 +01:00
Irmen de Jong
512ddd1694
cleanups
2024-12-20 22:59:20 +01:00
Irmen de Jong
1a1ab0dac6
changed the data type system to composite types
2024-12-05 21:48:51 +01:00
Irmen de Jong
2eed75f602
call convention for @Rx parameters, also use cpu registers if possible, like normal parameters
2024-11-25 22:22:24 +01:00
Irmen de Jong
fff0d741c3
improved parsing of "not in" operator, and [] array signature (allow space)
2024-10-02 19:06:20 +02:00
Irmen de Jong
2da35fec17
remove requirement to end subroutine with an EOL, so oneliners are now possible
...
main { sub start() { cx16.r0++ cx16.r1++ } }
2024-09-01 20:55:43 +02:00
Irmen de Jong
8f6eaeac2c
half width katakana conversion
2024-08-21 18:51:34 +02:00
Irmen de Jong
c9a4235669
update to kotlin 2.0, fix several code style issues
2024-06-04 01:00:46 +02:00
Irmen de Jong
ddb8346711
added txt.cls() as a shorter alternative to clear_screen().
...
cx16: added new character encodings, and routines in textio to enable the character sets for them.
cx16: added txt.chrout_lit() and txt.print_lit() to always print the literal characters and never as control codes
2024-04-07 19:32:44 +02:00
Irmen de Jong
f40b7b62bb
updated unit tests and some basic changes for them
2024-03-02 23:19:20 +01:00
Irmen de Jong
358215e4dd
removed postIncrDecr (still allow ++/-- to be parsed into +=1/-=1)
2024-02-06 18:50:08 +01:00
Irmen de Jong
6aed7e429a
allow containment check in a range expression ("run time" range expression)
2024-01-03 01:17:13 +01:00
Irmen de Jong
ef1c665b9a
allow underscores for numerical grouping
2023-12-09 13:13:34 +01:00
Irmen de Jong
dff1d9e4dd
cleanup range expression doc
2023-08-09 22:58:04 +02:00
Irmen de Jong
7c0bde7310
parser: allow curly brace on next line for asmsub too
...
downgrade antlr4 one version again to what is used in IntelliJ's antlr plugin, to avoid potential version conflicts
2023-08-09 20:01:12 +02:00
Irmen de Jong
c223702ea0
code cleanups
2023-07-30 18:42:45 +02:00
Irmen de Jong
bf703a8a66
unittest
2023-06-27 23:43:35 +02:00
Irmen de Jong
0a83b51e00
allow more curly brace styles
2023-06-27 01:59:22 +02:00
Irmen de Jong
e779a07bce
allow when with byte 1,2,3 for word variables without having to cast the values to word explicitly
2023-03-09 22:15:56 +01:00
Irmen de Jong
6aabbffc62
some cleanups
2023-02-09 02:34:18 +01:00
Irmen de Jong
d0e6a2eb8b
fix compiler crash on hoisting certain vardecls from inner scopes
2022-12-22 18:49:53 +01:00
Irmen de Jong
e2f20ebf94
fix crash on empty conditional branch statement (if_cc { } )
2022-11-23 02:14:48 +01:00
Irmen de Jong
88cbb6913d
tweak bool type handling
2022-07-11 14:55:50 +02:00
Irmen de Jong
6a57337a68
improved bool type checking
2022-07-08 22:59:35 +02:00
Irmen de Jong
965340ff90
logical and/or/xor/not all replaced by bitwise &,|,^,~ (ast, codegens)
...
this also fixed some invalid outcomes of logical expressions!
2022-07-02 00:38:17 +02:00
Irmen de Jong
4b358abbb7
"not" operator removed from ast and codegen (it's been replaced with x==0 as equivalent)
2022-06-29 01:13:08 +02:00
Irmen de Jong
c75bd97537
update kotest
2022-06-26 18:51:03 +02:00
Irmen de Jong
af2ca7a67e
fix problematic characters that cause path errors on Windows
2022-06-05 11:46:37 +02:00
Irmen de Jong
ba614801ee
cleanup
2022-05-22 23:11:22 +02:00
Irmen de Jong
6f2fdbe447
added %option merge, also fixed problem with unit test building in newer IntelliJ version
2022-04-15 22:38:32 +02:00
Irmen de Jong
3b6e7eccdd
simplified containment check, only possible on string and arrays (as per the docs)
2022-03-27 16:59:55 +02:00
Irmen de Jong
ff57c5e9d3
working on vm and new ast
2022-03-21 01:36:11 +01:00
Irmen de Jong
3961f26635
consolidating modules
2022-03-11 20:45:39 +01:00
Irmen de Jong
e51c274a18
reducing dependencies
2022-03-11 20:32:35 +01:00
Irmen de Jong
9a798360f4
introduced codeAst and codeCore modules to reduce dependencies
2022-03-10 22:38:16 +01:00
Irmen de Jong
251b6fcf70
reducing dependencies
2022-03-10 02:09:34 +01:00