Archive for April, 2007

The Wizard of Climbing

“to climb” translated into German is “klettern”. The kletterwizard allows you to write nice looking letters in a nice KDE-Wizzard-GUI with a snip of your fingers.

I’ve created a RPM for OpenSuSE 10.2 with another snip of checkinstall‘s fingers.

C-Plus-Plus

It is amaising what horrorable error messages g++ is able to generate…

error: could not convert ‘((Parser*)this)->Parser::words. std::map<_Key, _Tp, _Compare, _Alloc>::find [with _Key = std::basic_string<char, std::char_traits<char>, std::allocator<char> >, _Tp = Word*, _Compare = std::less<std::basic_string<char, std::char_traits<char>, std::allocator<char> > >, _Alloc = std::allocator<std::pair<const std::basic_string<char, std::char_traits<char>, std::allocator<char> >, Word*> >](((const std::basic_string<char, std::char_traits<char>, std::allocator<char> >&)((const std::basic_string<char, std::char_traits<char>, std::allocator<char> >*)(& sval))))’ to ‘bool’

The code to reproduce it looks like
if (words.find(sval)) {...}
where words is a std::map<std::string, Word*>.

The correct code is:
if (words.find(sval) == words.end()) {...}

You can opt-out from Google Analytics tracking by clicking the link below. Click here to opt-out.