Speed testing SpeedCrunch

Ariya Hiyadat has submitted his calculator implementation, giving KDE users a choice of 4 (!) different calculators.

I’ve tested it a little, and I have to say that it’s pretty good work, especially the bit about using pure C++. I was tempted to go that way myself but constructing the appropriate LALR(1) table by hand, but that’s hard to maintain, which is why I’m still using bison/flex.

I like very much how alternate lines have different colors, which seems “better” somehow than inserting separators between different entries like I have mine now. Oh BTW, kcalc2 has since become abakus (and has made it to version 0.52), which was a name suggested on #kde-devel by argonel.

The only things I’ve found that I don’t like with SpeedCrunch are:

  1. 4 * atan 1 is an invalid expression, but 4 * atan (1) is valid. However, the same doesn’t seem to apply to 4 * atan -2 and 4 * atan (-2), as both are valid.
  2. It appears to be possible to truncate an answer with noticing, as SpeedCrunch doesn’t have any horizontal scrollbars, but you can resize the window so that your answer is clipped (and it starts up that small for me, but that’s neither here nor there).

It’s a great effort though, especially since it’ll compile on more systems than mine will =D. It’s a pity that Ariya doesn’t have time to do more with it. I’ll probably tweak abakus some more to try and improve it, as I’ve received some good suggestions of varying difficulty. P.S. Debian users, you may have to tweak the Makefile to change KDE_PREFIX/include to KDE_PREFIX/include/kde, or wait until tomorrow when I remember to post the corrected version.

Bonus points to Ariya for limiting his hospitality to non-alcoholic beverages, I always hate it when people try to push me to drink something alcoholic. ;-)