Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Message fields can reference enum types before they're defined in a proto file. Even if all enums are loaded before all messages, messages can define nested proto types, which means that the order message types are read in can determine whether field's type exists before it is referenced. The workaround for this is to do a two pass type resolution: load top level enums and top level messages (which may recursively add additional types), then resolve any field in any message whose type is empty. This cl extends existing logic for out of order message definitions to include out of order enums.
- Loading branch information