Home » Community » Coffee corner » C++ FQA
Re: C++ FQA [message #12522 is a reply to message #12521] |
Wed, 07 November 2007 11:33 |
cbpporter
Messages: 1401 Registered: September 2007
|
Ultimate Contributor |
|
|
I've read a good deal of the FQA (and the FAQ too) and while it is mostly right, it is also strongly biased. It still makes a point though, and I think a lot of people agree that C++ is too complicated for it's and everybody else's sake. I would love for an alternative, something that is more simple, straight-forward, but still powerful.
Right now D could be the only alternative (C++0x is even more complicated and redundant). I used D for 2500+ line project (which in C++ would have been about 4000-5000 lines) with about 20 files and I think I have a pretty good idea of what it can do. It has some strong points:
1. True module support.
No more including hundreds of kilobytes if not megabytes of header files in each compilation unit. No more writing every ddecalration twice. Modules act like Java packages, can be fully qualified to avoid name clashes and can be combined to create a library with different access levels. And because each module is compiled only once, D is lightning fast. My entire project compiled from scratch almost instantly, and if I only modified the content of a function or other miner detail, truly instantly.
2. A lot of built in features, like variable length array and hash maps, which combined with some extra functions, can be used to create types like Vector or Map, but even more easy to use and without templates. char[] and about 10 extra functions could make String and StringBuffer obsolete.
3. Templates + mixins + static ifs are stronger than templates in C++ + preprocessor. I never used them, because you can do in D a lot more without templates than in C++.
4. Optional (but defaulted to true) garbage collection.
As much as you could dislike the idea of garbage collection, memory management in C++ is a nightmare, and from this point of view, even U++ which has a lot less such issues, is not able to give such pain free management.
But is also has some disadvantages. Mostly because it has been branched to D 1.0, which is stable, and 2.0 which is a moving target, is not compatible with 1.0, and is a little more complex. It introduces const correctness as in C++, but D can live a lot easier without such extra access methods to have to deal with. Also, the standard library is widely disliked, and a third party library has been created, which is pretty good (even though a little to C++ style), but cross linking between the libraries is impossible. Also operator overloading is just a little bit less powerful.
Still, it is quite a good programing language, having a lot of pain free features and performance comparable to C/C++. I would love to see such a great GUI library as U++ for D, and I'm sure it will continue to evolve.
|
|
|
|
|
C++ FQA
By: unodgs on Tue, 06 November 2007 23:27
|
|
|
Re: C++ FQA
|
|
|
Re: C++ FQA
By: unodgs on Wed, 07 November 2007 10:40
|
|
|
Re: C++ FQA
|
|
|
Re: C++ FQA
By: unodgs on Wed, 07 November 2007 13:15
|
|
|
Re: C++ FQA
|
|
|
Re: C++ FQA
|
|
|
Re: C++ FQA
|
|
|
Re: C++ FQA
|
|
|
Re: C++ FQA
|
|
|
Re: C++ FQA
By: mirek on Thu, 08 November 2007 05:34
|
|
|
Re: C++ FQA
By: Zardos on Thu, 08 November 2007 13:33
|
|
|
Re: C++ FQA
By: mirek on Thu, 08 November 2007 19:25
|
|
|
Re: C++ FQA
By: mdelfede on Thu, 08 November 2007 23:39
|
|
|
Re: C++ FQA
By: mirek on Fri, 09 November 2007 08:51
|
|
|
Re: C++ FQA
By: mdelfede on Fri, 09 November 2007 13:41
|
|
|
Re: C++ FQA
By: mirek on Fri, 09 November 2007 14:48
|
|
|
Re: C++ FQA
By: mdelfede on Fri, 09 November 2007 15:52
|
|
|
Re: C++ FQA
By: waxblood on Fri, 09 November 2007 17:07
|
|
|
Re: C++ FQA
By: mdelfede on Fri, 09 November 2007 19:51
|
|
|
Re: C++ FQA
By: mirek on Sat, 10 November 2007 15:14
|
|
|
Re: C++ FQA
By: mdelfede on Sat, 10 November 2007 17:06
|
|
|
Re: C++ FQA
|
|
|
Re: C++ FQA
By: mirek on Sat, 10 November 2007 17:54
|
|
|
Re: C++ FQA
By: mdelfede on Sat, 10 November 2007 23:57
|
|
|
Re: C++ FQA
By: mirek on Sun, 11 November 2007 09:54
|
|
|
Re: C++ FQA
By: mdelfede on Sun, 11 November 2007 11:25
|
|
|
Re: C++ FQA
By: Zardos on Tue, 13 November 2007 01:56
|
|
|
Re: C++ FQA
By: mirek on Tue, 13 November 2007 09:25
|
|
|
Re: C++ FQA
|
|
|
Re: C++ FQA
By: mirek on Tue, 13 November 2007 10:52
|
|
|
Re: C++ FQA
By: mirek on Thu, 22 November 2007 05:43
|
|
|
Re: C++ FQA
By: mdelfede on Sun, 11 November 2007 11:36
|
|
|
Re: C++ FQA
|
|
|
Re: C++ FQA
By: mdelfede on Sun, 11 November 2007 18:52
|
|
|
Re: C++ FQA
|
|
|
Re: C++ FQA
By: mirek on Mon, 12 November 2007 09:46
|
|
|
Re: C++ FQA
By: mdelfede on Mon, 12 November 2007 10:19
|
|
|
Re: C++ FQA
|
|
|
Re: C++ FQA
By: mdelfede on Mon, 12 November 2007 11:43
|
|
|
Re: C++ FQA
|
|
|
Re: C++ FQA
By: mdelfede on Mon, 12 November 2007 16:47
|
|
|
Re: C++ FQA
|
|
|
Re: C++ FQA
By: mirek on Mon, 12 November 2007 20:15
|
|
|
Re: C++ FQA
By: mirek on Mon, 12 November 2007 20:21
|
|
|
Re: C++ FQA
|
|
|
Re: C++ FQA
By: mirek on Mon, 12 November 2007 22:43
|
|
|
Re: C++ FQA
|
|
|
Re: C++ FQA
By: mirek on Mon, 12 November 2007 23:34
|
|
|
Re: C++ FQA
By: mdelfede on Mon, 12 November 2007 23:33
|
|
|
Re: C++ FQA
By: exolon on Tue, 13 November 2007 17:30
|
|
|
Re: C++ FQA
By: mdelfede on Tue, 13 November 2007 18:24
|
|
|
Re: C++ FQA
By: exolon on Tue, 13 November 2007 18:58
|
|
|
Re: C++ FQA
|
|
|
Re: C++ FQA
By: mirek on Fri, 16 November 2007 11:59
|
|
|
Re: C++ FQA
By: waxblood on Fri, 16 November 2007 16:24
|
|
|
Re: C++ FQA
By: mdelfede on Fri, 16 November 2007 16:37
|
|
|
Re: C++ FQA
By: mirek on Sat, 17 November 2007 10:04
|
|
|
Re: C++ FQA
By: mirek on Sat, 10 November 2007 15:22
|
|
|
Re: C++ FQA
By: mdelfede on Sat, 10 November 2007 16:58
|
|
|
Re: C++ FQA
By: mirek on Thu, 08 November 2007 05:25
|
|
|
Re: C++ FQA
By: mirek on Wed, 07 November 2007 15:14
|
|
|
Re: C++ FQA
By: mdelfede on Wed, 07 November 2007 15:39
|
|
|
Re: C++ FQA
By: exolon on Mon, 12 November 2007 13:09
|
|
|
Re: C++ FQA
By: mr_ped on Wed, 07 November 2007 17:05
|
|
|
Re: C++ FQA
|
|
|
Re: C++ FQA
By: mr_ped on Sat, 10 November 2007 22:26
|
|
|
Re: C++ FQA
By: mirek on Sat, 10 November 2007 22:35
|
|
|
Re: C++ FQA
|
|
|
Re: C++ FQA
|
Goto Forum:
Current Time: Tue May 07 12:56:21 CEST 2024
Total time taken to generate the page: 0.05003 seconds
|