Jump to page: 1 25  
Page
Thread overview
Hello, folks! Newbie to D, have some questions!
Feb 18, 2017
timmyjose
Feb 18, 2017
ag0aep6g
Feb 18, 2017
timmyjose
Feb 18, 2017
ketmar
Feb 19, 2017
timmyjose
Feb 19, 2017
timmyjose
Feb 19, 2017
ag0aep6g
Feb 20, 2017
timmyjose
Feb 20, 2017
ketmar
Feb 20, 2017
timmyjose
Feb 20, 2017
Adam D. Ruppe
Feb 20, 2017
timmyjose
Feb 20, 2017
ag0aep6g
Feb 20, 2017
timmyjose
Feb 20, 2017
Ali Çehreli
Feb 20, 2017
ketmar
Feb 20, 2017
H. S. Teoh
Feb 21, 2017
ketmar
Feb 19, 2017
ketmar
Feb 19, 2017
Jacob Carlborg
Feb 20, 2017
timmyjose
Feb 20, 2017
ketmar
Feb 20, 2017
H. S. Teoh
Feb 21, 2017
timmyjose
Feb 20, 2017
Ali Çehreli
Feb 21, 2017
timmyjose
Feb 18, 2017
sarn
Feb 19, 2017
Seb
Feb 20, 2017
timmyjose
Feb 18, 2017
sarn
Feb 18, 2017
timmyjose
Feb 18, 2017
Daniel Kozak
Feb 19, 2017
timmyjose
Feb 19, 2017
ketmar
Feb 18, 2017
Moritz Maxeiner
Feb 18, 2017
berni
Feb 19, 2017
timmyjose
Feb 19, 2017
Guillaume Piolat
Feb 20, 2017
timmyjose
Feb 19, 2017
bachmeier
Feb 20, 2017
timmyjose
Feb 21, 2017
Steve Biedermann
Feb 21, 2017
timmyjose
Feb 21, 2017
Ali Çehreli
Feb 22, 2017
timmyjose
Feb 22, 2017
Steve Biedermann
Feb 22, 2017
timmyjose
February 18, 2017
Hello folks,

I am interested in learning D (just starting out, did a few of the exercises on the D tour), and had some questions before I decide to jump right in. My questions are genuinely motivated by my experiences and expectations, so please forgive me if some questions don't come across as well as my intentions!

1. I have some experience with both C and C++, and have been learning Rust for a while, but a few things put me off about the whole business -

a). The core language appears to be simple enough, but becomes increasingly complex as I begin writing larger programs.

b). The whole ownership system is easy to understand, but the APIs become very complicated and unwieldy, and more time appears to be spent on understanding and ensuring that memory is being used correctly than on the core program logic.

c). The whole community seems infused with both the Feminism/SJW (I don't care about those communities, but it feels weird having a programming community get sidetracked by all that bullshit), and too much of Ruby-on-Rails culture (probably started with Steve Klabnik) so that it doesn't feel like any real systems programmers are focusing on that language, and finally, d). The whole language feels like a bit of patchwork of random ideas, and also the whole "safety" and "no segfaults" guarantees seem to have lesser and lesser RoI as time goes by.

Sorry for the rant, I didn't realise I was quite that frustrated! That's just to give some background about me and my recent experiences! :D

In that regard, I suppose I'll get a better feel of the community here as I interact more, but I have high hopes that it'll be much more technical than purely social!

2. I am more interested in learning D as a pure systems programming language so that I can develop my own tools (not looking to develop an OS, just some grep-scale tools to start off with). In that regard, I have a few concerns about the GC. My rudimentary knowledge of the D ecosystem tells me that there is a GC in D, but that can be turned off. Is this correct? Also, some threads online mention that if we do turn off GC, some of the core std libraries may not fully work. Is this presumption also correct?

In this regard, I am curious to know if I would face any issues (with my intent in mind), or will I do just fine? If you could share your experiences and domains of use, that would also be very helpful for me. Secondly, how stable is the language and how fast is the pace of development on D?

Again, sorry for my ignorance if I have been wrong-footed on some (or all) points.


2. I am also curious as to what would be the best path for a complete beginner to D to learn it effectively? I am a relatively fast learner (and I learn better by context, as in, some core unifying idea described and then elucidated through big examples instead of learning in bits and pieces). How did you folks learn D? I'm sure hearing your experiences would be helpful too. Are there any books/video tutorials that you would recommend (aside from this site itself).

3. Are there some small-scale Open Source projects that you would recommend to peruse to get a feel for and learn idiomatic D?

4. I have heard good reports of D's metaprogramming capabilities (ironically enough, primarily from a thread on the Rust user group), and coming from a Common Lisp (and some Racket) background, I am deeply interested in this aspect. Are D macros as powerful as Lisp macros? Are they semantically similar (for instance, I found Rust's macros are quite similar to Racket's)?

5. Supposing I devote the time and energy and get up to speed on D, would the core language team be welcoming if I feel like I can contribute?

That's all off the top of my head at the moment. Perhaps I'll have more questions as I read the responses. Thanks in advance!

Cheers.


February 18, 2017
On Saturday, 18 February 2017 at 20:15:55 UTC, timmyjose wrote:
> 2. I am more interested in learning D as a pure systems programming language so that I can develop my own tools (not looking to develop an OS, just some grep-scale tools to start off with). In that regard, I have a few concerns about the GC. My rudimentary knowledge of the D ecosystem tells me that there is a GC in D, but that can be turned off. Is this correct?

There is a GC, but you can avoid the features that use it. There's a function attribute for that: @nogc [1]. It forbids GC-manages allocations. The GC is still there, but it won't do anything because you're not triggering it.

You can also turn automatic collections off (GC.disable [2]). There's no need for that when all your code is @nogc, though, because collections are triggered by allocations.

As for getting rid of the GC entirely (for saving space, I guess), I think that's more involved. May require changes to druntime. Shouldn't be necessary most of the time.

> Also, some threads online mention that if we do turn off GC, some of the core std libraries may not fully work. Is this presumption also correct?

Yes. Whenever a std function returns a new string or some such it's going to be GC-allocated. There's an experimental module for custom allocators [3], but the rest of the library doesn't make use of it, yet. When a std function uses the GC, the compiler won't let you call it from @nogc code.

> In this regard, I am curious to know if I would face any issues (with my intent in mind), or will I do just fine?

I don't think you're going to run into much trouble when making "grep-scale tools".

[...]
> 4. I have heard good reports of D's metaprogramming capabilities (ironically enough, primarily from a thread on the Rust user group), and coming from a Common Lisp (and some Racket) background, I am deeply interested in this aspect. Are D macros as powerful as Lisp macros?

D doesn't have macros. D has templates like C++, string mixins (insert a statically know/generated string as D code), and CTFE (Compile Time Function Evaluation, to programmatically generate static stuff).

> Are they semantically similar (for instance, I found Rust's macros are quite similar to Racket's)?

Can't answer this, because I'm not familiar enough with those languages.

> 5. Supposing I devote the time and energy and get up to speed on D, would the core language team be welcoming if I feel like I can contribute?

Absolutely. Anyone is welcome to contribute. D is very much a volunteer effort. Also don't hesitate to point out (or even fix) any stumbling blocks you may encounter when starting out.

[1] https://dlang.org/spec/attribute.html#nogc
[2] https://dlang.org/phobos/core_memory.html#.GC.disable
[3] https://dlang.org/phobos/std_experimental_allocator.html
[4] http://ddili.org/ders/d.en/index.html
[5] https://tour.dlang.org/
February 18, 2017
Thanks for the very comprehensive response! I think most of my doubts are cleared now. You're right though that I'm probably worrying too much about GC with my current use case. Also thanks for the links - they should also come in very handy indeed.

I managed to find some book recommendations as well on the site. I've decided to start out with what appears to be the most approachable of them - Programming in D by Ceherli.

>D doesn't have macros. D has templates like C++, string mixins (insert a statically >know/generated string as D code), and CTFE (Compile Time Function Evaluation, to >programmatically generate static stuff).

Ah, I see! Thanks for clarifying that although CTFE as you mentioned it seems to match my specific interest.

I look forward to learning D and being able to contribute some day! :-)

On Saturday, 18 February 2017 at 21:09:20 UTC, ag0aep6g wrote:
> On Saturday, 18 February 2017 at 20:15:55 UTC, timmyjose wrote:
>> [...]
>
> There is a GC, but you can avoid the features that use it. There's a function attribute for that: @nogc [1]. It forbids GC-manages allocations. The GC is still there, but it won't do anything because you're not triggering it.
>
> You can also turn automatic collections off (GC.disable [2]). There's no need for that when all your code is @nogc, though, because collections are triggered by allocations.
>
> As for getting rid of the GC entirely (for saving space, I guess), I think that's more involved. May require changes to druntime. Shouldn't be necessary most of the time.
>
>> [...]
>
> Yes. Whenever a std function returns a new string or some such it's going to be GC-allocated. There's an experimental module for custom allocators [3], but the rest of the library doesn't make use of it, yet. When a std function uses the GC, the compiler won't let you call it from @nogc code.
>
>> [...]
>
> I don't think you're going to run into much trouble when making "grep-scale tools".
>
> [...]
>> [...]
>
> D doesn't have macros. D has templates like C++, string mixins (insert a statically know/generated string as D code), and CTFE (Compile Time Function Evaluation, to programmatically generate static stuff).
>
>> [...]
>
> Can't answer this, because I'm not familiar enough with those languages.
>
>> [...]
>
> Absolutely. Anyone is welcome to contribute. D is very much a volunteer effort. Also don't hesitate to point out (or even fix) any stumbling blocks you may encounter when starting out.
>
> [1] https://dlang.org/spec/attribute.html#nogc
> [2] https://dlang.org/phobos/core_memory.html#.GC.disable
> [3] https://dlang.org/phobos/std_experimental_allocator.html
> [4] http://ddili.org/ders/d.en/index.html
> [5] https://tour.dlang.org/

February 18, 2017
On Saturday, 18 February 2017 at 20:15:55 UTC, timmyjose wrote:
> Hello folks,

Hi :)

> 2. I am more interested in learning D as a pure systems programming language so that I can develop my own tools (not looking to develop an OS, just some grep-scale tools to start off with). In that regard, I have a few concerns about the GC. My rudimentary knowledge of the D ecosystem tells me that there is a GC in D, but that can be turned off. Is this correct? Also, some threads online mention that if we do turn off GC, some of the core std libraries may not fully work. Is this presumption also correct?

