Earlier quoted context omitted.
You will also find Clojure just as refreshing / enlightening. My company uses Elixir but I’ve also done a lot of Clojure, give it a shot if you haven’t.
Seconded. Clojure was a real turning point for me but be warned - once you have the veil lifted re OOP you'll not want to work with Java/C# ever again.
Don’t call it a comeback: Java is still champ
431–440 of 557 posts
Re: Don’t call it a comeback: Java is still champ
#432The only problem Java has is experienced C programmers don't build servers from scratch with it yet. Once they take that responsibility, the debate will be over because: "While I'm on the topic of concurrency I should mention my far too brief chat with Doug Lea. He commented that multi-threaded Java these days far outperforms C, due to the memory management and a garbage collector. If I recall correctly he said "only…
https://go.dev Experienced C developers have switched to it. Actually it gets even better, they are extremely productive in it. Don't trust me, check github. I wonder why. /s
Re: Don’t call it a comeback: Java is still champ
#433Earlier quoted context omitted.
> Not as fast as C++ at sub 5 micros. Try sub 5 nanos. I was curious awhile ago at how fast C++ hash set lookup was compared to C#, and it consistently performed a lookup at 1 nanosecond. I tested with up to 6GB of data and then stopped because it was taking longer to generate random data then it was to run the benchmark 10,000 times. C++ benchmarks here[0]. It's a bit more complicated then just a pure lookup since I…
I'm talking about an end to end HFT system in C++.
Re: Don’t call it a comeback: Java is still champ
#434Re: Don’t call it a comeback: Java is still champ
#435Java's adequate. It's like a Toyota Corolla (insert your boring car of choice here if you don't feel this one works for the analogy). Not the prettiest, not the fastest, not the most efficient. But it gets you from point A to point B with little fuss or muss. I totally get why companies adopt and standardize on it. Do I use it for personal projects? Nope. Because it's not fun to "drive". For that, I pick the equivale…
I personally use Racket (Lispish) just because it is so much fun to build whatever I want and customize it. It just feels good to have my small projects just fit me perfectly.
Re: Don’t call it a comeback: Java is still champ
#436Earlier quoted context omitted.
Erlang is not as peformant as Java, but there are plenty of reasons to prefer the former to the latter: - a much better concurrency model, that gets you parallelism for free just by adding cores - no global gc pauses, low-latency - fantastic operational tools (trace debugging, remote shell, etc.) - Erlang/OTP gives you great middleware out of the box, including including queues, pub-sub, service monitoring, database,…
All that said, Erlang is a very sharp knife, built for one specific purpose. This is just not true: "a much better concurrency model" If your program is CPU-bound, where real threads are king, then Erlang is a pretty poor solution. Because you cannot have real threads in Erlang, even if you wanted to. Number crunching or string processing are not its forte. Also, most enterprise software does not really benefit from…
> CSPs, for example, which in many ways are superior to actors
how is csp superior to actors?Re: Don’t call it a comeback: Java is still champ
#437Earlier quoted context omitted.
Weird Spring is the reason why i am sticking to Java
I just can't get past annotations as a thing. Seems like a crime against programming to me.
Re: Don’t call it a comeback: Java is still champ
#438Earlier quoted context omitted.
Finalizers are deprecated (though are still used of course in existing programs), so just a heads up: Cleaner API is the replacement
Sure, I mean, finalizers have been deprecated as long as I can remember. But -- as you say -- they still work, and I expect will continue to work for quite a while. And, as you suggest, probably forever for existing bytecode that targets older JVM versions.
Re: Don’t call it a comeback: Java is still champ
#439Java's adequate. It's like a Toyota Corolla (insert your boring car of choice here if you don't feel this one works for the analogy). Not the prettiest, not the fastest, not the most efficient. But it gets you from point A to point B with little fuss or muss. I totally get why companies adopt and standardize on it. Do I use it for personal projects? Nope. Because it's not fun to "drive". For that, I pick the equivale…
I wouldn’t use Java again because I am done dealing with the brokenness of Maven and Gradle. They are the opposite of “little fuss and muss.” The Go build tools fit your analogy better.
people shit on maven, but i say it's much better than many other built tooling - npm, make, or custom scripts.
The only thing need getting used to is that you cannot and should not stray from the maven model - fit your project's built into the maven model, rather than try to twist maven to do your bidding.
Re: Don’t call it a comeback: Java is still champ
#440Earlier quoted context omitted.
This is destructuring but not pattern matching.
How is this not pattern matching? In Scala, I would write: enum Expr: case INT(value: Int) case ADD(left: Expr, right: Expr) case MULT(left, Expr, right: Expr) def eval(e: Expr): Int = e match case INT(value) => value case ADD(l, r) => eval(l) + eval(r) case MULT(l, r) => eval(l) + eval(r) This "match" syntax is the example given in the Scala docs for Pattern Matching: https://docs.scala-lang.org/tour/pattern-matchin…