• 1 Post
  • 38 Comments
Joined 2 years ago
cake
Cake day: June 15th, 2023

help-circle

  • Software optimization is mostly not a language-level problem. I’ll be dailying my 3-year-old OnePlus 9 Pro until it starts missing out on security updates, but it will probably still be “usable” long after that. Support/updates aside, my 6-year-old galaxy s9 can still run most normal apps. Hell, I got the most recent lineageOS running on a pixel 2 XL from the year before that and it straight up felt fast as long as I wasn’t playing some super intensive game or something. This isn’t an android vs. iOS problem, it’s a “developers of [insert flashy new app here] either not bothering to put effort in to optimize their code or being forced to push out a minimum viable product ASAP” problem.

    Edit: fixed my hyphen use





  • Zangoose@lemmy.onetolinuxmemes@lemmy.worldnuclear take:
    link
    fedilink
    arrow-up
    13
    ·
    edit-2
    1 year ago

    In the grand scheme of things the difference between C, C++, and Python isn’t meaningful when operating over a network (edit: for a single-user system). It’s very likely that the difference for thread OP is just caused by weaker connections to specific repos.

    We’re talking about a package manager, not a game, network server, etc. On a basic level the package manager only needs to download files from a network and install them (OS syscalls for reading/writing files, these are exposed C functions or assembly routines), or delegate to a specific package’s build setup (which will also likely be written in a compiled language)





  • That’s the thing though, because it’s kind of a paradox. If you had a single team working on it, then sure, it might be easier to just learn Rust. However, on an open source project, especially a volunteer driven one, that isn’t necessarylily the case. Your average enterprise dev probably isn’t even considering rust as an option yet, because it’s still in early stages in terms of tooling and support infrastructure.

    I made another comment in this post, but as it is right now languages like Java and C# make up significantly more projects/job positions than rust. If you want to get more contribution from volunteer devs, it needs to be in a language that devs are comfortable with. Most people won’t want to learn a whole new programming language for a volunteer project when they’re already working a full-time job in a different language. I explained this in the other post, but that’s why I think having both projects is still beneficial. Sublinks and Lemmy can (hopefully) continue to exist at the same time and benefit from each other’s development, especially if they stay API compatible. Sublinks will have a lower barrier to entry (thus maybe a quicker development cycle with more people involved), while Lemmy will help contribute to the validation of rust as a language for production code.

    Also “rust is the future” implies that’s the only programming language that is worth learning, which is simply not the case. Different languages are better at different things. There will never be a single language that’s best at everything. Even for a specific task, multiple languages are good at doing the same thing. For example, Go, Rust, C#/any .NET, and Java/any JRE can all do REST services like Lemmy pretty well. Of those, I wouldn’t even say Rust is the best choice, because its frameworks are all still pretty new.

    Other languages are growing and evolving as well. Even old languages like Java and C++ have had significant improvements in their modern standards (Java records, C++ smart pointers, etc.). Hell, even COBOL got a new standard version as of 2023 (if I had to guess, this didn’t do much for it though). Just because certain languages are bad right now doesn’t mean they will stay bad forever.






  • Sorry for being unclear, I wasn’t trying to say language doesn’t make a difference (e.g. static vs. dynamic typing would make a big difference). I also personally like the error handling of rust a lot more, even if it does take a bit getting used to when my education has mostly been in languages with Java-style exception handling.

    I mostly meant that the language-level performance and features aren’t necessarily holding the codebase back in a debate between Java and Rust for a lemmy-like REST API. As long as the developers are aware of the pitfalls of Java (null, mutation, error-handling, etc.), it’s possible to have good code.

    I just think that from a maintainability standpoint, a Java-style codebase is much easier for most people to read, understand, and maintain because that’s what most people are familiar with. Especially when many of the developers are volunteer contributors, that type of thing could make a big difference.

    The main problem with Rust is that it’s only starting to get adoption now, it isn’t taught in most education curriculums, and it’s industry use is pretty small at the moment. It’s kind of a catch-22, because rust adoption won’t increase unless large projects like lemmy exist. But that’s also why I think having more options is also fine. Sublinks might get more developers short term because of its language, but that also doesn’t mean it’ll completely replace Lemmy. Both projects can exist at the same time, and hopefully benefit from each other’s development.


  • A lot of people here seem to think that Java code is awful and disgusting and no projects should ever use it. The thing about popular languages is that more code existing in a language inevitably means a lot of it ends up being bad. The same thing will likely happen to rust as it gets popular, but that isn’t exactly a problem. It’s possible to have a well-maintained Java codebase.

    Debate between functionality of the actual programming languages at this point is pretty meaningless, if they have good development standards then a Java program could end up just as well maintained as rust. Any time saved by compiler enforcement of specific standards (like no using null) would be lost by the fact that the devs don’t know rust tooling. You could just have a requirement in PRs that null isn’t used. Both Java and Rust have usable frameworks for REST API development, so using one or the other comes down to familiarity.

    The idea that programming languages make code suddenly good or bad is pretty silly. Different languages have different language-level guarantees which can help produce good or working code. That being said, it’s not like it’s impossible to write good Java code, just like it’s not impossible to write bad rust code. Most people seem to be conflating guaranteed functionality and safety with maintainability, stability, and readability. Rust is still a new language, so although it’s great, Java will probably be the better choice for the latter 3 qualities.

    That being said, something like Kotlin would probably have been a better starting point since it can interact with Java (and works like Java in most cases) but also has some nice improvements like stricter null checking (Kotlin nulls are treated similarly to rust’s Option<T>, it’s just described as T? instead and the syntax is generally a lot more concise). There’s also the benefit of being able to write some code in Kotlin and some in Java since they are mostly cross-compatible.





  • True, I’m more worried about Citra since interest has kind of died down for that project. I’m kind of hoping some forks show up soon that get popular enough to be put onto a package manager since there aren’t many alternatives with the same compatibility/performance (from what I can tell Panda3ds isn’t very stable yet)


  • Zangoose@lemmy.onetoMemes@lemmy.mlApple
    link
    fedilink
    arrow-up
    1
    arrow-down
    1
    ·
    1 year ago

    Obviously every generation has its struggles, but I was never disagreeing with that. If you treat this as “just another generational problem,” you are fundamentally missing the point. It’s as you say, a whole different set of problems.

    Micro targeted ads are hard to ignore because most of the time they’re influencing our subconscious state. This isn’t just another generational issue we’re facing, it’s fundamentally shaping the way people look at the world without them even being aware of it. It’s not limited to just the current generation, because everyone interacts with technology. However, targeting inner psychology will obviously impact people with less developed brains more than it will impact adults, and we’re beginning to see the effects of that already with Gen Z.