Re: DMD different compiler behaviour on Linux and Windows

2019-04-26 Thread Mike Parker via Digitalmars-d-learn
On Friday, 26 April 2019 at 15:48:51 UTC, Ron Tarrant wrote: On Thursday, 25 April 2019 at 20:38:31 UTC, Mike Parker wrote: If you compile with -m32 on Windows the error goes away. Not trying to be a but it also works with -m64 on Windows. Yes, thanks. That's a typo. -m32, where size_t is

Re: DMD different compiler behaviour on Linux and Windows

2019-04-26 Thread Ron Tarrant via Digitalmars-d-learn
On Thursday, 25 April 2019 at 20:38:31 UTC, Mike Parker wrote: If you compile with -m32 on Windows the error goes away. Not trying to be a but it also works with -m64 on Windows.

Re: DMD different compiler behaviour on Linux and Windows

2019-04-25 Thread Mike Parker via Digitalmars-d-learn
On Thursday, 25 April 2019 at 20:18:28 UTC, Zans wrote: import std.stdio; void main() { char[] mychars; mychars ~= 'a'; long index = 0L; writeln(mychars[index]); } Why would the code above compile perfectly on Linux (Ubuntu 16.04), however it would produce the following error

Re: DMD different compiler behaviour on Linux and Windows

2019-04-25 Thread Patrick Schluter via Digitalmars-d-learn
On Thursday, 25 April 2019 at 20:18:28 UTC, Zans wrote: import std.stdio; void main() { char[] mychars; mychars ~= 'a'; long index = 0L; writeln(mychars[index]); } Why would the code above compile perfectly on Linux (Ubuntu 16.04), however it would produce the following error

DMD different compiler behaviour on Linux and Windows

2019-04-25 Thread Zans via Digitalmars-d-learn
import std.stdio; void main() { char[] mychars; mychars ~= 'a'; long index = 0L; writeln(mychars[index]); } Why would the code above compile perfectly on Linux (Ubuntu 16.04), however it would produce the following error on Windows 10: source\app.d(8,21): Error: cannot