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

> foo(out int mvar); // oops, not myvar; maybe caused by a refactor?

This should fail to compile, it's the equivalent of declaring a variable twice int the same scope.

If that were int myvar you'd be correct, in this case the typo introduces a new variable mvar that won't conflict with the original declaration.

Whoops, I missed the typo. Inadvertently proving your point.

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