Hacker Newsnew | past | comments | ask | show | jobs | submit | twykke's commentslogin

having used Coffeescript almost exclusively (in the Node.js world) for something like 6 years, async/await was the only feature i have been gnashing my teeth waiting for, but i wasn't even that impatient because i have also been using Fibers for just as long.


i tend to use an explicit return except in one-line functions; there are plenty of CS features you can forgo if you don't think they benefit you.


some colleagues of mine have complained about the significant whitespace being difficult to understand. i can't argue with something subjective like that.

however i like to point that our entire codebase, CS, JS, TS, Python, Java, Swift, 100% of it already has significant whitespace.

...it's just that the JS/TS/Java also have curly brackets.


I'm not sure I understood. I don't know about Swift but do JS and Java have significant whitespace?


No, twykke is saying that in almost every language, even ones that don't technically have significant whitespace, people still use coding conventions and style guides that restrict whitespace to match the curly braces. Some people even use automated commit hooks to reject commits that don't follow the guide.

The end result (or arguably, driving force) is that even in languages where whitespace isn't significant, people read the whitespace, not the curly braces. So the curly braces are basically redundant noise.


Ok, thanks.

I agree about { } being mostly noise but I think they are the lesser evil. I'm making most of my money with Python and I still believe significant whitespace is a very bad idea. The Ruby alternative of using end is better even if not super elegant (and Ruby is my language of choice). It's on par with curly braces. After 30+ years of programming I still have to find a satisfying solution to the problem.


i also don't use CoffeeScript because of any 'feature' it has over standard JS but instead because of its concise but expressive syntax. it's less about what it does have/do, and more about what it doesn't have/do.

some small aspects of CS i forgo because they (in my opinion) are a little too concise such that they sacrifice readability, but all in all it has my favorite syntax of any language.


Exactly.

I personally think calling .map() on an array is more readable than an array comprehension. But since CS is "just JavaScript" you are free to use the native JS array methods (and even more elegantly, at that).


list comprehensions was exactly what i was talking about :) however i replace them with lodash and ramda, which benefit enormously from CS's lambda syntax


I wish this line of thinking was more common. So many people feel forced to use parts of a language when you don't have to.


CS breaks the ternary ?: operator which is a big headache for me.


Everything is an expression. Including if statements. There is no need of such syntax abominations.


Bingo. Remember when you first first learned the ternary operator syntax? I recall thinking something along the lines of, "Wow, that's cryptic!"

    result = if condition then success else failure


Sure, but other coffee operations like x||=5 are also abominations. Brevity and purity are often at odds and the choices made by a language can be arbitrary.


spread some love for moonscript (and its inspiration coffeescript of course, my daily bread-and-butter) - to my mind the best possible syntax for a (dynamic) programming language. python being second place.

is it possible to get a tattoo with significant whitespace?


all our opsworks servers have been unreachable from the internet since around 05:13Z when we see a mysterious 'configure' command with no further details in the opsworks logs

EDIT: they are in EU-West zone btw


Can we all agree that the amount of humans which the Earth's (mass/surface area/volume/energy/environment/resources/what-have-you) can support is finite? Can we also agree that the ideal number of humans on Earth is somewhere between 0 and this finite limit?

In this case, I would simply argue that the ideal amount is somewhat lower than the amount of humans which would necessitate covering the entire Earth's landmass and oceans with a planet-sized city, obliterating all natural landforms and all species except those found in factory farms and zoos.

I guess what I am trying to say is, if we consider overpopulation not to be a problem, then we must believe that humans are wise enough to stop multiplying before Earth becomes a monoculture. This is the argument that I find hard to believe.


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

Search: