• 1 Post
  • 242 Comments
Joined 2 years ago
cake
Cake day: September 24th, 2023

help-circle






  • Even if there are tight time constraints, you won’t sacrifice quality, because that would make you slower.

    Too right. People find this so hard to understand. I think they dramatically underestimate the payback time on technical debt.

    I am currently working in a startup that has the classic “we’re a startup, quality doesn’t matter” attitude. They think that they might not be around in a year so it’s best to go fast and not give a shit about tech debt.

    In my experience that attitude bites in under 6 months. I’m already wasting entire days sorting out messes that they neglected to deal with.


  • I mean, it would be great if this succeeded… ffmpeg is nice and all but its interface is clearly terrible and there’s absolutely no way it is remotely secure. Anyone that uses it on a server basically has to run it in its own VM, or a severely locked down sandbox.

    But good luck supporting all the codecs people expect. I’m not even talking the obscure ones ffmpeg supports; just the ones “normal” people use will be a life’s work.

    Also you have to change the name!






  • Right, I’m not saying it isn’t simpler in terms of syntax. The point I was making is that the syntax is simpler but in a way that makes it worse because while it’s easier for computers to read, it’s harder for humans.

    it was only later discovered that they can be compiled down to native code.

    That sounds extremely unlikely. I think you’re misinterpreting this quote (which is fair enough; it’s not very clear):

    Steve Russell said, look, why don’t I program this eval … and I said to him, ho, ho, you’re confusing theory with practice, this eval is intended for reading, not for computing. But he went ahead and did it. That is, he compiled the eval in my paper into IBM 704 machine code, fixing bugs, and then advertised this as a Lisp interpreter, which it certainly was. So at that point Lisp had essentially the form that it has today …

    As far as I can tell Lisp was always intended to be compiled and executed. That quote is about compiling the eval() function (which was just meant to explain how Lisp is executed) into a binary and using that as an interpreter.

    Also I skimmed the paper that is from, and in fact Lisp was intended to be targeted by AI (in the same way that we get AI to write and execute Python to solve problems), which explains a lot. It wasn’t designed for humans to write, so why bother with nice syntax; just have the machine write the AST directly!

    (I expect that was only part of the motivation tbf, but still!)


  • This comment perfect captures why I don’t like Lisp. Essentially “it’s simple, this easy to read code transforms to this AST”. Lisp basically says “we can make parsing way easier if we force programmers to write the AST directly!” which is really stupid because computers can perfectly well parse syntax that is easy for humans to read and turn it into ASTs automatically.

    It makes it easier to parse for computers at the cost of being much harder to parse for humans, which is really the wrong choice in most cases. (The exception is if you’re DIYing your compiler, e.g. if you’re teaching how to write a compiler then Lisp is a good target.)


  • Yeah it’s great for little scripts. There’s even a cargo script feature that’s being worked on so you can compile & run them using a shebang.

    I’d use a shell script if it is literally just a list of commands with no control logic or piping. Anything more than that and you’re pointing a loaded gun at your face, and should switch to a proper language, of which Rust is a great choice.


  • It’s definitely a growing problem with Rust. I have noticed my dependency trees growing from 20-50 a few years ago to usually 200-500 now.

    It’s not quite as bad as NPM yet, where it can easily get into the low thousands. Also the Rust projects I have tend to have justifiably large dependencies, e.g. wasmtime or Slint. I don’t think it’s unreasonable to expect a whole GUI toolkit to have quite a few dependencies. I have yet to find any dependencies that I thought were ridiculous like leftpad.

    We could definitely do with better tooling to handle supply chain attacks. Maybe even a way of (voluntarily) tying crate authors to verified real identities.

    But I also wouldn’t worry about it too much. If you a really worried, develop in a docker container, use a dependency cooldown, and whatever you do don’t use cryptocurrencies on your dev machine.