Charlie Gordon

Results 122 comments of Charlie Gordon

> I'm still in unsure about this, is: > > `u32 x = 1, y = 2;` so much better than: > > ``` > u32 x = 1; >...

> Based on the latest master, the unit test are broken: > > `test/parser/sizeof_expr_ok.c2:64: unexpected error: unknown module: 's' ` > `test/parser/sizeof_expr_ok.c2:69: unexpected error: 'aa[0]' is not a type` Are...

Indeed different behavior on linux and macOS. The CI test fails but is not reported as failure either: ``` Run . env.sh setting C2 development environment test/parser/sizeof_expr_ok.c2 test/parser/sizeof_expr_ok.c2:[6](https://github.com/c2lang/c2compiler/actions/runs/15007841090/job/42170721587?pr=218#step:4:7)4: unexpected error:...

> This commit is probably the biggest language change so far (not code-wise, but impact-wise). I like the use when using simple structs, like point. So instead of > >...

> Minor typo in commit msg: intiializers (makes git log nicer) Yes, I forgot to fix that. Changed the commit line to: ```none Compiler: accept initializer lists in assignments, extend...

> I was looking through the code and in `analyseBinaryOperator()` there is a check if `opcode == Assign`. That got me thinking about the other assign (`+=`, `-=`, `/=` etc)....

> (i pushed a change to master to get a better error location for that) The error code is still somewhat confusing: ``` point.c2:32:7: error: lvalue required as left operand...

> I would prefer to keep patches as small as possible, since reviewing smaller ones is a lot easier... So a complete overhaul of the expr parsing would probably be...

I missed your last message before pushing my latest version. Let me merge your changes and rework this.

> The Tokenizer.charAt() is really nasty, since it breaks the clean interface of tokens... I'll see if I can find a nice solution. A cleaner solution is to store the...