Earlier quoted context omitted.
Though I haven't tried it, I understand that some people do development inside a Docker container, so maybe you don't need to run Linux on your desktop? It seems like a trick that's worth learning.
I'm aware of all these tricks including VSCode devcontainer. It's just a higher celling no matter how you slice it. The solutions with the least amount of resistance tends to win. Look how easy it's to try these. I don't have to set up VMs or even know what make is to do anything. - dotnet: https://dotnet.microsoft.com/en-us/download - rust: https://www.rust-lang.org/learn/get-started - go: https://go.dev/dl/ If you…
The Hare programming language
301–310 of 323 posts
Re: The Hare programming language
#302lol my other post got flagged, so let me reiterate perhaps in a less inflammatory way. It is disappointing to see that "trust the programmer" is a design goal. Programmers can not be trusted with manual memory management. We have decades of proof, billions and billions of dollars of bug fixes and mitigation investments, real world damages, etc. Building a language like this and saying you hope it will be the foundati…
Why are you afraid of manual memory management?
The world is just doing fine with it, because, believe me or not, the world's worst problems like violence, war, poverty, famine, just to name a few, are not caused by C bugs.
Re: The Hare programming language
#303Earlier quoted context omitted.
It's certainly much more complicated than Go, and not just on the surface
But they are nowhere near the same niche. Go is much much closer to JS than to Rust by design, it just mimics being lower-level. System level programming almost by definition requires quite a bit of complexity, and you can’t hide it no matter how elegant your abstraction is. Essential complexity is non-reduceable:
Re: The Hare programming language
#304Earlier quoted context omitted.
There are plans to research an optional borrow checker for Hare. Hare also does offer many "safety" advantages over C: checked slice and array access, exhaustive switch and match, nullable pointer types, less undefined behavior, no strict pointer aliasing, fewer aggressive optimizations, and so on. Hare code is much less likely to have these errors when compared to C code. I would ultimately just come out and say tha…
I think a section on safety might be worthwhile. For example, Zig pretty clearly states that it wants to focus on spatial memory safety, which it sounds like Hare is going for as well. That's certainly an improvement and worth noting, although it obviously leaves temporal safety on the table. > but the argument that we're morally in the wrong to prefer another approach is not really appreciated. Well, sorry to hear i…
I guess not having to type keywords in caps (because who uses IDE/smart editors) and having a C like syntax is the selling point.
Re: The Hare programming language
#305Earlier quoted context omitted.
What necessary use case of macros isn’t addressed by comptime in zig?
zig comptime is the same as constexpr/consteval in C++ which operate on variables and valid code blocks. C macros operate on arbitrary tokens, which get converted to code or constants. For example variadic functions can be implemented to act on token arglists that act as abstract tuples: https://github.com/FrozenVoid/C-headers/blob/main/argmanip.h
It's an explicit goal of the language that you can tell what the local control flow is by reading the code, but of course one is free to run the C preprocessor as part of the build if one disagrees.
I don't think C++ constexpr/consteval can be used to write things like generic json serializers and deserializers, which Zig does in the standard library using comptime, but I'm not sure.
Re: The Hare programming language
#306Earlier quoted context omitted.
I don't think many Zig programmers miss C macros. Comptime is extremely powerful.
C macros are powerful enough to create entire functional languages at compile time, which is far beyond any constexpr functions. https://github.com/rofl0r/order-pp
Re: The Hare programming language
#307Earlier quoted context omitted.
C doesn't exactly have macros. That's a text substitution done by the preprocessor in its own limited, special-purpose language. True hygienic macros of something like Common Lisp are a different beast. If all you want are textual substitutions, you can use the C preprocessor in front of any language.
Common Lisp does have macros, but not hygienic macros.
Re: The Hare programming language
#308Earlier quoted context omitted.
> you can use the C preprocessor in front of any language. You will be paddling upriver if that language doesn't have a mostly C-compatible token structure, or has white space sensitivities that C preprocessing doesn't preserve and such.
The C Preprocessor has sensitivities that aren't matched by C in all cases. And in the case of Hare, the tokenisation should be close enough to C that the CPP would only break in the same ways it already does.
Re: The Hare programming language
#309Earlier quoted context omitted.
Modern web programming is almost always deployed on Unix-like operating systems / Linux. The biggest reason to allow running Hare on Windows/macOS would just be for developers who don't use Linux.
Correct, which outnumbers the number of developers using Linux only right? Why cut a substantial amount of your possible user base?
Keeping the scope niche/small seems like a feature to me, not a bug. Let non-FOSS OS users find something else (?)
I am personally no FOSS zealot but I can respect a project that has a firm idea of its scope and targeted user base and wishes to stay limited to that
Not everything needs to be huge or growth hacked to death
Re: The Hare programming language
#310Earlier quoted context omitted.
As other commenters alluded to, it's an ideological and practical decision. We simply prefer free software operating systems. We do not care to legitimize nonfree platforms, and we prefer to be able to read (and patch) the code to understand the tools we depend on. If that's a deal-breaker for you, no worries - Hare does not have to appeal to everyone to achieve its goals.
For those not familiar with the concept: this is how moral backbone looks like.