Live data from Hacker News

“Swift is the only language I could find with over 100 keywords”

twitter.com

21–26 of 26 posts

Re: “Swift is the only language I could find with over 100 keywords”

#21
post #20

Earlier quoted context omitted.

JS is a fairly low bar to compare other programming languages to.

And used by many, so useful to compare to?

It’s only used by many because it’s the only scripting language on the web browser, and not due to anything intrinsic to the language.

So it’s popularity tells us nothing about the language, and more about the fact that it’s the only language on the most popular platform.

So I’m not sure comparing any language to JS is useful to learn about the language.

Re: “Swift is the only language I could find with over 100 keywords”

#22
post #5

And yet code in Swift is much cleaner than anything in Javascript. I say that having mostly written Swift & Javascript at my jobs and on the side.

JS is a fairly low bar to compare other programming languages to.

The point was to compare a "simpler" language

Re: “Swift is the only language I could find with over 100 keywords”

#23
post #20

Earlier quoted context omitted.

And used by many, so useful to compare to?

It’s only used by many because it’s the only scripting language on the web browser, and not due to anything intrinsic to the language. So it’s popularity tells us nothing about the language, and more about the fact that it’s the only language on the most popular platform. So I’m not sure comparing any language to JS is useful to learn about the language.

It’s popularity tells us many people will be able to relate to that comparison.

Re: “Swift is the only language I could find with over 100 keywords”

#25
post #15

Earlier quoted context omitted.

All special forms (if, let, progv, etc...) are very similar to keywords in other languages. But there's only a couple dozen of them. From Wikipedia: "Some Lisp control structures are special operators, equivalent to other languages' syntactic keywords."

Personally I don't think that really counts. IIUC you can override those names, so they aren't reserved, and you can implement any one of these as a macro so you don't need to remember anything outside of the core language. (You can't implement them all as macros, but IIRC there are disjoint built-in sets that can give you the full behaviour)

Sure. I think the point he was trying to make is that some languages are more complex than others. And in that context, the fact that Lisp has the flexibility to override just about anything actually makes the language more complex. Because now you can't make any assumptions about anything. In some ways Lisp is the most complex language in existence because it encompasses an infinite number of sub languages (ergo Racket's tagline "The programmable programming language"). In other ways it's the most simple language ever.

Re: “Swift is the only language I could find with over 100 keywords”

#26
post #20

Earlier quoted context omitted.

JS is a fairly low bar to compare other programming languages to.

And used by many, so useful to compare to?

It's less useful when you realize that almost every other widely used programming language is better than JavaScript.
Post reply on HN