function declaration in parameter list

2013-04-30 Thread Jay Norwood
On Saturday, 6 April 2013 at 14:50:50 UTC, Bruno Medeiros wrote: Interesting thread. I've been working on a hand-written D parser (in Java, for the DDT IDE) and I too have found a slew of grammar spec issues. Some of them more serious than the ones you mentioned above. In same cases it's actual

Re: WinAPI callbacks and GC

2013-04-30 Thread Sean Kelly
On Apr 23, 2013, at 2:21 PM, Jack Applegame wrote: > > According WinAPI documentation, CtrlHandler will be called in new additional > thread. Is it safe to allocate GC memory in NOT Phobos threads? > If not, how to make it safe? I'm trying call thread_attachThis() at the > beginning of CtrlHand

Re: how hash_t toHash() works?

2013-04-30 Thread Ivan Kazmenko
- import std.functional; ... RedBlackTree !(MyRecord, binaryFun!"a.key < b.key", true) cont; ... cont = redBlackTree !("a.key < b.key", true, MyRecord) (); - Error: template instance RedBlackTree!(ValueRecord, binaryFun, true) RedBlackTree!(ValueRecord, binaryFun, true) does

Re: starting with GUI

2013-04-30 Thread Carlos
A wild guess: import gtk.Entry; Thank you I just did that some minutes ago ( a good guess ). Now I'm trying to work on the layout so I can finally enter in signals if that's how GTKD works.

Re: starting with GUI

2013-04-30 Thread anonymous
On Tuesday, 30 April 2013 at 17:03:07 UTC, Carlos wrote: I;m trying to add a Entry but I get the following error: "mywindow.d(12): Error: undefined identifier Entry" Here is my code : "window.add(new Entry("Minsit"));" I'm just guessing to see if everything is that simple. So I have to defin

Re: starting with GUI

2013-04-30 Thread Carlos
Another version of the CLI which tries to keep 1440 minutes for a complete day ( this is desired on the GUI ) is : " import std.stdio; import std.c.stdlib; void main() { immutable sitc = 1.66; immutable sleepc = 1.08; float tcsleep, tcsit, tc; int minsleep, minsit; write("Input minutes sit : \n"

starting with GUI

2013-04-30 Thread Carlos
I;m trying to add a Entry but I get the following error: "mywindow.d(12): Error: undefined identifier Entry" Here is my code : "window.add(new Entry("Minsit"));" I'm just guessing to see if everything is that simple. So I have to define the Entry. How do I do that ? ( Any tutorials from the

Re: how hash_t toHash() works?

2013-04-30 Thread gedaiu
On Monday, 29 April 2013 at 16:01:15 UTC, Ivan Kazmenko wrote: one more question What is the type of cont? auto cont = redBlackTree !("a.key < b.key", true, MyRecord) (); I want to use this as a property in a class and i can't use there auto keyword... I tried different types but it did not w

Re: Arrays of functions, function signatures and template instantiation

2013-04-30 Thread anonymous
On Tuesday, 30 April 2013 at 10:02:07 UTC, JR wrote: [...] For instance, is it possible to have MatrixWalker's F type to have a default value of a NOP void function(), have the innermost foreach loop check if the element is a function, and if so call it directly without needing FuncRunner at al

Re: Arrays of functions, function signatures and template instantiation

2013-04-30 Thread JR
On Tuesday, 30 April 2013 at 09:18:56 UTC, anonymous wrote: On Tuesday, 30 April 2013 at 08:42:57 UTC, JR wrote: On Tuesday, 30 April 2013 at 02:38:27 UTC, anonymous wrote: Don't know what's going wrong there. It works for me: http://dpaste.dzfl.pl/5c71f80e My bad, I switched the wrong runn

Re: Arrays of functions, function signatures and template instantiation

2013-04-30 Thread anonymous
On Tuesday, 30 April 2013 at 08:42:57 UTC, JR wrote: On Tuesday, 30 April 2013 at 02:38:27 UTC, anonymous wrote: To get rid of the cast: [...] Instantiating the template with a function parameter causes a compilation error when actually calling the function; -- asdf.d:13: Error: v

Re: Arrays of functions, function signatures and template instantiation

2013-04-30 Thread JR
On Tuesday, 30 April 2013 at 02:38:27 UTC, anonymous wrote: To get rid of the cast: [...] Instantiating the template with a function parameter causes a compilation error when actually calling the function; -- asdf.d:13: Error: variable asdf.MatrixWalker!(@system void(string major,