A gccjit.Location encapsulates a source code location, so that you can (optionally) associate locations in your language with statements in the JIT-compiled code, allowing the debugger to single-step through your language.
You can construct them using
gccjit.Location instances are optional; most API entrypoints accepting one default to None.
If you don’t have source code for your internal representation, but need
to debug, you can generate a C-like representation of the functions in
your context using
This will dump C-like code to the given path. If the update_locations argument is True, this will also set up gccjit.Location information throughout the context, pointing at the dump file as if it were a source file, giving you something you can step through in the debugger.