69 for (T tree: trees) |
69 for (T tree: trees) |
70 lb.append(copy(tree, p)); |
70 lb.append(copy(tree, p)); |
71 return lb.toList(); |
71 return lb.toList(); |
72 } |
72 } |
73 |
73 |
|
74 public JCTree visitAnnotatedType(AnnotatedTypeTree node, P p) { |
|
75 JCAnnotatedType t = (JCAnnotatedType) node; |
|
76 List<JCTypeAnnotation> annotations = copy(t.annotations, p); |
|
77 JCExpression underlyingType = copy(t.underlyingType, p); |
|
78 return M.at(t.pos).AnnotatedType(annotations, underlyingType); |
|
79 } |
|
80 |
74 public JCTree visitAnnotation(AnnotationTree node, P p) { |
81 public JCTree visitAnnotation(AnnotationTree node, P p) { |
75 JCAnnotation t = (JCAnnotation) node; |
82 JCAnnotation t = (JCAnnotation) node; |
76 JCTree annotationType = copy(t.annotationType, p); |
83 JCTree annotationType = copy(t.annotationType, p); |
77 List<JCExpression> args = copy(t.args, p); |
84 List<JCExpression> args = copy(t.args, p); |
78 return M.at(t.pos).Annotation(annotationType, args); |
85 return M.at(t.pos).Annotation(annotationType, args); |
231 JCMethodDecl t = (JCMethodDecl) node; |
238 JCMethodDecl t = (JCMethodDecl) node; |
232 JCModifiers mods = copy(t.mods, p); |
239 JCModifiers mods = copy(t.mods, p); |
233 JCExpression restype = copy(t.restype, p); |
240 JCExpression restype = copy(t.restype, p); |
234 List<JCTypeParameter> typarams = copy(t.typarams, p); |
241 List<JCTypeParameter> typarams = copy(t.typarams, p); |
235 List<JCVariableDecl> params = copy(t.params, p); |
242 List<JCVariableDecl> params = copy(t.params, p); |
|
243 List<JCTypeAnnotation> receiver = copy(t.receiverAnnotations, p); |
236 List<JCExpression> thrown = copy(t.thrown, p); |
244 List<JCExpression> thrown = copy(t.thrown, p); |
237 JCBlock body = copy(t.body, p); |
245 JCBlock body = copy(t.body, p); |
238 JCExpression defaultValue = copy(t.defaultValue, p); |
246 JCExpression defaultValue = copy(t.defaultValue, p); |
239 return M.at(t.pos).MethodDef(mods, t.name, restype, typarams, params, thrown, body, defaultValue); |
247 return M.at(t.pos).MethodDef(mods, t.name, restype, typarams, params, receiver, thrown, body, defaultValue); |
240 } |
248 } |
241 |
249 |
242 public JCTree visitMethodInvocation(MethodInvocationTree node, P p) { |
250 public JCTree visitMethodInvocation(MethodInvocationTree node, P p) { |
243 JCMethodInvocation t = (JCMethodInvocation) node; |
251 JCMethodInvocation t = (JCMethodInvocation) node; |
244 List<JCExpression> typeargs = copy(t.typeargs, p); |
252 List<JCExpression> typeargs = copy(t.typeargs, p); |
355 return M.at(t.pos).TypeIdent(t.typetag); |
363 return M.at(t.pos).TypeIdent(t.typetag); |
356 } |
364 } |
357 |
365 |
358 public JCTree visitTypeParameter(TypeParameterTree node, P p) { |
366 public JCTree visitTypeParameter(TypeParameterTree node, P p) { |
359 JCTypeParameter t = (JCTypeParameter) node; |
367 JCTypeParameter t = (JCTypeParameter) node; |
|
368 List<JCTypeAnnotation> annos = copy(t.annotations, p); |
360 List<JCExpression> bounds = copy(t.bounds, p); |
369 List<JCExpression> bounds = copy(t.bounds, p); |
361 return M.at(t.pos).TypeParameter(t.name, t.bounds); |
370 return M.at(t.pos).TypeParameter(t.name, bounds, annos); |
362 } |
371 } |
363 |
372 |
364 public JCTree visitInstanceOf(InstanceOfTree node, P p) { |
373 public JCTree visitInstanceOf(InstanceOfTree node, P p) { |
365 JCInstanceOf t = (JCInstanceOf) node; |
374 JCInstanceOf t = (JCInstanceOf) node; |
366 JCExpression expr = copy(t.expr, p); |
375 JCExpression expr = copy(t.expr, p); |