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

In that case you're not really hacking it.

If you think about what a switch does and how it works, it makes perfect sense. It's just a bit unusual to do it that way.



Is it not though? By exploiting the conditions to evaluate to true == $CaseValue you're subverting the expectation that the choices all rely on a single variable, all the while breaking fallthrough and default.




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

Search: