Trouble with Cortex-M "Hello World"

Johannes Pfau via Digitalmars-d digitalmars-d at puremagic.com
Wed Apr 1 06:59:33 PDT 2015


Am Wed, 01 Apr 2015 12:56:22 +0000
schrieb "Jens Bauer" <doctor at who.no>:

> Unfortunately, my attempt to build GDC on my CubieBoard2 failed.
> 
> However, I decided to change the line slightly, in order to find 
> out exactly what's going wrong...
> 
> 
> src/start.d:46:12: error: mismatched array lengths, 0 and 3
>       uint[4]message=[2,cast(uint)"hello\r\n".ptr,7];
>              ^
> make: *** [output/src/start.o] Error 1
> 
> This means that the arry on the right hand side is actually 
> parsed correctly.
> It seems that the number [3] or [4] is parsed/read as zero ??

I'm not sure if anybody ever used GDC/DMD/LDC on a big-endian system.
It could be an endianess issue somewhere in the code. I debugged a
misaligned-access bug in the frontend some time ago, bugs like these can
result in the weirdest effects.

It should compile on the cubieboard though. What exactly failed?


More information about the Digitalmars-d mailing list