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

It's pretty straightforward? You can interpolate a variable in scope and apply modifiers to it. You can't interpolate arbitrary expressions (which field access would be). Alternatively, you can interpolate an arbitrary identifier, then specify a value for that identifier in the arguments.

The key is "identifiers, not expressions."



The person you're responding to didn't misunderstand (or ask) how it works. They just find it inconvenient.

It would be perfectly possible to add field access without needing to support arbitrary expressions. However, as someone coming from a C# background, I would very much prefer arbitrary expressions.




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

Search: