Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

In C# in general you shouldn't call a virtual method from a constructor. See http://blogs.msdn.com/b/abhinaba/archive/2006/02/28/540357.a... (of course there are exceptions to this rule, but make sure you understand the rule).

I thought Java had this same issue, but if methods aren't explicitly virtual you're effectively always in this state. So clearly Java must deal with construction/virtuals differently.



Consider applying for YC's Fall 2026 batch! Applications are open till July 27.

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

Search: