summaryrefslogtreecommitdiff
path: root/context/data/textadept/context/lexers/scite-context-lexer-cpp-web.lua
blob: 631a802febec2d8969bcd2c8fd560a250f6886ba (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
local info = {
    version   = 1.002,
    comment   = "scintilla lpeg lexer for cpp web",
    author    = "Hans Hagen, PRAGMA-ADE, Hasselt NL",
    copyright = "PRAGMA ADE / ConTeXt Development Team",
    license   = "see context related readme files",
}

local lexer       = require("scite-context-lexer")
local context     = lexer.context
local patterns    = context.patterns

local cppweblexer = lexer.new("cpp-web","scite-context-lexer-cpp")
local cpplexer    = lexer.load("scite-context-lexer-cpp")

-- can probably be done nicer now, a bit of a hack

cppweblexer._rules       = cpplexer._rules_web
cppweblexer._tokenstyles = cpplexer._tokenstyles
cppweblexer._foldsymbols = cpplexer._foldsymbols
cppweblexer._directives  = cpplexer._directives

return cppweblexer