Khyber Sen
Khyber Sen
I've realized that, given we only instrument the primary package, that means we instrument: * 0 or 1 library target * 0 or 1 test target for unit tests (the...
Currently, we can put the metadata file (usually called `metadata.bc`) anywhere with `--metadata` and `$METADATA`. However, this means we usually put it in the same place between different profiles (`debug`,...
The `rustc` version used to build `c2rust` in `rust-toolchain.toml` is unnecessarily tied to the `rustc` version emitted in a `rust-toolchain.toml` in transpiler-generated crates. These should be maintained and updated separately,...
Now that https://github.com/rust-lang/rust/pull/97423 has landed, we can generate atomic intrinsics for all combinations of memory ordering arguments instead of restricting them.
In [`rav1d`](https://github.com/memorysafety/rav1d), we need `const` initialization of bitfield `struct`s to initialization `static`s. Otherwise, the `static` has to be `mut`, which is `unsafe` to access (or else you have to pay...
For custom allocator/deallocator functions other than `{m,c,re}alloc` and `free`, such as: * `getaddrinfo` and `freeaddrinfo` * `open`, etc. and `close` * `glob` and `globfree` * `mmap` and `munmap` it would...
For `KnownFn`s like ```rust fn strchr( // `WRITE` because the return type is derived from `cs`'s provenance. cs: *const c_char: [READ | WRITE | OFFSET_ADD | NON_NULL], c: c_int, )...
* Fixes #996. Use `SubstsRef` when creating an `Instance` to get the `SymbolName` so that we don't ICE on generic foreign `fn`s like `extern "rust-intrinsic"`s.
3c038606a32329d3e4ce21e308e8a49635a6d44f adds the simple (still incomplete) dataflow constraints for `CastKind::Misc` (fixes the minimum outlined in https://github.com/immunant/c2rust/pull/839#discussion_r1218701683). The full constraints are trickier since the types can be recursive, so I wanted...
Fixes #682. More specifically, it fixes the low-hanging fruit of achieving strict provenance by replacing `0 as *{const,mut} _` with `std::ptr::null{,_mut}()`. The real int-to-ptr instances where `std::ptr::from_exposed_addr` and `ptr::expose_addr()` should...