diff options
author | toma <toma@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2009-11-25 17:56:58 +0000 |
---|---|---|
committer | toma <toma@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2009-11-25 17:56:58 +0000 |
commit | ce4a32fe52ef09d8f5ff1dd22c001110902b60a2 (patch) | |
tree | 5ac38a06f3dde268dc7927dc155896926aaf7012 /kate/tests/highlight_lpc.c | |
download | tdelibs-ce4a32fe52ef09d8f5ff1dd22c001110902b60a2.tar.gz tdelibs-ce4a32fe52ef09d8f5ff1dd22c001110902b60a2.zip |
Copy the KDE 3.5 branch to branches/trinity for new KDE 3.5 features.
BUG:215923
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdelibs@1054174 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kate/tests/highlight_lpc.c')
-rw-r--r-- | kate/tests/highlight_lpc.c | 64 |
1 files changed, 64 insertions, 0 deletions
diff --git a/kate/tests/highlight_lpc.c b/kate/tests/highlight_lpc.c new file mode 100644 index 000000000..fe5c62979 --- /dev/null +++ b/kate/tests/highlight_lpc.c @@ -0,0 +1,64 @@ +// NOTE: This is a test file for kate's LPC syntax highlighting. + +// This is a Single-Line Comment +/* This is a Multi- + Line Comment */ + +// This again is a Single-Line Comment which should end here /* + +// And this is an evil single line comment \ + which should include this and the next line because of the \ + Do not use this style at home, kids. +// BEGIN region marker + +// END of region marker + +private void create() +{ +// Some Preprocessor stuff: +#define SOME_STUFF if(foo("bar")) \ + { \ + bar("foo"); \ + } // Preprocessor, Keyword, Preprocessor-String, Multiline + + // Some closures: + #'create; + #'?!; + + + /* Some other Data Types: */ + + int i = 1; // Integer. + float b = 2.34; // Float. + int c = 0b001; // Binary + int e = 0x019Beef; // Hexadecimal + int f = 0o2345; // Octal + string a = "Wheee"; // String + string x = "Wheee\ + heee"; // Multi-Line String, again, don't use this. + + + + /* Some keywords: */ + if(1) + { + switch(2) + { + case 3: + 4; + break; + } + } + + else + { + return 0; + } +} + +/* +WARNING: If the above function is part of a multi-line comment, + it's buggy. The WARNING: itself should be a comment-keyword. + That's not actually part of the language, but simply used + to highlight important stuff inside comments like TODO: etc. +*/ |