diff options
| author | zooster <r00ster91@proton.me> | 2022-08-18 18:54:51 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2022-08-18 19:54:51 +0300 |
| commit | 4055e6055b5c0727f5e85a30760c9bccf525f4de (patch) | |
| tree | 3295ef3babc22815422ced1f692bc98c9a43972d /lib/std/Thread/Condition.zig | |
| parent | 2523b443a482d78fd1a31f5e6b0224fec03835e3 (diff) | |
| download | zig-4055e6055b5c0727f5e85a30760c9bccf525f4de.tar.gz zig-4055e6055b5c0727f5e85a30760c9bccf525f4de.zip | |
AstGen: disallow leading zeroes in int literals and int types
This makes `0123` and `u0123` etc. illegal.
I'm now confident that this is a good change because
I actually caught two C header translation mistakes in `haiku.zig` with this.
Clearly, `0123` being octal in C (TIL) can cause confusion, and we make this easier to read by
requiring `0o` as the prefix and now also disallowing leading zeroes in integers.
For consistency and because it looks weird, we disallow it for integer types too (e.g. `u0123`).
Fixes #11963
Fixes #12417
Diffstat (limited to 'lib/std/Thread/Condition.zig')
0 files changed, 0 insertions, 0 deletions
