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

Not comparable. h() was a one-sized-fits-all problem to quoting things that could occur anywhere in an HTML DOM. #to_i assures that a bit of syntax that can only ever accept integers is in fact given a real integer.

In case we're misunderstanding each other, I'm also saying that the framework should be doing that, not the caller (as was the case with h()).



Thanks, yes misunderstanding: agree should be a framework protection not something developer should be sprinkling over code.




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

Search: