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

There's so many languages out there, I reject Raku out-of-hand simply since IMO the type should follow the variable name.

You mean like:

    my $a of Int = 42;
    say $a;  # 42
or

    my $a of Int = "foo";'       
    # Type check failed in assignment to $a; expected Int but got Str ("foo")

?

hmmm Raku is C style

  int number;

 … you choose Pascal style

  number : Integer;

Very good, I wrote Pascal many years ago, but I was thinking more Kotlin/Scala (right?) vs Java.

AI taking jobs by users avoiding ads. It makes me wonder how widespread this is and what other "not so obvious" job-taking effects it has.

That's not what they're talking about here, though, is it? They have premium offerings as well, which LLMs are causing people to not buy.

Put another way: Adam said traffic to their docs was down 40% and revenue was down 80%. I don't think it's purely traffic-driven revenue.


Renting a car is more of a pain these days. I find I actually have to learn how that car "likes its buttons". I don't remember having to look at a physical gear shifter to know it's in drive/reverse, etc. Now I have to see if some light is on. It must have been obvious to Human Factors folks from the outset that this was all a waste of time.

not to mention it has all the phone pairing of the last dozen people to use that car. I wish rental fleet cars had some super easy to access setting to reset them for the next person.

> I wish rental fleet cars had some super easy to access setting to reset them for the next person.

Just factory reset the radio, that's what I had to do with my truck that has no apparent way to remove a phone once it's been added.


Yeah but if they didn't change anything substantial and merely followed customer preferences and established norms, how would they justify the massive administrative and managerial bloat with inflated salaries in established auto companies? How will you keep the investor class satisfied without promises of massive returns within the next few years or so to keep that stock juiced with new gimmicks to sell? How do you keep the MBA holding c-suite relatives employed if they are simply making the same or similar bulk consumer cars for decades at a time? Think about that year or so window when only OEM parts are available to repair new vehicles before generic parts are modeled and built and the new and completely unnecessary tools that can be sold to mechanics and dealers that they can gouge people on.

Long-term maybe we won't care about code because AI will just maintain it itself. Before that day comes, don't you want a coding language that isn't opinionated, but rather able to describe the problem at hand in the most understandable way possible (to a human)?

You're reading too much into what I mean by "opinionated".

I have very specific requirements and constraints that come from knowledge and experience, having worked with dozens of languages. The language in question is general-purpose, highly flexible and strict but not opinionated.

However, I am not experienced in every single platform and backend which I support, and the constraints of the language create some very interesting challenges. Coding agents make this achievable in a reasonable time frame. I am enjoying making the language, and I want to get experience with making low-level languages. What is the problem? Do you ever program for fun?


I think it's a shame more real leather isn't used. It just goes to waste, but fake leather is cheaper.


Fake leather is such an annoying scam. Real leather can last for a century if taken care of, fake leather lasts a handful of years before it literally flakes away into nothing.

Though that reminds me of the time I bought a real leather couch set that had absolute garbage everything else, the legs broke after a couple of years. Really not the part I was expecting the manufacturer to have cheaper out on...


Fake leather has a wide, wide range of quality. Polyurethane faux-leather used in many automobiles these days is considered to be superior to leather in terms of durability and longevity. Take a look at old examples of MB-Tex, which Mercedes has been making for ... 60-70 years by now.

Similarly, plenty of leather that will disintegrate and flake into trash or crack and peel, especially if not taken care of well.


My Mercedes "leather" seats have flaked in ten years, almost the entire seat area (where my butt goes) is now showing the white underneath.


Plenty of real leather seats that have done the same. I had a 10 year old real leather Volkswagen that did the same myself.

Meanwhile, I have a 11 year old Vinyl “fake leather” car with no issues, and a 8 year old car with PU pleather that looks nearly brand new. Ironically, the steering wheel is made of real leather and has started flaking in a few small corners.

I’m not sure how any of those anecdotes proves which is more durable or long lasting than the other.


There are also many grades or "real" leather. In particular, the label "Genuine Leather" means little more than "bits of leather included" [1].

[1] https://mahileather.com/blogs/news/what-is-genuine-leather


This seems like a good time to share the obligatory Fortnine leather vs fake leather video: https://www.youtube.com/watch?v=xwuRUcAGIEU


There’s also the fact that leather is the waste by product of harvesting meat. People aren’t going to stop eating meat any time soon.


I too am annoyed by “faux leather” as it is so stupid to see some ad saying leather jacket and when you look at the details see faux leather. That is not a leather jacket it is a plastic jacket so cut the shit. Same level of ragebait as things like vegetarian “meat”balls.


> Same level of ragebait as things like vegetarian “meat”balls.

There is some amazing vegetarian food out there. Both Buddhist and Hindu cultures have been making amazing vegetarian food for literally thousands of years and they are really good at it.

Also, vegetables are just yummy!

Fake meat, no thanks. Incredible vegetarian and vegan food exists, stop trying to fake it. Same with gluten free foods, almond flour is an amazing ingredient but it is different than flour. It is funny that the keto community had amazing gluten free recipes years before the gluten free communities figured it out.


Exactly. I find myself incidentally eating vegetarian most of the week, being Indian, just because it tastes good (and because it's cheaper, but that's another matter). My parents only eat meat on the weekends due to such cost so it's interesting to see people in the West eat meat for every meal such that its lack is noted.


Agreed... when I was a vegetarian, I ate nothing but Indian/Malay/Thai etc and it was great. If I hadn't moved I would probably be vegetarian to this day.


What’s wrong with vegetarian meatballs? As a vegetarian I find naming the products after what they’re imitating far more helpful that coming up with some clumsy confusing name that’s obviously trying to imply what they want to say without saying it… does anyone really read the word “vegetarian” and then still think it must have meat in it? I don’t think that’s a real problem


"Stop calling it soy MILK! There's no such thing as oat MILK! Milk comes from COWS."

What should they call it, then? Oat beverage? Soy water? No, that's silly. They are, functionally, milks. That's an apt descriptor.

Ditto for other vegan alternatives.



Maybe "juice" ? "Soy juice" and "Oat juice" sound pretty good to me.

On the "Soy milk" wikipedia page, it is said that Germany and Italy use names like "soy drink" or "soy beverage".


It is much closer in taste and use to milk than it is to juice.


I see my comment got upvotes but yours is downvoted for some reason, maybe they only read the first sentence and thought you were disagreeing? (or they agree with this for meastball but not milk for some reason)


It's more amusing when they call it "vegan leather".


I think you misread the word feather.


I find it annoying in Java when uppercase is used because its an acronym. URL or UUID. No man, just Url/Uuid. No need to yell just because its an acronym.


Man I wish they'd continue The Looney Tunes Show.


My OO projects were usually in Java with a DB. They all ran afoul of what Martin Fowler calls the Anemic Domain Model. Basically your objects are data-only, so there's no benefit. In addition Spring injection became ubiquitous, and further killed objects with behavior. The only project using a DB and had objects with behavior was an old one that happened to use TopLink as an OR mapping.


> Basically your objects are data-only, so there's no benefit.

This makes me wonder why most of us use Java at all. In your typical web app project, classes just feel like either:

1) Data structures. This I suspect is a result of ORM's not really being ORM's but actually "Structural Relational Mappers".

- or -

2) Namespaces to dump functions. These are your run-of-the-mill "utils" classes or "service" classes, etc.

The more I work in Java, the more I feel friction between the language, its identity(OO beginning to incorporate functional ideas), and how people write in it.


> why most of us use Java at all

Java was the first popular language to push static analysis for correctness. It was the "if it compiles, it runs" language of its day, what meant that managers could hire a couple of bad developers by mistake and it wouldn't destroy the entire team's productivity.

I'm not sure that position lasted for even 5 years. But it had a very unique and relevant value proposition at the time.


OCaml would like to have a word with you. In 2005 it already had better static analysis and correctness on object oriented stuff than what Java struggles to approach today.

But Java has better marketing.


Java is from 1996...

It got really useful by 1998.


OCaml is also from 1996. And I say 2005 because that's when I started using it, not when it started being useful.

By that time it supported parametric generics, multiple inheritance, named parameters, optionals instead of nulls everywhere, compile to machine code and quite a few extra things that I couldn't understand at the time.


A lot of that is down to how people rely on frameworks that force them into "convenient" abstractions. Like Spring and Hibernate. But those are not the language. They represent a (vocal) subset of programmers.

You don't need an ORM or an overgrown dependency injection framework to create a webapp in Java.


Service classes are the thing I hate most. They’re just namespaces for functions. They’re a product of Java not being able to have top level functions.


Not being able to have top level functions is a feature, not a bug.

You can declare static methods on interfaces in Java, which means you could call things like Users.create("Foobar") if you wanted to.


