aboutsummaryrefslogtreecommitdiff
path: root/lua/lexers/pony.lua
diff options
context:
space:
mode:
Diffstat (limited to 'lua/lexers/pony.lua')
-rw-r--r--lua/lexers/pony.lua4
1 files changed, 3 insertions, 1 deletions
diff --git a/lua/lexers/pony.lua b/lua/lexers/pony.lua
index 618a9bf..5cb07a1 100644
--- a/lua/lexers/pony.lua
+++ b/lua/lexers/pony.lua
@@ -19,8 +19,10 @@ local annotation = token(l.PREPROCESSOR, l.delimited_range('\\', false, true))
local lit_bool = token(l.CONSTANT, pword{'true', 'false'})
+local nq = l.any - P'"'
local lit_str = token(l.STRING,
- l.delimited_range('"') -- this covers triple quoted strings
+ P'"""' * (nq + (P'"' * #(nq + (P'"' * nq))))^0 * P'"""'
+ + l.delimited_range('"')
+ l.delimited_range("'")
)