The intermediate representation passed from the Mojom parser (the frontend of the Mojom compiler) to the code generators (the backend of the Mojom Compiler) is a MojomFileGraph
described in mojom_types.mojom and mojom_files.mojom in mojo/public/interfaces/bindings. Thus the Mojom compiler uses Mojo serialization to serialize the intermediate representation.
This situation potentially entails a circular dependency because it means that in order to build the Mojom compiler it is necessary to use code that has been generated by the Mojom compiler. In order to break this circular dependency we check in the generated code needed by the compiler rather than generating it while building the compiler.
This directory contains the checked-in generated Go code used by the frontend of the compiler: mojom_files/mojom_files.mojom.go and mojom_types/mojom_types.mojom.go.
The backend of the Mojom compiler is written in Python and the corresponding generated Python files may be found in mojo/public/tools/bindings/pylib/mojom/generate/generated/mojom_files_mojom.py and mojo/public/tools/bindings/pylib/mojom/generate/generated/mojom_types_mojom.py