Hacker News new | past | comments | ask | show | jobs | submit login

I'd go dummy function all the way.

No code duplication. No goto




well to each his own. In case of the cleanup phase before return I find it to be much cleaner with goto, since usually it's sub 10 lines and you'd have to program a function that gets pointers or objects passed that then get freed/destroyed, which I find ugly as hell. I look at such an outer procedure as an 'owner' of these objects and therefore I want to see the allocations and deallocations in plain text right there.




Join us for AI Startup School this June 16-17 in San Francisco!

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: