Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
caim
searching Neon…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
5 ms
·
1.
▲
by
caim
1y ago
funny thing is that Malloc also behaves like an arena. When your program starts, Malloc reserves a lot of memory, and when your program ends, all this memory is released. Memory Leak ends up not being a problem with Memory Safety. So, you w
2.
▲
by
caim
1y ago
I really didn't expect that from the land of freedom. /s
3.
▲
by
caim
1y ago
- lol people really say whatever comes to their mind around here don't they? Apple literally hired Chris Lattner in 2005 and made a team to work on LLVM. After GNU refused to integrate LLVM into GCC, But Apple saw an opportunity to hav
4.
▲
by
caim
1y ago
Swift has its own ABI and calling convention, so that makes sense that Apple adapted to it. The system v abi doesn't say anything about syscall. Windows x86_64 abi is the same abi for x86, for this reason, you can only pass arguments i
5.
▲
by
caim
1y ago
You right. Always good to remember that Apple was and still is the main company behind LLVM. Swift was built and its maintained by the same time that worked in LLVM. And also, Swift has its own fork of LLVM and LLVM has built-in a lot of fe
6.
▲
by
caim
1y ago
Wow, thanks! I didn't know this project. To parse C++ you need to perform typecheck and name resolution at the same time. And C++ is pretty complex so it's not a easy task.
7.
▲
by
caim
1y ago
Just parsing C++ is already a freaking hell. It's no wonder that every other day a new mini C compiler drops in, while no one even attempts to parse C++.
8.
▲
by
caim
1y ago
That's great! Interop with C++ is such a complex task. Congratss on your work! It's definitely not an easy thing. I've always wondered what is the best way to interact with C++ template instantiation while keeping performance
9.
▲
by
caim
1y ago
C ABI is the system V abi for Unix, since C was literally created for it. And that is the abi followed by pretty much any Unix successor: Linux, Apple's OS, FreeBSD. Windows has its own ABI. The different abi is pretty much legacy and
10.
▲
by
caim
1y ago
Yep, that's true. But multiple immutable shared references are a form of contraction, while mutable references are actually affine. Swift doesn't have references like Rust, and you can't even have unsafe raw pointers to varia
11.
▲
by
caim
1y ago
Yeah, that makes sense. The Rust type system isn't "affine" as in affine logic. Rust allows different forms of contraction, which affine logic strictly prohibits. And some people like to claim that the Curry-Howard correspond
12.
▲
by
caim
1y ago
Great work! Also, the error messages are neat!
13.
▲
by
caim
1y ago
The main point of Affine logic is that it doesn't allow contraction, and the Rust type system does allow different forms of contraction. How exactly is Rust an "affine language"? Also, the claims about Curry-Howard correspond
14.
▲
by
caim
1y ago
Funny thing is that you can get undefined behavior and segfaults using only "safe rust", and the rust compiler has subtle bugs that allow you to disable important checks (like type checking), which can leave your code completely b
15.
▲
by
caim
1y ago
And how would you conclude that "fast"? You can have UB in "safe rust". https://github.com/Speykious/cve-rs You can even disable the Type check, trait check and borrow check in "safe rust"