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

Typescript projects are a significant effort to set up with the traditional tooling (NPM & Node). With Deno you can literally just create a .ts file and run it.

[-] FizzyOrange@programming.dev 2 points 8 months ago

To be honest I suspect they wanted to do this before, but the power mods wouldn't allow it. I definitely remember the staff posting a proposal to allow second chances for closed questions, and it was downvoted to hell by the mods. They presumably got scared because they were getting a lot of free labour from the mods (even if it probably wasn't exactly the kind they wanted).

Now StackOverflow is dead the mods have no power, so they are free to make changes.

[-] FizzyOrange@programming.dev 2 points 2 years ago

Sounds awesome. Good luck!

[-] FizzyOrange@programming.dev 2 points 2 years ago

all genders

Uhm what?

[-] FizzyOrange@programming.dev 2 points 2 years ago

You could do some of it in Python, but some stuff needs low level access to registers, e.g. trap handlers and context switching.

Should you do that? Absolutely fucking not. It would be hilariously slow and inefficient. Hundreds of times, maybe thousands of times slower than C/C++ kernels.

[-] FizzyOrange@programming.dev 2 points 2 years ago

No that's a subtly different thing. The storage is a contiguous vector, but because it is a ring buffer there must be one pair of adjacent elements that are not contiguous in memory. That's what that comment is saying.

But because it is only one discontinuity it doesn't affect algorithmic complexity, so it is still O(1) to access elements, unlike a linked list which is O(N).

If you google "circular buffer" there will be loads of diagrams that make it really obvious how it works.

[-] FizzyOrange@programming.dev 2 points 2 years ago

Screenshots. Print screen. Wayland famously doesn't have a way to do this very basic task (all of the desktop environments had to add custom extensions).

Seems like they finally did it though really recently. And it only took 12 years!

[-] FizzyOrange@programming.dev 2 points 2 years ago

I dunno it looks well designed but I dunno why I would use it instead of Rust.

[-] FizzyOrange@programming.dev 2 points 2 years ago

I agree. Even when copilot gets something completely wrong it's usually easier to think "no that's wrong, it should be this" than "ok the first line of code should be...".

It completely solves the "blank page" problem.

[-] FizzyOrange@programming.dev 2 points 2 years ago

Pip and venv have been tools that I’ve found to greatly accelerate dev setup and application deployment.

I'm not saying pip and venv are worse than not using them. They're obviously mandatory for Python development. I mean that compared to other languages they provide a pretty awful experience and you'll constantly be fighting them. Here's some examples:

  • Pip is super slow. I recently discovered uv which is written in Rust and consequently is about 10x faster (57s to 7s in my case).
  • Pip gives terrible error messages. For example it assumes all version resolution failures are due to requirements conflicts, when actually it can be due to Python version requirements too so you get insane messages like "Requirement foo >= 2.0 conflicts with requirement foo == 2.0". Yeah really.
  • You can't install multiple versions of the same dependency, so you end up in dependency resolution hell (depA depends on foo >= 3 but depB depends on foo <= 2).
  • No namespace support for package names so you can't securely use private PyPI repositories.
  • To make static typing work properly with Pyright and venv and everything you need some insane command like pip install --conf-settings editable-mode=compat --editable ./mypackage. How user friendly. Apparently when they changed how editable packages were installed they were warned that it would break all static tooling but did it anyway. Good job guys.
  • When you install an editable package in a venv it dumps a load of stuff in the package directory, which means you can't do it twice to two different venvs.
  • The fact that you have to use venvs in the first place is a pain. Don't need that with Deno.

There's so much more but this is just what I can remember off the top of my head. If you haven't run into these things just be glad your Python usage is simple enough that you've been lucky!

I’m actually in the process of making such a push where I’m at, for the first time in my career

Good luck!

[-] FizzyOrange@programming.dev 2 points 2 years ago

That depends on how readable you want the output to be. It's already pretty bad on that front. If you start supporting arbitrary features it's going to end up as a bytecode interpreter. Which would be pretty cool too tbf! Has anyone written a WASM runtime in bash? 😄

[-] FizzyOrange@programming.dev 2 points 2 years ago

How are you going to find references to prize, go to its definition or rename it without knowing what type x is? It's impossible without static types.

view more: ‹ prev next ›

FizzyOrange

0 post score
0 comment score
joined 3 years ago