| Summary: | xtend2 does not validate imports | ||
|---|---|---|---|
| Product: | [Modeling] TMF | Reporter: | Matthias Wienand <matthias.wienand> |
| Component: | Xtext | Assignee: | Project Inbox <tmf.xtext-inbox> |
| Status: | CLOSED DUPLICATE | QA Contact: | |
| Severity: | minor | ||
| Priority: | P3 | CC: | nyssen, sebastian.zarnekow |
| Version: | 2.0.1 | Flags: | sebastian.zarnekow:
indigo+
|
| Target Milestone: | SR2 | ||
| Hardware: | PC | ||
| OS: | Linux | ||
| Whiteboard: | |||
*** This bug has been marked as a duplicate of bug 300906 *** |
Build Identifier: I20110613-1736 You can place arbitrary imports in a .xtend file without getting response on whether the specified import is legal or not. Example: [xtend] import it.aint.there [/xtend] Such import statements should be highlighted appropriately. When generating the DSL, the imports get reorganized, so that illegal imports do not make it into the generated code and some of the required imports are added automatically. Nevertheless, import validation could reduce the time needed to find "bugs" that are just misspelled imports. Example: [xtend] import org.eclipse.xtext.generator.IFilesystemAccess class DatadslGenerator implements IGenerator { override void doGenerate(Resource resource, IFileSystemAccess fsa) { } } [/xtend] In this example the IFileSystemAccess interface cannot be resolved, because the respective import is misspelled. Reproducible: Always Steps to Reproduce: 1. Create a new .xtend file 2. Add an import statement: "import it.aint.there" 3. As you can see, the import statement is neither marked nor listed as a problem.