Okay, yes, it's easy to turn off or control the GC.  It's also easy to control memory allocation in general (unlike, say, Java, where it's practically impossible to do anything without writing "new").

Also, yes, a lot of the standard library doesn't work if you do that.  A lot does work, but a lot doesn't.  The biggest blocker is the use of exceptions, which currently rely on GC (though there's interest in changing that).

But I think the real answer to your question is in this thread:
https://forum.dlang.org/thread/o6c9tj$2bdp$1@digitalmars.com
(Silicon Valley D Meetup - January 26, 2017 - "High Performance Tools in D" by Jon Degenhardt)

> In this regard, I am curious to know if I would face any issues (with my intent in mind), or will I do just fine? If you could share your experiences and domains of use, that would also be very helpful for me. Secondly, how stable is the language and how fast is the pace of development on D?

When I first started using D about four years ago, it was easy to hit compiler bugs and basic things that didn't work.  It don't find that happens much nowadays when I'm doing everyday programming.

There's plenty of new stuff happening, like escape analysis, but the foundation is getting pretty good.  I think the biggest gap is the number of libraries compared to, say, Python, but personally I'm happy binding to C libraries, and there are plenty of them.

> 2. I am also curious as to what would be the best path for a complete beginner to D to learn it effectively? I am a relatively fast learner (and I learn better by context, as in, some core unifying idea described and then elucidated through big examples instead of learning in bits and pieces). How did you folks learn D? I'm sure hearing your experiences would be helpful too. Are there any books/video tutorials that you would recommend (aside from this site itself).

Some people have written tutorials.  It sounds like you're already experienced with programming, so the fastest way is probably to just dive in.  Get the basics from a small tutorial, then pick a small project (or some practice programming problems) and start coding with the standard library docs on hand :)

> 4. I have heard good reports of D's metaprogramming capabilities (ironically enough, primarily from a thread on the Rust user group), and coming from a Common Lisp (and some Racket) background, I am deeply interested in this aspect. Are D macros as powerful as Lisp macros? Are they semantically similar (for instance, I found Rust's macros are quite similar to Racket's)?

Lisp macros let you rewrite features at the interpreter level.  Walter Bright has explicitly said he doesn't like that kind of macro (I don't think he even likes the C preprocessor's macros).

D's metaprogramming is more constrained in that sense, but it's powerful at code generation (see templates and the "mixin" keyword), compile-time code execution, and compile-time introspection.  Compile-time introspection is one of my favourite features.  If, for example, you need an array of all the names of single argument methods (or whatever) from a class, you can get it.

Take a look at ctRegex in the standard library for a great example of what can be done.

> 5. Supposing I devote the time and energy and get up to speed on D, would the core language team be welcoming if I feel like I can contribute?

I'm not the core team, but I'm confident the answer is yes :)
February 18, 2017
On Saturday, 18 February 2017 at 21:09:20 UTC, ag0aep6g wrote:
>> Also, some threads online mention that if we do turn off GC, some of the core std libraries may not fully work. Is this presumption also correct?
>
> Yes. Whenever a std function returns a new string or some such it's going to be GC-allocated.

This particular problem isn't so bad as it might sound because D string functions are based on ranges.
February 18, 2017
On Saturday, 18 February 2017 at 21:27:55 UTC, sarn wrote:
> On Saturday, 18 February 2017 at 20:15:55 UTC, timmyjose wrote:
>> [...]
>
> Hi :)
>
>> [...]
>
> Okay, yes, it's easy to turn off or control the GC.  It's also easy to control memory allocation in general (unlike, say, Java, where it's practically impossible to do anything without writing "new").
>
> Also, yes, a lot of the standard library doesn't work if you do that.  A lot does work, but a lot doesn't.  The biggest blocker is the use of exceptions, which currently rely on GC (though there's interest in changing that).
>
> But I think the real answer to your question is in this thread:
> https://forum.dlang.org/thread/o6c9tj$2bdp$1@digitalmars.com
> (Silicon Valley D Meetup - January 26, 2017 - "High Performance Tools in D" by Jon Degenhardt)
>
>> [...]
>
> When I first started using D about four years ago, it was easy to hit compiler bugs and basic things that didn't work.  It don't find that happens much nowadays when I'm doing everyday programming.
>
> There's plenty of new stuff happening, like escape analysis, but the foundation is getting pretty good.  I think the biggest gap is the number of libraries compared to, say, Python, but personally I'm happy binding to C libraries, and there are plenty of them.
>
>> [...]
>
> Some people have written tutorials.  It sounds like you're already experienced with programming, so the fastest way is probably to just dive in.  Get the basics from a small tutorial, then pick a small project (or some practice programming problems) and start coding with the standard library docs on hand :)
>
>> [...]
>
> Lisp macros let you rewrite features at the interpreter level.  Walter Bright has explicitly said he doesn't like that kind of macro (I don't think he even likes the C preprocessor's macros).
>
> D's metaprogramming is more constrained in that sense, but it's powerful at code generation (see templates and the "mixin" keyword), compile-time code execution, and compile-time introspection.  Compile-time introspection is one of my favourite features.  If, for example, you need an array of all the names of single argument methods (or whatever) from a class, you can get it.
>
> Take a look at ctRegex in the standard library for a great example of what can be done.
>
>> [...]
>
> I'm not the core team, but I'm confident the answer is yes :)

Wow! That was an excellent response. Thank you!

I'll be sure to check out the thread that you linked in detail (a lot of it went over my head, but I'm sure it'll all make more sense soon). I also managed to dig out the YouTube link from there. :-)

Also, thanks for sharing your experience. It really does help. I was a bit apprehensive because these days rather than the effort, I'm more concerned with the time invested (who isn't, right?), and reading that your experience with D helps put me at ease.

About metaprogramming, yes, that is one part that I'm really interested in, and I would love to explore that area thoroughly!The introspection example is pretty cool! I'm pretty sure I'll have tons of questions once I get going with D, and the community has been very welcoming so far! :-)
February 18, 2017
Dne 18.2.2017 v 21:15 timmyjose via Digitalmars-d-learn napsal(a):

> Hello folks,
>
> I am interested in learning D (just starting out, did a few of the exercises on the D tour), and had some questions before I decide to jump right in. My questions are genuinely motivated by my experiences and expectations, so please forgive me if some questions don't come across as well as my intentions!
>
> 1. I have some experience with both C and C++, and have been learning Rust for a while, but a few things put me off about the whole business -
>
> a). The core language appears to be simple enough, but becomes increasingly complex as I begin writing larger programs.
>
> b). The whole ownership system is easy to understand, but the APIs become very complicated and unwieldy, and more time appears to be spent on understanding and ensuring that memory is being used correctly than on the core program logic.
>
> c). The whole community seems infused with both the Feminism/SJW (I don't care about those communities, but it feels weird having a programming community get sidetracked by all that bullshit), and too much of Ruby-on-Rails culture (probably started with Steve Klabnik) so that it doesn't feel like any real systems programmers are focusing on that language, and finally, d). The whole language feels like a bit of patchwork of random ideas, and also the whole "safety" and "no segfaults" guarantees seem to have lesser and lesser RoI as time goes by.
>
> Sorry for the rant, I didn't realise I was quite that frustrated! That's just to give some background about me and my recent experiences! :D
>
> In that regard, I suppose I'll get a better feel of the community here as I interact more, but I have high hopes that it'll be much more technical than purely social!
Hi, welcome in D community
>
> 2. I am more interested in learning D as a pure systems programming language so that I can develop my own tools (not looking to develop an OS, just some grep-scale tools to start off with). In that regard, I have a few concerns about the GC. My rudimentary knowledge of the D ecosystem tells me that there is a GC in D, but that can be turned off. Is this correct? Also, some threads online mention that if we do turn off GC, some of the core std libraries may not fully work. Is this presumption also correct? In this regard, I am curious to know if I would face any issues (with my intent in mind), or will I do just fine? If you could share your experiences and domains of use, that would also be very helpful for me
>

Yes, by default D use GC. And yes there is a some part of D standard library which uses GC. But it is something you can avoid if you want. I am using D for many years and for almost anything and never have issue with GC.

> Secondly, how stable is the language and how fast is the pace of development on D?
>
> Again, sorry for my ignorance if I have been wrong-footed on some (or all) points.

D stability is good, really good, for many of us too good :P. I have been using D for many years (five or six). And right now there is a big effort to never break anything until it makes really sense.

OTOH D development is quite fast. So there are many improvements with every release

>
>
> 2. I am also curious as to what would be the best path for a complete beginner to D to learn it effectively? I am a relatively fast learner (and I learn better by context, as in, some core unifying idea described and then elucidated through big examples instead of learning in bits and pieces). How did you folks learn D? I'm sure hearing your experiences would be helpful too. Are there any books/video tutorials that you would recommend (aside from this site itself).
I can't help here because I am using D for a long time, so I do not remember how I have learned it.
>
> 3. Are there some small-scale Open Source projects that you would recommend to peruse to get a feel for and learn idiomatic D?

It is maybe not small-scale but idiomatic D code is in phobos itself.

