Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Teach ast.Resolve() about 'include' paths (#34)
We previously assumed a 1-to-1 relationship between type reference names and .thrift files in the search path, but the 'include' header allows for an additional degree of indirection. For example, we could `include "subdir/file.thrift"`, which allows for type references named `file.TypeName`, but the previously logic would fail to load `file.thrift` unless `subdir/` was explicitly added as a search directory. The revised approach implemented here first searches all of the program's 'include' headers to resolve the given include path (e.g. `subdir/file.thrift`) and then attempts to parse _that_ path relative to one of the configured search directories.
- Loading branch information