whats your favorite thing aboot c++?

Pages: 123
And the destruction of stream is deterministic at the end of the try block, correct? Alright, so it does have RAII. It just calls it something different.
The fact that they implemented this feature shows that someone did complain that non-determinism in the release of resources was a problem, which is exactly my point.
If you want to use an improvement as an argument against a language, then sure.
What against? I'm saying RAII is awesome, that's all.
I'm missing RAII when programming in pure C.
std::pair<std::multimap<uint64_t, uint64_t>::const_iterator, std::multimap<uint64_t, uint64_t>::const_iterator> GetRange(uint64_t Entry) {return m_CMap.equal_range(Entry);}
For some reason it is not formated propertly.

It gets better when you start using that return value in a for loop ;)

EDIT: I know I can use typedefs, but its not cool that way ._.
Last edited on
Has 'cool' acquired yet another meaning? As in 'pointlessly confusing'?
Security through obscurity, anyone?




*sarcasm
Last edited on
If you're not afraid of ticking time bombs, sure thing RB.
1
2
3
4
auto GetRange(uint64_t) -> decltype (m_CMap.equal_range(Entry))
{
    return m_CMap.equal_range(Entry);
}


Much better.
Are you sure? Where is Entry defined? ;)
Nice catch. You may keep it. :)
I see what you did there.
Quite a few days late to see that now, does light travel slowly where you're from? ;)
I just read it that day...
My favorite thing about C++ is it's complexity. This makes it incredibly satisfying when you get it. And stupidly frustrating when you don't. :) Kind of like understanding the human mind. Reminds me of a great quote I heard: "If the human mind was so simple we could understand it, we would be so simple we couldn't."
C++ isn't complex...the English language is complex.
I don't think it's fair to make such comparision. Besides, English language isn't THAT complex, when you compare it to some other natural languages.
Yes, english isn't complex, chinese is...

my favorite thing is the flexibility
English is complex because it has arbitrary, contradictory and inconsistent rules that you can only really get used to with a lot of practice (and even then, most people, even native speakers over the age of 20, make mistakes which have nothing to do with laziness). This is because it's a mixture of a bunch of languages (mostly German, Latin, Greek and French) with lots of loanwords and words and rules that someone just made up at some point (no, really). There are also lots of dialects within the UK itself (I'm not even talking about Scotland, Wales and Ireland, I mean adjacent counties, and even adjacent parts of London). It also relies heavily on context (then again, so does C++) and the position of verbs can change the meaning of a sentence and it can be very ambiguous. It also borrows lots of words from random languages all over the world. Other languages (like Norwegian Bokmål ("book language") and Nynorsk ("new Norwegian", even though it's really old Norwegian)) have regulatory bodies, but English doesn't and never has. In conclusion, English is a horrible language and I feel sorry for everyone who learned it as a second language.
Last edited on
I'm to the point in English where I consider myself very good but also hate the language for its incnsistencies, oddities, and simply stupid aspects. It's also very difficult to be very expressive without explaining the same thing in enough ways that you get the whole picture.

The thing I don't like about languages in general is the cultural attachments. They make old writings so hard to understand because you have no sense of the culture at the time. A good language should be expressive, consistent, and should have no cultural ties or ties to any one specific time period.

I feel sad that English is becoming so global.


I only speak English because it is my first language and I have not yet been required to learn another language.
Last edited on
Pages: 123