From 14f29d96821ecb40e2aca177576989ffa8be82d8 Mon Sep 17 00:00:00 2001 From: "Johnny C. Lam" Date: Sat, 19 Oct 2013 07:52:46 +0000 Subject: [PATCH] Fix ticket 301 - Allow Define() to take decimal values. Extend Define() to allow for non-alphanumeric values. Also allow for "_", ".", and "=" in the value. Spaces are still prohibited. git-svn-id: svn://svn.curseforge.net/wow/ovale/mainline/trunk@1065 d5049fe3-3747-40f7-a4b5-f36d6801af5f --- OvaleCompile.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/OvaleCompile.lua b/OvaleCompile.lua index 1b47032..04fdd9a 100644 --- a/OvaleCompile.lua +++ b/OvaleCompile.lua @@ -664,7 +664,7 @@ end -- Compile non-function and non-icon declarations. local function CompileDeclarations(text) -- Define(CONSTANTE valeur) - text = strgsub(text, "Define%s*%(%s*([%w_]+)%s+(%w+)%s*%)", ParseDefine) + text = strgsub(text, "Define%s*%(%s*([%w_]+)%s+([%w_.=]+)%s*%)", ParseDefine) -- On remplace les constantes par leur valeur text = strgsub(text, "([%w_]+)", ReplaceDefine) -- 1.7.9.5