kevinpt / hdlparse

Simple parser for extracting VHDL documentation
http://kevinpt.github.io/hdlparse/
MIT License
70 stars 54 forks source link

matching end of entity and end of architecture #13

Open m-tosch opened 5 years ago

m-tosch commented 5 years ago

Entities and architectures can end with "end some_name;" instead of "end entity;" or "end architecture;" The regex should check for any word (maybe with \w) instead of the specific keywords "entity" and "architecture"

https://github.com/kevinpt/hdlparse/blob/be7cdab08a8c18815cc4504003ce9ca7fff41022/hdlparse/vhdl_parser.py#L87

https://github.com/kevinpt/hdlparse/blob/be7cdab08a8c18815cc4504003ce9ca7fff41022/hdlparse/vhdl_parser.py#L92

m-tosch commented 4 years ago

The same is also true for

package The same is true for packages. They can also end with "end some_name;" instead of "end package;" https://github.com/kevinpt/hdlparse/blob/be7cdab08a8c18815cc4504003ce9ca7fff41022/hdlparse/vhdl_parser.py#L35