
11 Apr
2008
11 Apr
'08
8:28 a.m.
I have a dumb question about new error handling. What is the rationale for using 'libvirt_message' instead of 'message' in new Libvirt Ruby error classes? Here is an example of code I am writing: rescue SystemCallError process($!.message) ... rescue Libvirt::Error process($!.libvirt_message) ... instead of, shorter: rescue Libvirt::Error, SystemCallError process($!.message) ... In reality, my rescue classes are bit longer, so the code gets hairy. Wouldn't it be better to use standard 'message' attribute instead? Sincerely, Vadim -- "La perfection est atteinte non quand il ne reste rien a ajouter, mais quand il ne reste rien a enlever." (Antoine de Saint-Exupery)