Just some of the memory safety errors caught by Fil-C
github.com
github.com
This would be handy when writing programs for both Fil-C and Yolo-C. A developer would use Fil-C with all the nice diagnostics and for safe release builds; and if a user does not want Fil-C for some reason, well.. they can use regular C compiler. But this can only happen if the program does not rely on any Fil-C-only features, like FUGC.
FUGC is not a feature your code uses, just something that runs in the background to catch possible use-after-free cases, but triggering them is still an error and you won't want to ship any product with such bugs.
If you want to support Yolo-C in your codebase, then don’t rely on FUGC. Free your objects like normal.
But maybe you are writing code that’s all in for Fil-C. Then you might want to rely on FUGC.
Right now, the Fil-C runtime already relies on the GC in that it creates objects that don’t get freed. So it would already be hard to provide diagnostics about leaked objects. And since the GC is concurrent and runs at unpredictable times, any diagnostics it reported would be flaky.
FUGC really is designed to be something you rely on in production as opposed to being a leak detector.
See here: https://github.com/pizlonator/llvm-project-deluge/blob/delug...