aboutsummaryrefslogtreecommitdiffhomepage
path: root/lexers/LexErlang.cxx
diff options
context:
space:
mode:
authornyamatongwe <devnull@localhost>2010-07-13 21:44:00 +1000
committernyamatongwe <devnull@localhost>2010-07-13 21:44:00 +1000
commitf5e7b31bb9c60f85e91a0958ae2e7452a2792063 (patch)
treeb54aacc72daf0121e9c0e2b28583b2372a3b6aab /lexers/LexErlang.cxx
parent412fd42d7b9f10cb615e5e0ed01d1d9f51ae5f2d (diff)
downloadscintilla-mirror-f5e7b31bb9c60f85e91a0958ae2e7452a2792063.tar.gz
For new lexer design change includes to add new files and remove unused files.
Normalise order of includes. Minor fixes for compatibility with new lexer design.
Diffstat (limited to 'lexers/LexErlang.cxx')
-rw-r--r--lexers/LexErlang.cxx27
1 files changed, 16 insertions, 11 deletions
diff --git a/lexers/LexErlang.cxx b/lexers/LexErlang.cxx
index 45577bda4..00f18b56b 100644
--- a/lexers/LexErlang.cxx
+++ b/lexers/LexErlang.cxx
@@ -4,24 +4,29 @@
/** @file LexErlang.cxx
** Lexer for Erlang.
** Enhanced by Etienne 'Lenain' Girondel (lenaing@gmail.com)
- ** Originally wrote by Peter-Henry Mander,
+ ** Originally wrote by Peter-Henry Mander,
** based on Matlab lexer by José Fonseca.
**/
#include <stdlib.h>
#include <string.h>
-#include <ctype.h>
#include <stdio.h>
#include <stdarg.h>
+#include <assert.h>
+#include <ctype.h>
-#include "Platform.h"
-#include "PropSet.h"
-#include "Accessor.h"
-#include "StyleContext.h"
-#include "KeyWords.h"
+#include "ILexer.h"
#include "Scintilla.h"
#include "SciLexer.h"
+#include "PropSetSimple.h"
+#include "WordList.h"
+#include "LexAccessor.h"
+#include "Accessor.h"
+#include "StyleContext.h"
+#include "CharacterSet.h"
+#include "LexerModule.h"
+
#ifdef SCI_NAMESPACE
using namespace Scintilla;
#endif
@@ -152,7 +157,7 @@ static void ColouriseErlangDoc(unsigned int startPos, int length, int initStyle,
// Try to match documentation comment
sc.GetCurrent(cur, sizeof(cur));
- if (parse_state == COMMENT_DOC_MACRO
+ if (parse_state == COMMENT_DOC_MACRO
&& erlangDocMacro.InList(cur)) {
sc.ChangeState(SCE_ERLANG_COMMENT_DOC_MACRO);
while (sc.ch != '}' && !sc.atLineEnd)
@@ -340,7 +345,7 @@ static void ColouriseErlangDoc(unsigned int startPos, int length, int initStyle,
case NUMERAL_BASE_VALUE : {
if (!is_radix(radix_digits,sc.ch)) {
radix_digits = 0;
-
+
if (!isalnum(sc.ch))
sc.ChangeState(SCE_ERLANG_NUMBER);
@@ -380,7 +385,7 @@ static void ColouriseErlangDoc(unsigned int startPos, int length, int initStyle,
/* Preprocessor --------------------------------------------------*/
case PREPROCESSOR : {
if (!IsAWordChar(sc.ch)) {
-
+
sc.GetCurrent(cur, sizeof(cur));
if (erlangPreproc.InList(cur)) {
style = SCE_ERLANG_PREPROC;
@@ -421,7 +426,7 @@ static void ColouriseErlangDoc(unsigned int startPos, int length, int initStyle,
} break;
case SCE_ERLANG_OPERATOR : {
if (sc.chPrev == '.') {
- if (sc.ch == '*' || sc.ch == '/' || sc.ch == '\\'
+ if (sc.ch == '*' || sc.ch == '/' || sc.ch == '\\'
|| sc.ch == '^') {
sc.ForwardSetState(SCE_ERLANG_DEFAULT);
} else if (sc.ch == '\'') {