Commits

Tim Hatch committed 476d6b2

Go allows unicode for identifiers.

Resolves #983

Comments (0)

Files changed (1)

pygments/lexers/compiled.py

     aliases = ['go']
     mimetypes = ['text/x-gosrc']
 
+    flags = re.MULTILINE | re.UNICODE
+
     tokens = {
         'root': [
             (r'\n', Text),
              r'|<-|\+\+|--|==|!=|:=|\.\.\.|[+\-*/%&])', Operator),
             (r'[|^<>=!()\[\]{}.,;:]', Punctuation),
             # identifier
-            (r'[a-zA-Z_]\w*', Name.Other),
+            (r'[^\W\d]\w*', Name.Other),
         ]
     }