Not everything can be associated to a single entity. Many operations work on two or more entities where none of them are the "master". Otherwise you end up with "coordinators".

Users.create(...) is the easy case. Try transfer_permissions(user1, user2, entity) while retaining transactionality and the ability of either user to cancel the transfer.


Permissions.transfer(x, y, z)

I'm not sure why having a global function by the same would make this any easier or harder to implement. But it would pollute the global namespace with highly specific operations.


And now you have invented a helper class when all you needed is a namespace. And you already had namespaces.


It doesn't have to be a class. It can be an interface. And regardless of what it is, it has to go somewhere. Whether it's in assorted_functions.c or Permissions.java makes little difference.

I mean it makes sense to group "like" things together. Whether that's in a module, a class, an interface, or a namespace. Having a huge number of things globally is just confusing pollution.


> it has to go somewhere

Yes, but going as a static method into a class that goes into a module is overkill vs just putting it in the module.

> Having a huge number of things globally is just confusing pollution.

I don't know what language you use, but modern programming languages allow specifying what to import when importing a module. You don't have to import everything from every module.


It is not a feature. Every programming language since has decided this was a mistake.


Can you provide an example of that?


Here is an example of a 2006 rant that qualifies: https://steve-yegge.blogspot.com/2006/03/execution-in-kingdo...

OO conflates many different aspects that are often orthogonal but have been conflated together opportunistically rather than by sound rigor. Clearly most languages allow for functions outside classes. It's clearly the case today especially with FP gaining momentum, but it's also clear back then when Java and the JVM were created. I think smalltalk was the only other language that had this limitation.

Like others in this thread, I can only recommend the big OOPS video: https://youtu.be/wo84LFzx5nI


They're just namespaces for functions, and... why is that so bad? Of all the reasons I hate Java, this isn't one of them, it's whatever.


You are so ready : https://fsharpforfunandprofit.com/rop/

The separation of functions and records..


I've read his book "Domain Modeling Made Functional" without much prior knowledge of F#. He provides some compelling examples and some of it ended up inspiring how I write OO code. F# seems cool but it felt like it was close to being extinct.


Honestly one of the best books I've read about programming. It's inspired me to try the language out just for fun things, think I'm going to use it for Advent of Code this year. I think it does benefit from being interoperable with C# so you can use it where it makes sense and still have C# to fall back on. Kind of like Scala/Kotlin with Java.


Java is a waste of time for the reasons you said. People use it for legacy reasons. Back then, the alternatives like JS just weren't there yet in several spaces like backend. Your alternatives were even more cumbersome like C++.


> People use it for legacy reasons

This is so incredibly wrong it must be a troll.


OO fatigue is a healthy symptom of readiness to move to clojure, where data and functions are free to live without encapsulation. No king of nouns, no king of execution!


Why did you create an anemic domain model?

Java has had "data carriers" in the form of records for a while now. Immutable(ish), low boilerblate, convenient.

    record User(String name){}
Records are great when doing more "data oriented programming".


I don't think anyone sets out to make an anemic domain model, it just happens. Lots of developers start with POJO's for JPA models and then never advance them into being full fledged objects when the requirements develop.


Surely that's a conscious design decision? Deciding to create data-carrying POJOs with JPA annotations is a valid strategy. Mixing in a bunch of logic and non-JPA state with them is a recipe for disaster. If you want your classes to Do Stuff, you have to design them to Do Stuff.

I dislike the term "anemic domain model", it casts a value judgment which I think is unwarranted. There's a spectrum from anemic to obese (for want of a better word). There are tradeoffs all along that spectrum. Finding a sweet spot will depend heavily on what you're doing, why you're doing it, what your team is comfortable with etc.


I genuinely believe its not a conscious design decision. Most people never properly learn how to turn things into objects. I've seen this happen in many projects across many companies. They simply just write procedural code without centralizing their logic anywhere.


That's not object oriented though


Does it have to be? Java is a hybrid paradigm language. It's perfectly fine to write data-oriented code. And if you're using an anemic model, there's no point paying the overhead price of fully fledged classes.


I meant, if you want to evaluate OOP by itself, you can't use things that break the paradigm. Java broke that probably because they realized OOP isn't always a good idea, after sticking to it up through v7.


Yes. Although something in-between works as well.


"One can even conjecture that LISP owes its survival specifically to the fact that its programs are lists, which everyone, including me, has regarded as a disadvantage"

Not the first time someone didn't realize what they had.


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

Search: