Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon. Entire thread

Let's Code in D

Name: Anonymous 2012-02-02 9:08

Hey /prog/, why aren't you writing D, God's gift to programmers? Let's get this ball rolling.

import std.stdio;

template factorial(int n)
{
    const factorial = n * factorial!(n-1);
}

template factorial(int n : 1)
{
    const factorial = 1;
}

void main(string[] argv)
{
   writeln(factorial!(10));
}

Name: Anonymous 2012-02-02 13:41

>>11

Native compiled code
You do realize only 2 of the 5 languages I mentioned don't compile to native code? And it's not like they're the only languages better than D.


Clean syntax
trololol
C syntax (not that nice to begin with) with all kinds of crap bolted on, you call that clean?


Statically typed with type inference
3 of the languages I mentioned have far superior type inference.


c++ vs D
Comparing to sepples makes no sense. Sepples is used because it's ubiquitous, not because it's a good language. If you want to replace it with an unpopular language you have to compete with other unpopular alternatives.


Out-of-the-box support for contract programming
Oh ye, Eiffel is also better than D, thanks for reminding me.


Support for purely functional programming
I say lisp, haskell, scala, ocaml and lisp are better than D and your counter argument is functional programming support. Are you fucking kidding me?


Vastly improved and simplified OOP
Improved OO? Any new OO language that doesn't adhere to the uniform access principle can suck my ass.

Newer Posts
Don't change these.
Name: Email:
Entire Thread Thread List