Skip to main content

Module preproc

Module preproc 

Source
Expand description

The C-family preprocessor pass: the include graph, macro collection, and the PreprocResults document.

Structs§

PreprocFile
Preprocessor data of a C/C++ file.
PreprocResults
Preprocessor data of a series of C/C++ files.

Enums§

PreprocDiagnostic
A non-fatal diagnostic produced while resolving the C/C++ include graph in fix_includes.

Functions§

fix_includes
Constructs a dependency graph of the include directives in a C/C++ file.
get_macros
Returns the macros contained in a C/C++ file.
preprocess
Extracts preprocessor data from a C/C++ source buffer and inserts it into a PreprocResults object.
preprocess_with_parser
Walk an already-built PreprocParser tree, accumulating its preprocessor data into results. Internal core shared by the public preprocess seam and the crate’s own preprocessor tests.
visible_macros
Every macro name visible to file — its own #defines plus those of every header it transitively includes — borrowed from files.