←back to thread

160 points todsacerdoti | 2 comments | | HN request time: 0.721s | source
Show context
jongjong ◴[] No.41898801[source]
I also love JavaScript.

It's true, it has some really bad parts but you can avoid them.

If I could design the perfect language for myself, it would have the syntax of JavaScript and the portability of JavaScript but it would use Python's strong duck typing approach.

replies(2): >>41898846 #>>41898893 #
anyfoo ◴[] No.41898846[source]
What have static type systems ever done to you, that you avoid them so much?
replies(3): >>41898943 #>>41899010 #>>41910924 #
bryanrasmussen ◴[] No.41898943[source]
most static type systems are verbose, probably due to linguistic verbosity, so one obvious thing that static type systems have probably done to a lot of people is given them pain from typing so much.
replies(2): >>41898960 #>>41900973 #
1. ggregoire ◴[] No.41900973[source]
Not sure what languages you are thinking to with "most static type systems", but in languages like TypeScript or Rust (and I guess modern Java/C#, haven't touched those in a while), most of the types are inferred by the system such as you don't need to write them. You type your functions arguments (and return values in Rust) and that's about it.
replies(1): >>41902780 #
2. bryanrasmussen ◴[] No.41902780[source]
Ok I was thinking Java / C# which I haven't touched in a while either and they were verbose, Typescript may be able to infer types but every place I've used it we write just everything out, and as such there is quite a lot of extra declaring of things that could be inferred, that may be cultural, but it seems pretty ingrained culture.