Programming Forums

Programming Forums (http://www.programmingforums.org/forumindex.php)
-   Other Programming Languages (http://www.programmingforums.org/forum38.html)
-   -   The D programming language (http://www.programmingforums.org/showthread.php?t=10798)

Baphomet Jul 21st, 2006 5:53 PM

The D programming language
 
I just read this on OSNews and found it rather intersting:

Quote:

D is a (relatively) new addition to the C family of programming languages, intended as a successor to C++ but also incorporating ideas and improvements from other C-like languages such as Java and C#. It is an object-oriented, garbage-collected, systems programming language that is compiled to executable rather than bytecode. The specification and reference compiler are currently at version 0.82, and are expected to reach 1.0 within the year. The reference compiler runs on both Windows and Linux x86, and the frontend if Open-Sourced. A port of the frontend to GCC is underway and already functional on Linux x86 and Mac OS X.

Maintained by Walter Bright, author of the Digital Mars C/C++ compilers and former compiler programmer for both Zorland and Symantec, is the language's primary author and maintains the reference implementation, though most if not all language decisions are made only after discussion on the D newsgroup.
Has anyone heard of this language? The article says that it is maintained by Walter Bright, the author of the Digital Mars compilers. The language looks rather good at first glance.

big_k105 Jul 21st, 2006 6:02 PM

I looked at it alittle bit quite a while back but never actually played with it. I have been thinking about trying it out. It seemed pretty good when I initially looked at it but I really don't know much about it other then what I have read.

Prm753 Jul 21st, 2006 6:25 PM

I have heard of it, and was going to try it, but never got around to configuring it for my computer. :p

grumpy Jul 21st, 2006 6:43 PM

A link to an official source of information is here.

Like any language, this one includes it's share of pros and cons. Personally, I consider it useful but unnecessarily restrictive. I wouldn't describe it as a language for beginners, but you don't need a PhD in computer science either: using it well requires a fair amount of experience with software development (eg design techniques).

Game_Ender Jul 22nd, 2006 12:01 PM

The one knock I have heard is that you can't get rid of the garbage collection. I believe the website used to calls it "optional" but it really isn't. Besides that D is a really cool language.

With D templates you can create a regular expression parser completely with templates.

EDIT: I don't think D is any more for advanced users than C++ is.

Baphomet Jul 22nd, 2006 2:05 PM

I like C++ though. What I've been looking for is another language like, it(not in syntax, necessarily). I haven't found one.

Eoin Jul 22nd, 2006 2:47 PM

Quote:

Originally Posted by Game_Ender
With D templates you can create a regular expression parser completely with templates.

I believe this is also possible in C++ either with the cuurrent Boost.Spirit framework or the upcoming Boost.Xpressive library.

uman Jul 22nd, 2006 3:10 PM

There is a language exactly like C++. It's called "C++".

What's the use in saying "I want to use a language like some other language X"? Just use X.

JimmyJim Jul 22nd, 2006 3:32 PM

It looks interesting. It appears to have the advantages of modern languages like C# and java but without the need for a VM and with all of the low level ability of C and C++.

One big drawback i can see is that its not backward compatible with C/C++. It would mean a major rewrite of your code if you were to port an application to it. This would probably mean most commercial software companies will stay with what they know and that means C++. There is no reason to upgrade just because its a shinny new language.

From my point of view its just a modernisation of C++. I dont see that its really needed, C++ with all the Boost libs and other tools(there are some GC libs i believe and other goodness out there) makes it just as modern as java or c#.

Game_Ender Jul 22nd, 2006 4:00 PM

You should spend some more time reading the docs. The language comparison can point in the direction of some good ones. It looks like the author spent a lot of time trying to make things that hard in C++ cleaner in D. Have a look at the exception safety and templates articles.

I am not sure there will ever be successor to C++ that is backwards compatible to it. People have learned from the C to C++ compatibility issue that you can bring to much baggage into a language like that. Another advantage to D is that it will have standard ABI, just like C. Providing a much better interoperability between libraries, compiler's and other languages. The lack of a standard ABI is pretty big short coming for C++.

About Regex, templates, and C++: Yes it is possible and has been done in C++, but (and this is a big one), the expressions don't look like regular expressions. In D the template acts on the string literal.

EDIT: Garbage collection and having to using mixins instead of multiple inheritance are to biggest gripes with D from the design stand point. I have not developed anything in D so I can't say whether they actually hurt program design much. I think once the DTL (D template library) is finished we will have a good measure of how D can stand up to C++.


All times are GMT -5. The time now is 12:22 AM.

Powered by vBulletin® Version 3.7.0, Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Copyright ©2007 DaniWeb® LLC