ImportC octal literals: difference between GCC and dmd

bachmeier no at spam.net
Sat Nov 27 04:48:55 UTC 2021


On Saturday, 27 November 2021 at 04:11:16 UTC, russhy wrote:
> Looks like ImportC has issues with ``08.0`` and ``09.0``
>
>
> ```D
> static double F[2] =
>     {
>         08.0,
>         09.0,
>     };
> ```
> ```
> $ dmd -c test.c
> test.c(3): Error: octal digit expected, not `8`
> test.c(3): Error: octal digit expected, not `8`
> test.c(4): Error: octal digit expected, not `9`
> ```

DMD does that with D code too. It doesn't seem correct though, 
unless octal double is a thing.


More information about the Digitalmars-d mailing list