Skip to content

Instantly share code, notes, and snippets.

@thatch
Created March 22, 2011 06:48
Show Gist options
  • Save thatch/880867 to your computer and use it in GitHub Desktop.
Save thatch/880867 to your computer and use it in GitHub Desktop.
patch for 635 tb
diff -r 62c4935c6f63 pygments/lexers/asm.py
--- a/pygments/lexers/asm.py Sat Mar 19 20:00:07 2011 -0700
+++ b/pygments/lexers/asm.py Mon Mar 21 23:48:01 2011 -0700
@@ -88,7 +88,10 @@
}
def analyse_text(text):
- return re.match(r'^\.\w+', text, re.M)
+ if re.match(r'^\.(text|data|section)', text, re.M):
+ return True
+ elif re.match(r'^\.\w+', text, re.M):
+ return 0.1
class ObjdumpLexer(RegexLexer):
"""
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment