cython.nanorc 1007 B

12345678910111213141516171819202122232425262728293031
  1. ## Cython nanorc, based off of Python nanorc.
  2. ##
  3. syntax "cython" "\.pyx$" "\.pxd$" "\.pyi$"
  4. icolor brightred "def [ 0-9A-Z_]+"
  5. icolor brightred "cpdef [0-9A-Z_]+\(.*\):"
  6. icolor brightred "cdef cppclass [ 0-9A-Z_]+\(.*\):"
  7. # Python Keyword Color
  8. color green "\<(and|as|assert|class|def|DEF|del|elif|ELIF|else|ELSE|except|exec|finally|for|from|global|if|IF|import|in|is|lambda|map|not|or|pass|print|raise|try|while|with|yield)\>"
  9. color brightmagenta "\<(continue|break|return)\>"
  10. # Cython Keyword Color
  11. color green "\<(cdef|cimport|cpdef|cppclass|ctypedef|extern|include|namespace|property|struct)\>"
  12. color red "\<(bint|char|double|int|public|void|unsigned)\>"
  13. #Operator Color
  14. color yellow "[.:;,+*|=!\%]" "<" ">" "/" "-" "&"
  15. #Parenthetical Color
  16. color magenta "[(){}]" "\[" "\]"
  17. #String Color
  18. color cyan "['][^']*[^\\][']" "[']{3}.*[^\\][']{3}"
  19. color cyan "["][^"]*[^\\]["]" "["]{3}.*[^\\]["]{3}"
  20. color cyan start=""""[^"]" end=""""" start="'''[^']" end="'''"
  21. # Comment Color
  22. color brightblue "#.*$"