[-] FizzyOrange@programming.dev 11 points 3 months ago

Definitely SQLite. Easily accessible from Python, very fast, universally supported, no complicated setup, and everything is stored in a single file.

It even has a number of good GUI frontends. There's really no reason to look any further for a project like this.

[-] FizzyOrange@programming.dev 12 points 3 months ago

The thing is that "learning C" means "I can write C code that compiles and might be full of bugs", whereas "learning Rust" means "I can write Rust code that compiles and has a small number of bugs". It's not apples-to-apples.

It's like saying "I found it easier to learn primary school maths than I did to learn a physics degree".

[-] FizzyOrange@programming.dev 12 points 3 months ago

[memory safety] is a more or less solved research problem

I don't know if I would go that far. There are some interesting alternative approaches to Rust's borrow checker that might turn out to be better. There's definitely more research that can be done.

But we do have at least one solution that works very well.

[-] FizzyOrange@programming.dev 11 points 5 months ago

If so, is that any different from just being root?

In security terms it's slightly different, in that if an attacker gains access to your account they would have to do a small amount of trivial work to gain root. But yeah it makes no real difference to security. Cargo cultists would object to this but they don't know what they're talking about:

  1. https://xkcd.com/1200/
  2. Local privilege escalation bugs are very common in Linux.
  3. You don't even need that - it's trivial to MitM sudo.

I think the real reason to use a normal user account and give it sudo privileges is that it prevents you accidentally hosing your system. You can't accidentally rm -rf /.

Another reason you might not want to do it is that a fair amount of software will get pissy with you if you run it as root and tell you not to.

[-] FizzyOrange@programming.dev 11 points 7 months ago

Wow the level of drama and anger here is crazy. I assume it was cathartic to write at least!

[-] FizzyOrange@programming.dev 12 points 11 months ago* (last edited 11 months ago)

Yeah I think that's mostly a myth. When I looked up salaries they were definitely good (for programming; amazing for the average person), but not "I would write COBOL for that" good.

There aren't really that many old COBOL systems around. I think it's mostly just over-reported because you can write an article about how some government department still uses COBOL but you can't write about one that switched to Java.

[-] FizzyOrange@programming.dev 11 points 11 months ago

IMO Julia just had way too many big issues to gain critical mass:

  1. Copied 1-based indexing from MATLAB. Why? We've known that's the worse option for decades.

  2. For ages it had extremely slow startup times. I think because it compiles everything from C, but even cached it would take like 20s to load the plotting library. You can start MATLAB several times in that time. I believe they improved this fairly recently but they clearly got the runtime/compile time balance completely wrong for a research language.

  3. There's an article somewhere from someone who was really on board with Julia about all the issues that made them leave.

I still feel like there's space for a MATLAB replacement... Hopefully someone will give it a better attempt at some point.

[-] FizzyOrange@programming.dev 11 points 11 months ago

Sooo much inane naysaying in that Rust for Filesystems article. I'm glad there are people with the stamina to push through it.

Part of the problem, Ted Ts'o said, is that there is an effort to get "everyone to switch over to the religion" of Rust

I would say a bigger problem is that there are people that think Rust is some kind of religion with acolytes trying to convert people. Is it really that hard to distinguish genuine revolutions (iPhone, Rust, AI, reusable rockets, etc.) from hyped nonsense (Blockchain/web3, Metaverse, etc.)?

These things are very obvious IMO, especially if you actually try them!

[-] FizzyOrange@programming.dev 11 points 1 year ago

Quite a lot of misunderstanding here I think.

This will make the point of your language being compiled entirely moot imo.

Not at all. Compiling to machine code rather than bytecode isn't about avoiding having a runtime. Hell, C has a runtime. It's called the C RunTime (CRT).

ML/Scheme/CLisp achieve memory safety through closures. Haskell achieves this through Monads.

No they use garbage collection and bounds checking just like imperative languages. There are some slight differences but those are nitpicks.

Functional languages have a property which allows them to be be both compiled into machine code and bytecode, and also, interpreted like an scripting language.

Absolutely nothing to do with being functional or not. Dart is not functional and it supports AoT and JIT compilation.

You can’t describe what C does with math.

You absolutely can describe what C does with maths. I understand it's very hard but check out CBMC for example.

What C does depends on the platform, the CPU, etc.

So does Rust to some extent, e.g. usize.

Semantics here is clear. Right?

I have no idea what you're trying to say here. The lifetime is completely irrelevant here because you have no references.

What is a ‘function’ in C? Well most C compilers translate it to an Assembly subroutine, but what if our target does not support labels, or subroutines?

The C specification says what a function is.

You see what I am arriving at?

Not even remotely lol

[-] FizzyOrange@programming.dev 11 points 1 year ago

You were so preoccupied wondering what asinine comment you could make that you never bothered to read the article and learn the reasons that they should.

[-] FizzyOrange@programming.dev 11 points 1 year ago

I totally agree, though I think it's worth adding:

  • The advantages of static types is not just finding bugs (though it does do that quite well). It also massively helps with productivity because a) types are now documented, b) you can use code intelligence tools like renaming variables, go-to-definition, find-references, etc. (assuming you use a good editor/IDE).

  • In general stronger types are better but I do think there is a point at which the effort of getting the types right is too high to be worth the benefit. I would say Rust hasn't reached that point, but if you look at formal verification languages like Dafny, it's pretty clear that you wouldn't want to use that except in extreme circumstances. Similarly I think the ability to use an any or dynamic escape hatch is quite useful, even if it should be used very sparingly.

[-] FizzyOrange@programming.dev 12 points 1 year ago

Really? I might have agreed for some other languages, but Go is so bare bones it feels like it takes way longer to write simple stuff than with Rust - you have to tediously write out loops all the time for example.

Tbf I haven't used it since it got generics. Maybe it is better now.

view more: ‹ prev next ›

FizzyOrange

joined 2 years ago