Re: ARM Cortex-M - Static array dyamically allocated

2013-12-21 Thread Mike
On Wednesday, 18 December 2013 at 14:30:12 UTC, Iain Buclaw wrote: This has been fixed to not call any library routines, but has not been backported to the 4.8 branch yet. This is something that will be done before New Years (if my list of things to do does not grow even more...) Iain, Pri

Re: ARM Cortex-M - Static array dyamically allocated

2013-12-21 Thread Iain Buclaw
On 21 December 2013 11:29, Johannes Pfau wrote: > Am Sat, 21 Dec 2013 11:34:29 +0100 > schrieb "Mike" : > >> >> > Should the module name then default to the file name? >> > Is there a way to query and print the full module name at >> > compile time? >> >> Good questions, I'd like to know these mys

Re: ARM Cortex-M - Static array dyamically allocated

2013-12-21 Thread Johannes Pfau
Am Sat, 21 Dec 2013 11:34:29 +0100 schrieb "Mike" : > > > Should the module name then default to the file name? > > Is there a way to query and print the full module name at > > compile time? > > Good questions, I'd like to know these myself. Iain? Johannes? It usually should default to the fi

Re: ARM Cortex-M - Static array dyamically allocated

2013-12-21 Thread Mike
On Saturday, 21 December 2013 at 10:14:18 UTC, Timo Sintonen wrote: Hi Mike, the arm-old branch has a new frontend version (2.064), the official gdc-4.8 branch is at (2.063) but I'll push an update today. Anyway, dmd 2.064 behaves the same way, it seems dmd 2.064 is pickier with object.d fi

Re: ARM Cortex-M - Static array dyamically allocated

2013-12-21 Thread Timo Sintonen
On Saturday, 21 December 2013 at 09:35:33 UTC, Mike wrote: On Saturday, 21 December 2013 at 08:51:11 UTC, Johannes Pfau wrote: Am Sat, 21 Dec 2013 02:58:49 +0100 schrieb "Mike" : On Saturday, 21 December 2013 at 00:07:17 UTC, Mike wrote: I should probably add that if I remove my object.d file

Re: ARM Cortex-M - Static array dyamically allocated

2013-12-21 Thread Mike
On Saturday, 21 December 2013 at 08:51:11 UTC, Johannes Pfau wrote: Am Sat, 21 Dec 2013 02:58:49 +0100 schrieb "Mike" : On Saturday, 21 December 2013 at 00:07:17 UTC, Mike wrote: I should probably add that if I remove my object.d file from the file system, I get: cc1d: error: cannot find so

Re: ARM Cortex-M - Static array dyamically allocated

2013-12-21 Thread Johannes Pfau
Am Sat, 21 Dec 2013 02:58:49 +0100 schrieb "Mike" : > On Saturday, 21 December 2013 at 00:07:17 UTC, Mike wrote: > > I should probably add that if I remove my object.d file from the > file system, I get: > > cc1d: error: cannot find source code for runtime library file > 'object.d' > cc1d: not

Re: ARM Cortex-M - Static array dyamically allocated

2013-12-20 Thread Mike
On Saturday, 21 December 2013 at 03:07:45 UTC, H. S. Teoh wrote: On Sat, Dec 21, 2013 at 02:58:49AM +0100, Mike wrote: [...] I should probably add that if I remove my object.d file from the file system, I get: cc1d: error: cannot find source code for runtime library file 'object.d' cc1d: note:

Re: ARM Cortex-M - Static array dyamically allocated

2013-12-20 Thread H. S. Teoh
On Sat, Dec 21, 2013 at 02:58:49AM +0100, Mike wrote: [...] > I should probably add that if I remove my object.d file from the > file system, I get: > > cc1d: error: cannot find source code for runtime library file > 'object.d' > cc1d: note: dmd might not be correctly installed. Run 'dmd -man' for

Re: ARM Cortex-M - Static array dyamically allocated

2013-12-20 Thread Mike
On Saturday, 21 December 2013 at 00:07:17 UTC, Mike wrote: On Friday, 20 December 2013 at 20:18:43 UTC, Timo Sintonen wrote: Object.d seems to be a special case in many ways. When building minlibd I was not able to have an empty or my own object.d and it had to be named object_.d I do not reme

Re: ARM Cortex-M - Static array dyamically allocated

2013-12-20 Thread Mike
On Friday, 20 December 2013 at 20:18:43 UTC, Timo Sintonen wrote: Object.d seems to be a special case in many ways. When building minlibd I was not able to have an empty or my own object.d and it had to be named object_.d I do not remember any more what all the problems were. Object.d (or .di)

Re: ARM Cortex-M - Static array dyamically allocated

2013-12-20 Thread Timo Sintonen
On Friday, 20 December 2013 at 19:14:43 UTC, Timo Sintonen wrote: On Friday, 20 December 2013 at 15:03:52 UTC, Mike wrote: Two questions: 1) These are defined in my object.d, so why is it saying only object.d can define these types? 2) Why is there exactly two instances of each error message?

Re: ARM Cortex-M - Static array dyamically allocated

2013-12-20 Thread Timo Sintonen
On Friday, 20 December 2013 at 15:03:52 UTC, Mike wrote: Two questions: 1) These are defined in my object.d, so why is it saying only object.d can define these types? 2) Why is there exactly two instances of each error message? Again, here's my build line: arm-none-eabi-gdc -march=armv7e-m -m

Re: ARM Cortex-M - Static array dyamically allocated

2013-12-20 Thread Mike
On Wednesday, 18 December 2013 at 15:17:34 UTC, Johannes Pfau wrote: I already have a personal branch with 2.064 backported to the gcc-4.8 branch: https://github.com/jpf91/GDC/commits/arm-old Thanks Iain and Johannes, I've built Johannes's arm-old branch, but I can't yet get to the linke

Re: ARM Cortex-M - Static array dyamically allocated

2013-12-18 Thread Iain Buclaw
On 18 December 2013 15:17, Johannes Pfau wrote: > Am Wed, 18 Dec 2013 14:29:57 + > schrieb Iain Buclaw : > >> >> Hi Mike, >> >> This has been fixed to not call any library routines, but has not been >> backported to the 4.8 branch yet. >> >> This is something that will be done before New Years

Re: ARM Cortex-M - Static array dyamically allocated

2013-12-18 Thread Iain Buclaw
On 18 December 2013 15:17, Johannes Pfau wrote: > Am Wed, 18 Dec 2013 14:29:57 + > schrieb Iain Buclaw : > >> >> Hi Mike, >> >> This has been fixed to not call any library routines, but has not been >> backported to the 4.8 branch yet. >> >> This is something that will be done before New Years

Re: ARM Cortex-M - Static array dyamically allocated

2013-12-18 Thread Johannes Pfau
Am Wed, 18 Dec 2013 14:29:57 + schrieb Iain Buclaw : > > Hi Mike, > > This has been fixed to not call any library routines, but has not been > backported to the 4.8 branch yet. > > This is something that will be done before New Years (if my list of > things to do does not grow even more...)

Re: ARM Cortex-M - Static array dyamically allocated

2013-12-18 Thread Daniel Kozak
On Wednesday, 18 December 2013 at 14:31:31 UTC, Iain Buclaw wrote: On 18 December 2013 14:29, Daniel Kozak wrote: Is this a bug, by design, a temporary convenience? Please advise and offer your suggestions? IMHO it is not a bug. Even static arrays are dynamically allocated and then con

Re: ARM Cortex-M - Static array dyamically allocated

2013-12-18 Thread Daniel Kozak
IMHO it is not a bug. Even static arrays are dynamically allocated and then convert to static. I mean everytime when you write [something, something else, ...] even if all members are known at compile time, it will create dynamic array.

Re: ARM Cortex-M - Static array dyamically allocated

2013-12-18 Thread Iain Buclaw
On 18 December 2013 14:29, Daniel Kozak wrote: > >> Is this a bug, by design, a temporary convenience? Please advise and >> offer your suggestions? > > > IMHO it is not a bug. Even static arrays are dynamically allocated and then > convert to static. > Not anymore, they are not. It makes no sen

Re: ARM Cortex-M - Static array dyamically allocated

2013-12-18 Thread Daniel Kozak
Is this a bug, by design, a temporary convenience? Please advise and offer your suggestions? IMHO it is not a bug. Even static arrays are dynamically allocated and then convert to static. You can write this: uint[3] message; message[0] = 2; message[1] = cast(uint)"hello\r\n".ptr; message[

Re: ARM Cortex-M - Static array dyamically allocated

2013-12-18 Thread Iain Buclaw
On 18 December 2013 14:14, Mike wrote: > I finally got a GDC cross-compiler built for the ARM Cortex-M, and it seems > to generated executable code (code that can be executed). I'm working on > getting a *very* minimal D runtime so I can run a simple semihosted hello > world program as I did with