[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Adding keywords to cc-mode
From: |
Le Wang |
Subject: |
Adding keywords to cc-mode |
Date: |
23 Jun 2006 20:22:38 -0700 |
User-agent: |
G2/0.2 |
Hi,
I'd like to get the following to indent properly somehow.
for each (i in collection) {
// do stuff
};
The "for each" syntax is valid in c++/cli. I'm hopefully lost after
looking at cc-*.el and the various modes based on it, csharp-mode, etc.
I've tried adding this to my mode:
(c-lang-defconst c-block-stmt-2-kwds
c++cli '("for" "if" "switch" "while" "catch" "for each"
"checked" "unchecked" "lock"))
This gets the font-locking right, but everything after "{" is still
doubly indented. Can someone point me to some resources?
Thanks.
--
Le
- Adding keywords to cc-mode,
Le Wang <=