The comments about Scala resonated. I've been working in a a large Scala codebase for the past few months. I've become a partial fan of the language, however: there have been multiple conversations like : (in screen share with colleague) "See that double right arrow there? What's that mean? (after attempts to find answer in books, SO, etc, and trying to guess based on the three/four other uses the language makes of d…
If you can't use an IDE to jump to the definition (or list all possible definitions) of a function, then aren't you missing one of the main benefits of a statically-typed language? If you can't use the static types for static analysis, what's the point?
Revisiting Java in 2021 – Part II
141–146 of 146 posts
Re: Revisiting Java in 2021 – Part II
#142Earlier quoted context omitted.
> I think if the Scala creators had been a bit less obsessed with symbology This might not be something to pin on the language designers, if you're using certain third-party libraries. Indeed it is possible to name a method pretty much whatever you want, with some constraints[0]. Wanna call it "!^"? Go ahead! But, this is afoul of the naming convention in many cases[1]--acknowledging that the convention may have prev…
A house is leaking from the roof. If the language designers allow methods named "!^", then someone will actually name a method "!^".
Re: Revisiting Java in 2021 – Part II
#143The comments about Scala resonated. I've been working in a a large Scala codebase for the past few months. I've become a partial fan of the language, however: there have been multiple conversations like : (in screen share with colleague) "See that double right arrow there? What's that mean? (after attempts to find answer in books, SO, etc, and trying to guess based on the three/four other uses the language makes of d…
I don't think symbols necessarily need to be SEO friendly. I think Google just doesn't treat them as well as they could?
Re: Revisiting Java in 2021 – Part II
#144The comments about Scala resonated. I've been working in a a large Scala codebase for the past few months. I've become a partial fan of the language, however: there have been multiple conversations like : (in screen share with colleague) "See that double right arrow there? What's that mean? (after attempts to find answer in books, SO, etc, and trying to guess based on the three/four other uses the language makes of d…
Not a scala programmer, but I searched for "scala cheatsheet" and got the answer: https://docs.scala-lang.org/cheatsheets/ Double arrow seems to have multiple uses - for anonymous functions (like in js) and for pass-by-reference arguments (I guess scala is pass-by-value by default). (Surprised at how Erlang-y it feels, especially WRT pattern matching)
The best (but still not exhaustive) doc is : https://stackoverflow.com/questions/7888944/what-do-all-of-s...
Re: Revisiting Java in 2021 – Part II
#145Earlier quoted context omitted.
Sure but the issue is that when a single symbol has multiple meanings that presents an obstacle to learning the language and understanding a code base.
How do you feel about = (assignment and equality check)? Or > which can be used for markup or less than or part of a function arrow? Or {} which can be used as a block or as an object? Or : which can be used for...so many things! Even the humble . can be used to dereference or as a decimal point. My point is that if "a symbol having multiple meanings" is a problem, then basically all languages have a problem.
{} always means "group of related stuff"
: always means : (sic) separator between a thing and something about the thing.
Re: Revisiting Java in 2021 – Part II
#146Earlier quoted context omitted.
Well, dynamic languages like Clojure and static analysis like ProGuard will never mix that well. The module system helps though. You can get rid of the parts of the JDK you don't need. I very much doubt reflection is going anywhere. For one, GraalVM native images support reflection, you just have to state ahead of time what you plan to reflect over. WASM+JVM works. You can run WASM on top of the JVM. There's a Truffl…
Right, you can trim the JDK - that's true but I think the "problem" is a bit more general. I'll give you a more concrete example. I have some small application and it needed to do some basic image manipulation. So I bring in BoofCV and do the manipulation. However I then see that BoofCV drags in all sorts of crazy stuff to do with machine learning and whatnot - along with a sea of irrelevant dependencies - I can keep…