diff options
| author | Garming Sam <garming_sam@outlook.com> | 2015-08-09 21:09:55 +1200 |
|---|---|---|
| committer | Garming Sam <garming_sam@outlook.com> | 2015-08-09 21:09:55 +1200 |
| commit | fdba872944675a2c2aa146ab3caadbad14452e97 (patch) | |
| tree | abc0d36f41cc99b1b86e5402d03b1ed5c633785c | |
| parent | ed9f8f83c90e995ad41f8c3c26f81d34900ec631 (diff) | |
| download | rust-fdba872944675a2c2aa146ab3caadbad14452e97.tar.gz rust-fdba872944675a2c2aa146ab3caadbad14452e97.zip | |
Add a proper comment for create_resolver
| -rw-r--r-- | src/librustc_resolve/lib.rs | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/librustc_resolve/lib.rs b/src/librustc_resolve/lib.rs index 37bf571e0bb..d044202c3ef 100644 --- a/src/librustc_resolve/lib.rs +++ b/src/librustc_resolve/lib.rs @@ -4034,6 +4034,14 @@ pub fn resolve_crate<'a, 'tcx>(session: &'a Session, } } +/// Builds a name resolution walker to be used within this module, +/// or used externally, with an optional callback function. +/// +/// The callback takes a &mut bool which allows callbacks to end a +/// walk when set to true, passing through the rest of the walk, while +/// preserving the ribs + current module. This allows resolve_path +/// calls to be made with the correct scope info. The node in the +/// callback corresponds to the current node in the walk. pub fn create_resolver<'a, 'tcx>(session: &'a Session, ast_map: &'a ast_map::Map<'tcx>, krate: &'a Crate, |
