Friday, June 5, 2009

back to Qt!

After a looong intermission (all hail Lua!), I'm again writing some code in Qt.

Of course, I'm using Qt 4.5 and QtCreator, which seems all nice and shiny. It seems the perfect excuse to start using Mercurial, since it's the system en vogue right now. Even GoogleCode has added support for it. Obviously Monotone won't make it big, so better to get into the bandwagon.

But...! QtCreator supports several VCS; but not Mercurial! Bummer. Well, it means I'll have to use Git, since I'm not using svn!

Sure, there's a QtDesigner view in QtCreator, and sure, it once again changes the philosophy of how to turn designs into programs. This time it's roughly what I like: it writes a '.ui' file and (optinally) the class(es) that load it. Clicking the 'goto slot' adds the corresponding slot-handling code to the apropriate class. So far, so good. There's no automated way to remove that code; but makes sense, at least in the name of safety.

But after manually removing the added code I got a lot of compiler errors! Most of them looked like some redefinition deep into the Qt codebase. Only after setting up version control (yeah, Git) I realised that I had deleted one curly bracket too many in the class declaration. Dang, I didn't knew my C++ was so rusty not to catch that at firsts sight. Of course, that also says a lot about compiler errors.

Wasn't that the advantage of static languages? to get errors early? But what use are unreadable errors?

Wednesday, January 21, 2009

"design patterns" or workarounds?

I've just read this, and it's right on point. How many times the "patterns" mantra believers try to fit the world in their few little boxes!

Hope to find more of those 'rebellious' posts about other things that bother me... of course those that i don't agree are wrong and misguided, by definition.

Monday, August 11, 2008

ojos de buho

Bah, no puedo dormir y es mi culpa.

No, no es porque dormí en la tarde. Es por tomar Excedrin para el dolor de cabeza. Lo he estado probando desde hace unos pocos días y me resulta mejor que la aspirina a la que estoy acostumbrado; pero soy demasiado sensible a la cafeína. En general eso es bueno, así me basta con tomar un vaso o dos de cocacola y me hace efecto para trabajar de noche, o simplemente para ayudar a concentrarme.

Pero hoy quería dormir. Mañana seguro estaré cansado de nuevo.

bah.

Wednesday, June 18, 2008

compiles? ship it!

OK, the lock-free hash table for Lua is working! after a little cleanup of the code, i announced it on the Lua list. Let's hope it stirs some new ideas. interested? get it here!

The code is small, so reading it all and comprehending isn't so hard... the next step should be writing some real tests to see if it really works. Bracing for embarrassment...