.cp is a common C++ source file extension.
.m, .M and .mm are Objective-C/Objective-C++ extensions.
All of these colorized very well by the C tokenizer and should be included
in the c_extensions array in tokenizer.c.
Here is the patch to tokenizer.c (also attached) to add these:
Index: tokenizer.c
===================================================================
--- tokenizer.c (revision 1176)
+++ tokenizer.c (working copy)
@@ -4,7 +4,7 @@
#include <string.h>
/* Some default file extensions */
-char *c_extensions[] = { ".c", ".C", ".cc", ".cpp", ".cxx", ".h", ".hpp"
};
+char *c_extensions[] = { ".c", ".C", ".cc", ".cpp", ".cxx", ".cp", ".h",
".hpp", ".m", ".M", ".mm" };
char *ada_extensions[] = { ".adb", ".ads", ".ada",".ADB", ".ADS", ".ADA"
};
extern int c_lex ( void );
Robert Rossi
CGDB
None
Public
|
Date: 2009-07-26 04:51 On Jul 21, 2009, at 18:36, Bob Rossi wrote: |
| Filename | Description | Download |
|---|---|---|
| tokenizer.c-patch | Add .cp .m .M and .mm extensions to c tokenizer | Download |
| lexer-patch.gz | Objective-C/C++ lexer patch | Download |
| Field | Old Value | Date | By |
|---|---|---|---|
| File Added | 336619: lexer-patch.gz | 2009-07-26 04:52 | mackyle |
| assigned_to | nobody | 2009-06-15 23:05 | mackyle |
| File Added | 331124: tokenizer.c-patch | 2009-06-15 23:04 | mackyle |
Copyright © 2009 Geeknet, Inc. All rights reserved. Terms of Use