Hacker News new | ask | show | jobs
by Abednego 5579 days ago
Thanks for the summary. This is my code. I've since switched to using "Bst" instead of "BST" for class names. I've also stopped putting spaces inside parentheses and angle brackets. Although I still think that code looks better with the spaces, I realize that most people don't format it that way, and I'm fine going with the popular convention.

This really sucks for angle brackets though. Compare

vector<pair<int, string> > blah;

to

vector< pair< int, string > > blah;

1 comments

I actually prefer the first one, since it's the closest that C++03 will allow to what I want. In C++0x, you will be able to say

  vector<pair<int, string>> blah;
And the parser will recognize >> as the end of two template calls, and not the stream operator.