I have been always use finally to clean up the mess to make my method end up gracefully, and it looks like the the finally code block is the last stop of the code flow. But wait, have you ever think about why IDE are not force you to write a return statement? If it is really the last stop, then you need to add return statement for a method requires a output parameter. It looks weird, but fortunately I could look for answer in my Eclipse:

public int f1(){ try{ x = 1; return x; }finally{ x = 2; } }

And this method print 1. So it looks the finally is NOT the last stop, otherwise we should saw 2. What’s wrong? Then I expended the method a bit:

I have a project that generate some java code and I will need these java class in another project. The generated code has some error because it need a dependant library, but Eclipse still generate the class file for them, even it has unresolved class reference. I actually noticed the error I still package them into a jar and import it the other project, because I thought the if I could import the dependant library in that project also, I’ll be safe. But I was wrong, the “Unresolved compilation problem” still occurred even I included the dependant library.

The solution is to include the dependant library into the original project that generate the code, make sure there is no error in the generated code and then included into the other project.

I know WordPress is far better than MS live space, I didn’t make the change simply because I am lazy. I should say thank you to MS for the tolerable service all these years, and this easy and smooth migration to WordPress.

PS. I know this migration from CCTV news broadcast, not from Internet:)