[-] pileghoff@programming.dev 6 points 1 year ago

I think this is enviable with low level languages. You simply can't abstract away as many things.

[-] pileghoff@programming.dev 7 points 1 year ago

What's wrong with man ascii?

[-] pileghoff@programming.dev 23 points 1 year ago* (last edited 1 year ago)

Async rust might suck, compared to async in higher level languages, but for someone comming from C, async rust simplifies a lot of stuff. It often feels like a lot of criticisms of rust boils down to the fact that rist was sold to both people using low and high level languages. I don't doubt that async rust is shit when all you want is a faster typescript.

Edit: I certainly also have my criticisms of rust and its async implementation, and I think some of the authors concerns are valid, it was just an observation about the tension between the needs of the two groups of users.

[-] pileghoff@programming.dev 7 points 1 year ago* (last edited 1 year ago)

Why would I, an embedded developer working on devices with at most a couple of mb of flash, need to learn SQL?

[-] pileghoff@programming.dev 21 points 1 year ago

I usually use Json5. It's JSON, but with all the weird quirks fixed (comments added, you can use hex numbers, you can have trailing commas etc.)

[-] pileghoff@programming.dev 4 points 1 year ago

Is that always suppose to be shown? My counter example (the one that prompted this thread) is embassy_executor::Executor. When looking in the docs i dont see anywhere that its locked behind a feature flag, you have to look in the source

32

I have a written a bit of rust by now, but one problem I always seem to encounter it that the features a create supports never seem to be documented. Neither what features are available, what they each do or which are default. Is that really the case, or am I missing something?

I constantly seem to include something from the docs, only to be told by the compiler that it does not exist, and then I have to open the source for the create to figure out if it's hidden behind a feature flag.

Also, is it really true that I can't disable a single feature from the default set, without having to copy the default list and manually removing it?

[-] pileghoff@programming.dev 5 points 1 year ago

What have you done to harden Firefox? And what exactly are you trying to view?

[-] pileghoff@programming.dev 13 points 1 year ago

I think the truth is that not only can't WASM manipulate the DOM, but javascript was build to manipulate the DOM and has been moulded around this purpose. Secondly, if you want to use WASM from another programming language, that is just another language you need to learn on top of javascript, because we are not at a stage where we can replace javascript (because of the DOM). Fo most it's more cost effective to just optimize their javascript code instead of adding another layer to the tech stack.

[-] pileghoff@programming.dev 5 points 1 year ago

I think most applications store it in plain text, but makes sure the file is only readable by the current user. This way, we rely on the protection of the OS, instead of doing it ourselves. (I'm not a desktop app developer, so I might be completely wrong, but I think this is what e.g. Firefox does).

[-] pileghoff@programming.dev 4 points 1 year ago* (last edited 1 year ago)

How would they add runtime checking without breaking all existing code?

But I think warning people is a good start, because those checks can be added to your CI pipeline and reject any incoming code that contains warnings. That way you can enforce type checking for a subset of modules and keep backwards compatibility.

[-] pileghoff@programming.dev 85 points 1 year ago

First semester of my cs degree, it was around 50/50. After 3 semesters very few women were left. Spoiler: it was not because they could not handle the courses.

[-] pileghoff@programming.dev 6 points 1 year ago

The usual answer is mocking using something like FFF or cmock. Mocking allows you to write tests where you can swap out the implementation of certain functions. The two frameworks I linked will auto generate code to assert that the function was called a certain number of times or with the right arguments.

view more: next ›

pileghoff

joined 1 year ago