emustudio / edigen

Emulator Disassembler Generator
GNU General Public License v3.0
4 stars 0 forks source link

Implement explicit root rules declaration #48

Closed vbmacher closed 3 years ago

vbmacher commented 3 years ago

There are missing checks for detection multiple names of the same rule

vbmacher commented 3 years ago

A deduplicate root rules visitor has been implemented

vbmacher commented 3 years ago

TODO: root rules which have multiple names are called possibly by wrong name. Rule names in root rule declaration are translated into Rule objects and the names are forgotten. Then in decoder rules are called as rule_first_name(start, RULE_FIRST_NAME) instead of rule_first_name(start, RULE_NAME_USED_IN_ROOT_RULE_DECLARATION)

vbmacher commented 3 years ago

TODO: root rules which have multiple names are called possibly by wrong name. Rule names in root rule declaration are translated into Rule objects and the names are forgotten. Then in decoder rules are called as rule_first_name(start, RULE_FIRST_NAME) instead of rule_first_name(start, RULE_NAME_USED_IN_ROOT_RULE_DECLARATION)

It's done now.