Re: Should the "front" range primitive be "const" ?

2018-03-23 Thread Drone1h via Digitalmars-d-learn
On Monday, 19 March 2018 at 00:50:06 UTC, Jonathan M Davis wrote: On Monday, March 19, 2018 00:14:11 Drone1h via Digitalmars-d-learn wrote: I am not sure whether I can make it work with "inout" instead of "const". Perhaps I am missing something. ... May I ask that you confirm that this is what

Re: Compile time initialization of AA

2018-03-23 Thread Seb via Digitalmars-d-learn
On Friday, 23 March 2018 at 22:43:47 UTC, Xavier Bigand wrote: I am trying to initialize an global immutable associative array of structs, but it doesn't compile. I am getting the following error message : "Error: not an associative array initializer". As I really need to store my data for a c

Re: Compile time initialization of AA

2018-03-23 Thread Ali Çehreli via Digitalmars-d-learn
On 03/23/2018 03:43 PM, Xavier Bigand wrote: > I am trying to initialize an global immutable associative array of > structs, but it doesn't compile. Current solution is to initialize the AA in a 'static this()' block or ('shared static this()'). > I am getting the following error message : "Er

Compile time initialization of AA

2018-03-23 Thread Xavier Bigand via Digitalmars-d-learn
I am trying to initialize an global immutable associative array of structs, but it doesn't compile. I am getting the following error message : "Error: not an associative array initializer". As I really need to store my data for a compile time purpose if we can't do that with AA, I'll use array

Re: remote execute program

2018-03-23 Thread Ali Çehreli via Digitalmars-d-learn
On 03/23/2018 12:25 PM, Cecil Ward wrote: > On Friday, 23 March 2018 at 01:23:56 UTC, Cecil Ward wrote: >> I am wanting to write a short program (on a ‘server’ you could say) >> that takes a command, runs it (as on the command line, so an >> executable with arguments or a shell command) and return

Re: remote execute program

2018-03-23 Thread Cecil Ward via Digitalmars-d-learn
On Friday, 23 March 2018 at 01:23:56 UTC, Cecil Ward wrote: I am wanting to write a short program (on a ‘server’ you could say) that takes a command, runs it (as on the command line, so an executable with arguments or a shell command) and returns a 3-tuple with an int for the return code, plus

Re: remote execute program

2018-03-23 Thread Cecil Ward via Digitalmars-d-learn
On Friday, 23 March 2018 at 07:57:33 UTC, Kagamin wrote: You can just read the whole request into a buffer and parse it there. Agreed.

Re: Issue with traits usability

2018-03-23 Thread Meta via Digitalmars-d-learn
On Wednesday, 21 March 2018 at 15:36:01 UTC, Márcio Martins wrote: Hi! How do I get past this? static struct X { int x; private enum T = 1; private alias M = string; } foreach (Member; __traits(allMembers, X)) { pragma(msg, __traits(getProtection, __traits(getMember,

Reactive data

2018-03-23 Thread crimaniak via Digitalmars-d-learn
I want to have reactive variables like in this example: ``` USING_REACTIVE_DOMAIN(D) // The two words VarSignalT firstWord = MakeVar(string( "Change" )); VarSignalT secondWord = MakeVar(string( "me!" )); // ... SignalT bothWords = firstWord + string( " " ) + secondWord; ``` from this page:

Re: Building Derelict based application under windows

2018-03-23 Thread ANtlord via Digitalmars-d-learn
On Friday, 23 March 2018 at 01:18:02 UTC, Mike Parker wrote: On Thursday, 22 March 2018 at 20:51:36 UTC, ANtlord wrote: Thanks in advance. Please feel free to ask any question Your errors with the derelict libs are linker errors, with the early ones being this one: "warning LNK4003: invali

Re: cannot access frame of function

2018-03-23 Thread Alex via Digitalmars-d-learn
On Friday, 23 March 2018 at 03:38:22 UTC, Jordan Wilson wrote: I have this same issue. Anyone have any thoughts on a workaround? For completeness: https://issues.dlang.org/show_bug.cgi?id=17841

Re: #import mapi.h

2018-03-23 Thread Martin Tschierschke via Digitalmars-d-learn
On Friday, 23 March 2018 at 01:12:58 UTC, Mike Parker wrote: On Thursday, 22 March 2018 at 21:45:40 UTC, Martin Tschierschke wrote: On Thursday, 22 March 2018 at 17:42:46 UTC, Paul Backus wrote: On Wednesday, 21 March 2018 at 16:22:45 UTC, Martin Tschierschke wrote: Is there an step by step int

Re: remote execute program

2018-03-23 Thread Kagamin via Digitalmars-d-learn
Or this: https://github.com/nextcardgame/lighttp/blob/master/examples/chat.d

Re: remote execute program

2018-03-23 Thread Kagamin via Digitalmars-d-learn
You can just read the whole request into a buffer and parse it there.