I need to Learn D Programming Language

I originally looked at D a few years ago before the version 1 was released. Now I looked at it and version 2 is released and the features and standard library look kick ass! I think for my next project after Trac will be to settle down and learn D programming language and port my Minecraft Proxy written in Java to D. I’m interested in seeing how much faster it runs and how much lower the memory footprint is.

I think it’d be fun to use the D programing language idioms in implementing the project. I think it would be interesting to use the concurrency module of the standard library and see if I can’t allow some of the more difficult parts of the Java programming faster and more stable in D. Provided if I did it right in Java, then I probably wouldn’t have so many headaches. I’m just curious if I could perhaps use the D standard library for pipe-lining the process for what could be cleaner code. I have to look and see if there is an opengl port to D. If not, then I’ll just attempt to use the C libraries and hope I manage the memory, unless D manages that as well.

Should be fun and I really can’t wait to get started on that in another 2 months. I am excited, because I’ve been meaning to learn C++ and C, Well, D is close enough in design to those languages that I’m hoping that creating solutions in C and C++ will be easier after working with D. My biggest weakness with C and C++ is memory management and really correctly using memory management that is handled by libraries and other third-party APIs. I think that if I can practice with D and C, that it’ll be easier for when I’m going between C and C++.The differences are huge and it’d be better to simply code in C when working with C APIs and code. I’m not sure. I want to use D and see how it works.

I can’t wait! Another reason to finish the Trac project, so I can get started. Of course, I’ll probably still maintain my Java project until the D one gets off the ground and works. I don’t know, I might start coding one weekend for grins and see how far I can get. If i can do the multithreading or socket polling and network code working for Minecraft in a day or two, then I think I can port the rest of the code in less than a week. The OpenGL code will be a little tricky, but since most of the code is one to one to the C API, I shouldn’t have a lot of trouble. The Java API does a lot of the window and input handling and implementing that won’t be that difficult, but will require testing and time.

Then I want to write a simple XMPP server.

Possibly Related Posts:


4 Comments.

  1. I tend to use derelict for my opengl/sfml/openal/etc bindings in D. Be sure to use the 2 svn as it has far more bindings in it. If you haven’t picked up “The D Programming Language” from amazon I would suggest getting that to “get your mind into D”. Finally, don’t know if you read reddit, but you are now on it:http://www.reddit.com/r/programming/comments/i4j4e/i_need_to_learn_d_programming_language/ may be some good tips there

    • oh and feel free to email me if you have any questions, I’ll do my best to help!

    • Derelict looks great. God, this is what I’m talking about! Derelict is beautifully coded, readable by programmers not familiar to the language and gives a greater understanding on how the language works and is coded. That library is exactly what I was looking for, so thanks. I look forward to starting to program D.

      I’ll probably start the network socket programming next weekend and see how far I get with that.

  2. There a OpenGL bindings for langauge D… Really are bindings for SDL (that include OpenGL). It’s called Derelict http://www.dsource.org/projects/derelict.

    Notes: For D2, you need to use Derelict2, and NOT USE DSSS install instructions. dsss actually it’s dead.