Dimi Paun dimi@lattica.com writes:
OK, here it is, using exceptions instead of cluttering the code with tests all over the place. Obviously, it is much cleaner then other methods, but we've I know we've been hesitant to use exceptions in Wine unless absolutely necessary due to the cost of __TRY.
IMO that's really ugly, and will cause no end of maintenance nightmares. You can't just jump out like that, you'll need to check every intermediate function to make sure it unwinds properly, frees allocated memory etc. In the end it's the same work as handling the error explicitly, but it makes the code much harder to follow.