From dcdfd740f31c552749bfd2851f23a3aad0ea224a Mon Sep 17 00:00:00 2001 From: pantor Date: Sun, 26 Nov 2017 19:38:47 +0100 Subject: [PATCH] fix parser bug 3 --- src/inja.hpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/inja.hpp b/src/inja.hpp index 3c8302f..b1e1a48 100644 --- a/src/inja.hpp +++ b/src/inja.hpp @@ -509,7 +509,7 @@ public: {Parsed::Function::DivisibleBy, Regex{"divisibleBy\\(\\s*(.*)\\s*,\\s*(.*)\\s*\\)"}}, {Parsed::Function::Odd, Regex{"odd\\(\\s*(.*)\\s*\\)"}}, {Parsed::Function::Even, Regex{"even\\(\\s*(.*)\\s*\\)"}}, - {Parsed::Function::ReadJson, Regex{"\\s*([^()]*?)\\s*"}} + {Parsed::Function::ReadJson, Regex{"\\s*([^\\(\\)]*?)\\s*"}} }; Parser() { } @@ -589,7 +589,7 @@ public: return result; } default: { - throw std::runtime_error("Parser error: Could not parse input: " + input); + throw std::runtime_error("Parser error: Could not parse expression: " + input); } } }