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

The whole unwrapping the list sound like bugs I hit trying to implement a lisp interpreter.


Or, the language designer thinking he's saving programmers work by jus returning the value in cases where there is a list of length one.

However, he's really making it worse because now all return values from that function have to be type-checked to see whether they are scalars or lists.


R comes to mind, where once in a blue moon a matrix result will happen to only have a single column, which R helpfully decides should be turned into a simple vector, which then doesn't have the matrix operations available anymore (like dim()), and kaboom!


The classic story of every interpreted language.


Yeah. I learned LISP pretty early in my career, wrote a few LISP interpreters, and those are indeed the kinds of bugs that I was stomping. PowerShell seems to have turned those bugs into language features. Augh.




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

Search: