aboutsummaryrefslogtreecommitdiffhomepage
path: root/lexlua/glsl.lua
diff options
context:
space:
mode:
Diffstat (limited to 'lexlua/glsl.lua')
-rw-r--r--lexlua/glsl.lua24
1 files changed, 9 insertions, 15 deletions
diff --git a/lexlua/glsl.lua b/lexlua/glsl.lua
index 31440f0a6..d6bef2b44 100644
--- a/lexlua/glsl.lua
+++ b/lexlua/glsl.lua
@@ -19,21 +19,15 @@ lex:modify_rule('keyword', token(lexer.KEYWORD, word_match[[
]]) + lex:get_rule('keyword'))
-- Types.
-lex:modify_rule('type',
- token(lexer.TYPE,
- S('bdiu')^-1 * 'vec' * R('24') +
- P('d')^-1 * 'mat' * R('24') * ('x' * R('24')^-1) +
- S('iu')^-1 * 'sampler' * R('13') * 'D' +
- 'sampler' * R('12') * 'D' * P('Array')^-1 * 'Shadow' +
- S('iu')^-1 * 'sampler' * (R('12') * 'DArray' +
- word_match[[
- Cube 2DRect Buffer 2DMS 2DMSArray 2DMSCubeArray
- ]]) +
- word_match[[
- samplerCubeShadow sampler2DRectShadow
- samplerCubeArrayShadow
- ]]) +
- lex:get_rule('type') +
+lex:modify_rule('type', token(lexer.TYPE, S('bdiu')^-1 * 'vec' * R('24') +
+ P('d')^-1 * 'mat' * R('24') * ('x' * R('24')^-1) +
+ S('iu')^-1 * 'sampler' * R('13') * 'D' +
+ 'sampler' * R('12') * 'D' * P('Array')^-1 * 'Shadow' +
+ S('iu')^-1 * 'sampler' * (R('12') * 'DArray' + word_match[[
+ Cube 2DRect Buffer 2DMS 2DMSArray 2DMSCubeArray
+ ]]) +
+ word_match[[samplerCubeShadow sampler2DRectShadow samplerCubeArrayShadow]]) +
+ lex:get_rule('type') +
-- Functions.
token(lexer.FUNCTION, word_match[[