Details
-
Bug
-
Status: Closed
-
Major
-
Resolution: Fixed
-
None
-
None
Description
This is a follow-on of GROOVY-8254 for groovysh. We may end up closing this issue with no change but a few aspects seem worth considering:
- Following the stricter interpretation by the compiler, adding a second (duplicate) import via the groovysh now causes a compiler "evaluate" error. Do we want to be more lenient in the repl context and in fact treat the import "list" like a simple name to class map and override old entries. This would be more repl-like in style.
- If I define a class and then do an import, then the class is ignored with no error. Perhaps we want an error in that case.
groovy:000> class Date{} ===> true groovy:000> :show classes Classes: class Date ===> [class Date] groovy:000> import java.sql.Date ===> java.sql.Date groovy:000> println Date class java.sql.Date
Attachments
Issue Links
- is a clone of
-
GROOVY-8254 Alias is ignored in constructor call
- Closed
- links to