7. VHDL
• 20 year old language (based on Ada)
• all shortcomings of arcane languages
• verbose
• irregular
• ...
7
8. Perfect fit for ?
• Xtext looks like perfect fit:
• navigation • navigation
• • type time syntax checking
type time syntax checking
Grammar
• • linting and quick-fixes
linting and quick-fixes
• formatting • formatting
• But: Powerful enough for VHDL?
8
12. Grammar
• Grammar
• Scoping
• UI
• Autocomplete • Lexer: No problems
• Formatting (We had ANTLR grammar to start from)
• Testing
• Parser: No semantic predicates
• Performance
• Keep track of the number/size of
objects that are created
12
13. Scoping
• Grammar
• Scoping
• UI
• Autocomplete
• Formatting • A lot harder than expected
• Testing
• Difficult to debug (declarative
• Performance
approach, lazy evaluation)
13
14. User Interface
• Grammar
• Scoping • Works as expected : outline,
• UI preferences, templates, folding,
• Autocomplete (syntax and semantic)
• Formatting highlighting
• Testing
• Xtext team keeps adding nice
• Performance
improvements
• Some scalability issues: Large
files are problematic in UI (n 2
problems)
14
15. Autocomplete
• Grammar
• Scoping
• UI
• Autocomplete based on
• Autocomplete
grammar/scope is not powerful
• Formatting
enough
• Testing
• autocomplete is mostly triggered for
incomplete code (incorrect context)
• Performance
• extended toolkit would be better
• Most VHDL autocompletes are
manually designed
15
16. Formatting
• Grammar
• Scoping
• UI
• Needs a lot of customization
• Autocomplete
• Formatting
• A lot cleaner to implement than
• Testing
what e.g. Emacs does
• Performance • Priority of rules not always clear
• Custom extension for vertical
alignment
16
17. Testing
• Grammar
• Scoping
• UI
• Autocomplete
• Formatting
• Xtext itself contains good
• Testing
starting points
• Performance • Dependency injection (Guice)
makes it easy to test
17
20. Conclusions
• Xtext is really powerful technology
• Gives great architecture/structure
• Getting started is easy
• But... still a lot of work
• Devil is in the details
20