187 if (sym.kind == TYP && |
187 if (sym.kind == TYP && |
188 (sym.flags() & STATIC) != 0 && |
188 (sym.flags() & STATIC) != 0 && |
189 staticImportAccessible(sym, packge) && |
189 staticImportAccessible(sym, packge) && |
190 sym.isMemberOf(origin, types) && |
190 sym.isMemberOf(origin, types) && |
191 !toScope.includes(sym)) |
191 !toScope.includes(sym)) |
192 toScope.enter(sym, fromScope, origin.members()); |
192 toScope.enter(sym, fromScope, origin.members(), true); |
193 } |
193 } |
194 } |
194 } |
195 }.importFrom(tsym); |
195 }.importFrom(tsym); |
196 |
196 |
197 // enter non-types before annotations that might use them |
197 // enter non-types before annotations that might use them |
215 Symbol sym = e.sym; |
215 Symbol sym = e.sym; |
216 if (sym.isStatic() && sym.kind != TYP && |
216 if (sym.isStatic() && sym.kind != TYP && |
217 staticImportAccessible(sym, packge) && |
217 staticImportAccessible(sym, packge) && |
218 !toScope.includes(sym) && |
218 !toScope.includes(sym) && |
219 sym.isMemberOf(origin, types)) { |
219 sym.isMemberOf(origin, types)) { |
220 toScope.enter(sym, fromScope, origin.members()); |
220 toScope.enter(sym, fromScope, origin.members(), true); |
221 } |
221 } |
222 } |
222 } |
223 } |
223 } |
224 public void enterAnnotation() { |
224 public void enterAnnotation() { |
225 importFrom(tsym); |
225 importFrom(tsym); |
281 if (sym.isStatic() && |
281 if (sym.isStatic() && |
282 sym.kind == TYP && |
282 sym.kind == TYP && |
283 staticImportAccessible(sym, packge) && |
283 staticImportAccessible(sym, packge) && |
284 sym.isMemberOf(origin, types) && |
284 sym.isMemberOf(origin, types) && |
285 chk.checkUniqueStaticImport(pos, sym, toScope)) |
285 chk.checkUniqueStaticImport(pos, sym, toScope)) |
286 toScope.enter(sym, sym.owner.members(), origin.members()); |
286 toScope.enter(sym, sym.owner.members(), origin.members(), true); |
287 } |
287 } |
288 } |
288 } |
289 }.importFrom(tsym); |
289 }.importFrom(tsym); |
290 |
290 |
291 // enter non-types before annotations that might use them |
291 // enter non-types before annotations that might use them |
311 Symbol sym = e.sym; |
311 Symbol sym = e.sym; |
312 if (sym.isStatic() && |
312 if (sym.isStatic() && |
313 staticImportAccessible(sym, packge) && |
313 staticImportAccessible(sym, packge) && |
314 sym.isMemberOf(origin, types)) { |
314 sym.isMemberOf(origin, types)) { |
315 found = true; |
315 found = true; |
316 if (sym.kind == MTH || |
316 if (sym.kind != TYP) { |
317 sym.kind != TYP && chk.checkUniqueStaticImport(pos, sym, toScope)) |
317 toScope.enter(sym, sym.owner.members(), origin.members(), true); |
318 toScope.enter(sym, sym.owner.members(), origin.members()); |
318 } |
319 } |
319 } |
320 } |
320 } |
321 } |
321 } |
322 public void enterAnnotation() { |
322 public void enterAnnotation() { |
323 JavaFileObject prev = log.useSource(env.toplevel.sourcefile); |
323 JavaFileObject prev = log.useSource(env.toplevel.sourcefile); |