Short overview on D

2014-08-03 Thread Bayan Rafeh via Digitalmars-d
A small background on this: I'm a university student about to start my graduation project with two teammates, both of which have a C/Java/Python background and I suggested we use D for our project. They're not familiar with it, so I wrote a short tutorial for them here:

Re: Short overview on D

2014-08-03 Thread Rikki Cattermole via Digitalmars-d
On 3/08/2014 7:36 p.m., Bayan Rafeh wrote: A small background on this: I'm a university student about to start my graduation project with two teammates, both of which have a C/Java/Python background and I suggested we use D for our project. They're not familiar with it, so I wrote a short

Re: Short overview on D

2014-08-03 Thread anonymous via Digitalmars-d
-- Functions -- Ref implies the type is a reference type, i.e. changes inside the functions will change the variable outside the function. in means immutable out is an alias for ref(preferably used for parameters) `ref` doesn't imply a reference, it declares or states or something. `in`

Re: Short overview on D

2014-08-03 Thread Gary Willoughby via Digitalmars-d
On Sunday, 3 August 2014 at 08:07:04 UTC, Rikki Cattermole wrote: Your introduction to templates is far too simplistic. You can use this[1] as a source to beef things up there. http://nomad.so/2013/07/templates-in-d-explained/

Re: Short overview on D

2014-08-03 Thread Bayan Rafeh via Digitalmars-d
Wow clearly I misunderstood a lot of stuff. On Sunday, 3 August 2014 at 08:07:04 UTC, Rikki Cattermole wrote: On 3/08/2014 7:36 p.m., Bayan Rafeh wrote: A small background on this: I'm a university student about to start my graduation project with two teammates, both of which have a

Re: Short overview on D

2014-08-03 Thread Nobody via Digitalmars-d
On Sunday, 3 August 2014 at 07:36:43 UTC, Bayan Rafeh wrote: A small background on this: I'm a university student about to start my graduation project with two teammates, both of which have a C/Java/Python background and I suggested we use D for our project. They're not familiar with it, so

Re: Short overview on D

2014-08-03 Thread Bayan Rafeh via Digitalmars-d
On Sunday, 3 August 2014 at 11:12:45 UTC, Nobody wrote: On Sunday, 3 August 2014 at 07:36:43 UTC, Bayan Rafeh wrote: A small background on this: I'm a university student about to start my graduation project with two teammates, both of which have a C/Java/Python background and I suggested we

Re: Short overview on D

2014-08-03 Thread anonymous via Digitalmars-d
On Sunday, 3 August 2014 at 10:57:26 UTC, Bayan Rafeh wrote: -- Functions -- Ref implies the type is a reference type [...] `ref` doesn't imply a reference, it declares or states or something. I'm basing this on the wiki: http://dlang.org/function.html ref parameter is passed by

Re: Short overview on D

2014-08-03 Thread Rikki Cattermole via Digitalmars-d
On 3/08/2014 10:57 p.m., Bayan Rafeh wrote: Wow clearly I misunderstood a lot of stuff. On Sunday, 3 August 2014 at 08:07:04 UTC, Rikki Cattermole wrote: On 3/08/2014 7:36 p.m., Bayan Rafeh wrote: A small background on this: I'm a university student about to start my graduation project with

Re: Short overview on D

2014-08-03 Thread Bayan Rafeh via Digitalmars-d
Small question. Can anyone give me an example of when one would use a parametrized block as opposed to a parameterized class or method?

Re: Short overview on D

2014-08-03 Thread Rikki Cattermole via Digitalmars-d
On 3/08/2014 11:53 p.m., Bayan Rafeh wrote: Small question. Can anyone give me an example of when one would use a parametrized block as opposed to a parameterized class or method? mixin templates take the context for which they are mixed in. Basically: mixin template FooT() { void

Re: Short overview on D

2014-08-03 Thread Bayan Rafeh via Digitalmars-d
On Sunday, 3 August 2014 at 11:56:32 UTC, Rikki Cattermole wrote: On 3/08/2014 11:53 p.m., Bayan Rafeh wrote: Small question. Can anyone give me an example of when one would use a parametrized block as opposed to a parameterized class or method? mixin templates take the context for which

Re: Short overview on D

2014-08-03 Thread Rikki Cattermole via Digitalmars-d
On 4/08/2014 12:30 a.m., Bayan Rafeh wrote: On Sunday, 3 August 2014 at 11:56:32 UTC, Rikki Cattermole wrote: On 3/08/2014 11:53 p.m., Bayan Rafeh wrote: Small question. Can anyone give me an example of when one would use a parametrized block as opposed to a parameterized class or method?

Re: Short overview on D

2014-08-03 Thread Bayan Rafeh via Digitalmars-d
On Sunday, 3 August 2014 at 13:27:40 UTC, Rikki Cattermole wrote: On 4/08/2014 12:30 a.m., Bayan Rafeh wrote: On Sunday, 3 August 2014 at 11:56:32 UTC, Rikki Cattermole wrote: On 3/08/2014 11:53 p.m., Bayan Rafeh wrote: Small question. Can anyone give me an example of when one would use a