diff options
| author | Caio <c410.f3r@gmail.com> | 2019-08-24 13:54:40 -0300 |
|---|---|---|
| committer | Caio <c410.f3r@gmail.com> | 2019-08-24 13:54:40 -0300 |
| commit | 6a3d51731408708cbc6a6e4e2683da8df7326007 (patch) | |
| tree | e57ad90ed14af52efe942e2280640e5ed6dd8c4f /src/libsyntax/ext | |
| parent | 478464570e60523adc6d303577d1782229ca1f93 (diff) | |
| download | rust-6a3d51731408708cbc6a6e4e2683da8df7326007.tar.gz rust-6a3d51731408708cbc6a6e4e2683da8df7326007.zip | |
Modifies how Arg, Arm, Field, FieldPattern and Variant are visited
Part of the necessary work to accomplish #63468.
Diffstat (limited to 'src/libsyntax/ext')
| -rw-r--r-- | src/libsyntax/ext/expand.rs | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/src/libsyntax/ext/expand.rs b/src/libsyntax/ext/expand.rs index 72f2c1375e7..92b48ed62cd 100644 --- a/src/libsyntax/ext/expand.rs +++ b/src/libsyntax/ext/expand.rs @@ -1210,9 +1210,13 @@ impl<'a, 'b> MutVisitor for InvocationCollector<'a, 'b> { } } - fn visit_generic_params(&mut self, params: &mut Vec<ast::GenericParam>) { - self.cfg.configure_generic_params(params); - noop_visit_generic_params(params, self); + fn flat_map_generic_param( + &mut self, + param: ast::GenericParam + ) -> SmallVec<[ast::GenericParam; 1]> + { + let param = configure!(self, param); + noop_flat_map_generic_param(param, self) } fn visit_attribute(&mut self, at: &mut ast::Attribute) { |
