| ▲ | inigyou 2 days ago | |
Nice pedantry. How does it prevent multiple coexisting mutable references? | ||
| ▲ | BobbyTables2 2 days ago | parent | next [-] | |
It’s not pedantry. Pointers and references are truly different things. A normal C compiler actually has to worry about a lot of extreme cases. Imagine a function takes two pointer arguments. What if they point to the same thing? What if one points to the other and is used for a write? The nature of the code generated varies greatly if these are possibilities… | ||
| ▲ | aw1621107 2 days ago | parent | prev [-] | |
I'm not sure you need to? Rust references don't exist in C, after all. That being said I wouldn't be surprised if there were other factors that would weigh against considering FFI calls to Fil-C safe by default (e.g., Fil-C's somewhat looser bounds on what is considered a valid pointer access). | ||