Skip to content

Commit e0c8aec

Browse files
author
Sebastian Kaupper
committed
Add parsing of context reference blocks together with context declarations
Add functions to the TokenToBlockParser which can be generally useful: HandleNonCodeTokens creates NonCode (i.e. whitespace and comment) blocks. The LRM allows these blocks basically everywhere. Note: Delimited comments are strictly speaking not separators according to the LRM (§15.3)! ReparseFromTokenMarker allows to iterate over a set of tokens a second time. This is useful if you cannot decide the block type based on a single token. `Context.StartBlock` searches ahead (without modifying tokens or adding blocks) until it can decide whether the `context` keyword is used in a context declaration or a context reference. Additionally, some changes are made to satisfy the static type checker.
1 parent d762084 commit e0c8aec

6 files changed

Lines changed: 827 additions & 224 deletions

File tree

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,3 +25,4 @@ coverage.xml
2525
/.idea/workspace.xml
2626

2727
pyVHDLParser/Sven
28+
venv/

0 commit comments

Comments
 (0)