>
> 4. I have heard good reports of D's metaprogramming capabilities (ironically enough, primarily from a thread on the Rust user group), and coming from a Common Lisp (and some Racket) background, I am deeply interested in this aspect. Are D macros as powerful as Lisp macros? Are they semantically similar (for instance, I found Rust's macros are quite similar to Racket's)?
I do not know Lisp macros, but AFAIK there are not semantically similar. OTOH D metaprogramming is really powerful and there has been some proposals to improve that https://wiki.dlang.org/DIP50
>
> 5. Supposing I devote the time and energy and get up to speed on D, would the core language team be welcoming if I feel like I can contribute?
>
> That's all off the top of my head at the moment. Perhaps I'll have more questions as I read the responses. Thanks in advance!
>
> Cheers.
>
>

February 18, 2017
timmyjose wrote:
> Thanks for the very comprehensive response! I think most of my doubts are cleared now. You're right though that I'm probably worrying too much about GC with my current use case.

i can tell you that i'm doing things like, for example, ZX Spectrum emulator and hobbyst videogames (everything in D, even low-level gfx), i never really cared about "avoiding GC", and i can maintain solid 35/50/60 FPS (depending of my needs) with my code.

i.e. that "GC-phobia" (i'm not talking about you specifiallly, of course, sorry) is mostly based on nothing. as GC will never fire "on it's own", and you can control it, avoiding GC is not unnecessary (except some very special cases, of course ;-). the key tech here (as usual) is to not allocate in tight loops, plan your memory discipline and such. nothing new for people used to systems languages. ;-)

sure, you can stop worrying about that and use D as some kind of scripting language too, and still have all the features like type checking. for things like IRC or email client i absolutely don't care about allocations (i.e. doing it left and right) and just letting GC to do it's work. my usual IRC client uptime is several monthes (after that it runs out of memory, but this is 'cause it never does any cleanup on it's data, keeping all logs and db in memory. i am too lazy to finish it. note that is it not a GC fault, it is my code. ;-).
February 18, 2017
On Saturday, 18 February 2017 at 20:15:55 UTC, timmyjose wrote:
> My rudimentary knowledge of the D ecosystem tells me that there is a GC in D, but that can be turned off. Is this correct?

Technically yes; you will lose core functionality, though, if you do.
I don't have the complete list at hand, but e.g. dynamic and associative arrays are one of the things you won't be able to use without the GC IIRC. If you use the reference compiler (dmd), you can use the flag `-vgc` to be shown all the GC allocations in a D program.

On Saturday, 18 February 2017 at 20:15:55 UTC, timmyjose wrote:
> Also, some threads online mention that if we do turn off GC, some of the core std libraries may not fully work. Is this presumption also correct?

Yes. Everything in Phobos that uses features depending on the GC won't work anymore.

On Saturday, 18 February 2017 at 20:15:55 UTC, timmyjose wrote:
> In this regard, I am curious to know if I would face any issues (with my intent in mind), or will I do just fine?

If you don't turn the GC off you should be fine. The GC will - AFAIK - only perform a collection cycle as a result of an allocation call to it, so you can avoid slow collection cycles without turning it off.

On Saturday, 18 February 2017 at 20:15:55 UTC, timmyjose wrote:
> If you could share your experiences and domains of use, that would also be very helpful for me.

I mostly use D for writing tools for my own use that have to interact with C APIs.

On Saturday, 18 February 2017 at 20:15:55 UTC, timmyjose wrote:
> Secondly, how stable is the language and how fast is the pace of development on D?

The parts of the language I need are pretty stable, but I don't think I use even half of what the language offers (D is very complex).
Regarding speed, you can see the numbers (git tags) for yourself here[0].

On Saturday, 18 February 2017 at 20:15:55 UTC, timmyjose wrote:
> 2. I am also curious as to what would be the best path for a complete beginner to D to learn it effectively?

That's usually not something someone can tell you, since every person learns differently.
Personally, when I started with D (back in D1 days) I read the articles about it and then just tried writing tools in it, so I suggest reading these[1]

On Saturday, 18 February 2017 at 20:15:55 UTC, timmyjose wrote:
> I am a relatively fast learner (and I learn better by context, as in, some core unifying idea described and then elucidated through big examples instead of learning in bits and pieces).

I'd describe D's unifying idea as "allow people to write complex, native software without all the C/C++ insanity". Though D comes with it's own share of insanity, of course.

On Saturday, 18 February 2017 at 20:15:55 UTC, timmyjose wrote:
> Are there any books/video tutorials that you would recommend (aside from this site itself).

I personally would not recommend books at the very start of learning a language (if one is already proficient with native programming in general), but only after one has already gotten comfortable with it and is looking for a comprehensive overview.
Regardless, I've heard good things about two books[2][3].
Since I loathe video tutorials I can't add anything on that point.

On Saturday, 18 February 2017 at 20:15:55 UTC, timmyjose wrote:
> 3. Are there some small-scale Open Source projects that you would recommend to peruse to get a feel for and learn idiomatic D?

Technically there's no such thing as idiomatic D as D is multi-paradigm. You can see some sensible idioms here[4], but no, I would not recommend reading anyone's D code just to get a feeling for "idiomatic D".

On Saturday, 18 February 2017 at 20:15:55 UTC, timmyjose wrote:
> 4. I have heard good reports of D's metaprogramming capabilities (ironically enough, primarily from a thread on the Rust user group),

This doesn't surprise me, honestly, since Rust's (compile time) metaprogramming capabilities are below D's and from my experience people in both communities are well aware of that. There are threads on Reddit about this topic if you have the time to dig them up. D's advanced compile time features are one of the main reasons I'm unlikely to switch to anything else for my tools (in my experience there is no other native programming language that let's me get things done as fast - in terms of development time - as D).

