January 16, 2002 User-defined types | ||||
---|---|---|---|---|
| ||||
Posted in reply to Walter | "Walter" <walter@digitalmars.com> wrote in message news:a24id1$1uqg$1@digitaldaemon.com... > > "Juan Carlos Arevalo Baeza" <jcab@roningames.com> wrote in message news:a20eab$28mc$1@digitaldaemon.com... > > Instead of adding complex numbers and whatnot to the > > language (for performance reasons and to avoid user-defined overloaded > > operators), the language should allow those complex numbers (and vectors, > > and matrices, etc...) to be easily created and integrated as libraries. > Keep > > the core language simple, and allow libraries to add the complex bits. That's my opinion. It's one of the strengths of C++, even if it's somewhat > > incomplete and with rough corners there. > > It's not at all easy to create user-defined types with overloaded operators > in C++. Well... no. Generally speaking, no simple task is easy in C++. The main problem with that language (and its main strength, too) is that it's more like an untidy and quite full bag of tools. Many of those tools need "qualified experts" to handle them, though. This means that you can do A LOT of different things with the language, but it also means that the result is never optimal. Salutaciones, JCAB |
January 16, 2002 Re: User-defined types | ||||
---|---|---|---|---|
| ||||
Posted in reply to Juan Carlos Arevalo Baeza | "Juan Carlos Arevalo Baeza" <jcab@roningames.com> wrote in message news:a24nrc$2217$1@digitaldaemon.com... > Well... no. Generally speaking, no simple task is easy in C++. The main > problem with that language (and its main strength, too) is that it's more > like > an untidy and quite full bag of tools. Many of those tools need "qualified > experts" to handle them, though. This means that you can do A LOT of > different things with the language, but it also means that the result is > never optimal. > > Salutaciones, > JCAB C++ does have a lot of tools in it. But it's missing important features like: 1) garbage collection 2) design by contract 3) support for unit testing It certainly is possible to use garbage collection with C++, and I do so myself. But two words that describe using gc with C++ are do it "very carefully". Garbage collectors for C++ have not caught on likely for that reason. You can emulate DBC in C++ with a collection of ungainly macros and virtual functions. The result is not too attractive. Ditto for unit testing. Of course, everything you can do in C++ can also be done in C, as cfront proves <g>. |
January 17, 2002 Re: Properties | ||||
---|---|---|---|---|
| ||||
Posted in reply to Juan Carlos Arevalo Baeza | It has a lot of interesting things, things I'd want C++ to have, but yeah probably C++ will remain my main tool for a while. I could get some use out of D for making tools perhaps. Stuff like Perl and Ruby are just too wierd for me. C++ is kind of a pain for little tools. I can only hope the new C++ standard committee maybe learns a few things from D and C# and other more modern languages. Sean "Juan Carlos Arevalo Baeza" <jcab@roningames.com> wrote in message news:a24nq2$2211$1@digitaldaemon.com... > "Sean L. Palmer" <spalmer@iname.com> wrote in message news:a24ln6$20tb$1@digitaldaemon.com... > > "Walter" <walter@digitalmars.com> wrote in message news:a24id1$1uqg$1@digitaldaemon.com... > > > > > > It's not at all easy to create user-defined types with overloaded > > operators > > > in C++. > > > > Luckily those few brave souls who actually know how can just make a > library > > for use by the masses that can't figure it out. > > > > With D, *nobody* can make types with overloaded operators except you, Walter. > > :) I guess you and I agree that D is not for us, Sean. It does make for > some very interesting discussions, though. And the whole DBC thing is very > cool indeed. > > Salutaciones, > JCAB > > > |
January 17, 2002 Re: User-defined types | ||||
---|---|---|---|---|
| ||||
Posted in reply to Walter | "Walter" <walter@digitalmars.com> wrote in message news:a24t94$25gp$1@digitaldaemon.com... > C++ does have a lot of tools in it. But it's missing important features > like: > 1) garbage collection > 2) design by contract > 3) support for unit testing Well, D also has a lot of tools in it (GC, DBC, unittests). But it's missing important features like: 1) operator overloading 2) templates 3) adequate support for strings =) |
January 17, 2002 Re: User-defined types | ||||
---|---|---|---|---|
| ||||
Posted in reply to Pavel Minayev | oops, forgot default values for function parameters! =) |
January 17, 2002 Re: User-defined types | ||||
---|---|---|---|---|
| ||||
Posted in reply to Pavel Minayev | Pavel Minayev wrote: > Well, D also has a lot of tools in it (GC, DBC, unittests). But it's missing > important features like: > > 1) operator overloading > 2) templates Come on, lay off of Walter. He's expressed the intent to support some form of generic programming at some point in the future. And he _will_ come around on operator overloading or I'll break his thumbs. > 3) adequate support for strings Adequate meaning "having a dedicated comparison operator?" -RB |
January 17, 2002 Re: User-defined types | ||||
---|---|---|---|---|
| ||||
Posted in reply to Russell Borogove | "Russell Borogove" <kaleja@estarcion.com> wrote in message news:3C4706DD.7070306@estarcion.com... > > 3) adequate support for strings > > > Adequate meaning "having a dedicated comparison operator?" Heh, yes! |
Copyright © 1999-2021 by the D Language Foundation