vhdl.xml 1.6 KB

123456789101112131415161718192021222324252627282930313233343536373839
  1. <?xml version="1.0" encoding="UTF-8" ?>
  2. <!-- ==========================================================================\
  3. |
  4. | To learn how to make your own language parser, please check the following
  5. | link:
  6. | https://npp-user-manual.org/docs/function-list/
  7. |
  8. \=========================================================================== -->
  9. <NotepadPlus>
  10. <functionList>
  11. <!-- ======================================================== [ VHDL ] -->
  12. <!--
  13. | Derived from :
  14. | https://community.notepad-plus-plus.org/topic/11554/function-list-for-vhdl
  15. \-->
  16. <parser
  17. displayName="VHDL"
  18. id ="vhdl_syntax"
  19. >
  20. <function
  21. mainExpr="(?x) # free-spacing (see `RegEx - Pattern Modifiers`)
  22. ^ # match at beginning of line
  23. \h* # optional leading whitespace
  24. (\w+\h*:)? # ID of process
  25. (?:\h(?!END)\w+\h)* # make sure this is not the end of a module
  26. \h*
  27. (?(1)(?:ENTITY|BLOCK|PROCESS)| # keywords if ':' was detected before
  28. (?:ENTITY|COMPONENT|ARCHITECTURE)) # keywords else
  29. [\h\(]+ # expect at least one blank or parentheses
  30. [A-Za-z0-9_\(\)., ]+ # ID or sensitivity list
  31. (?!\;)"
  32. >
  33. <functionName>
  34. <nameExpr expr=".*" />
  35. </functionName>
  36. </function>
  37. </parser>
  38. </functionList>
  39. </NotepadPlus>