On Saturday, 18 February 2017 at 20:15:55 UTC, timmyjose wrote:
> and coming from a Common Lisp (and some  Racket) background, I am deeply interested in this aspect. Are  D macros as powerful as Lisp macros? Are they semantically similar (for instance, I found Rust's macros are quite similar to Racket's)?

D does not have macros, it has compile time function execution[5], templates[6],
 mixins[7], and template mixins[8].

On Saturday, 18 February 2017 at 20:15:55 UTC, timmyjose wrote:
> 5. Supposing I devote the time and energy and get up to speed on D, would the core language team be welcoming if I feel like I can contribute?

I have never tried adding something to druntime or phobos myself, so I'm not in a position to comment on this.

[0] https://github.com/dlang/phobos/releases
[1] http://dlang.org/articles.html
[2] The D Programming Language, Andrei Alexandrescu
[3] Programming in D: Tutorial and Reference, Ali Cehreli
[4] https://p0nce.github.io/d-idioms/
[5] https://tour.dlang.org/tour/en/gems/compile-time-function-evaluation-ctfe
[6] http://dlang.org/templates-revisited.html
[7] http://dlang.org/mixin.html
[8] http://dlang.org/spec/template-mixin.html

February 18, 2017
I'm new here too (never heard of D before 2017).

> c). The whole community seems infused with both the Feminism/SJW

I didn't tried out Rust, but that would draw me away too. (Incidentally it was a comment on alternatives for Rust, that pointed me to D.)

> 2. I am also curious as to what would be the best path for a complete beginner to D to learn it effectively?

I started with the online version of the book of Ali Çehreli but after a while I decided to buy it and was impressed on its size (more than 700 pages!). Meanwhile I'm halfway through.

At the same time I'm working on a project of mine, which I just started writing in C++ last december, because I couldn't find a better language and thought I had to bite the bullet. Meanwhile it's completely rewritten in D (but two lines of C code that I need to use a C-libraray). Whenever I came across a new concept in the book I tried to refactor that project using this concept.

This approach worked very well for me. (And I appreciate this Learn-forum, because else I'd not dare to ask my seemingly silly questions.)

You wrote:
> ... area thoroughly!The introspection ...

I just realised, how much I'm thinking in D allready when I saw this: At first glance I wondered, what this thoroughly-template is about... ;-)

« First   ‹ Prev
1 2 3 4 5