new pattern, 0.1.2

This commit is contained in:
Alexander Zhirov 2023-03-25 15:37:46 +03:00
parent d7341373d4
commit 2010c7efde
1 changed files with 4 additions and 2 deletions

View File

@ -13,6 +13,10 @@ private:
string path;
PP[string] properties;
bool readed = false;
const string pattern = "^( |\\t)*(((\\w(\\w|-)+)(( |\\t)*(=>|=){1}"
~ "( |\\t)*)(?!\\/(\\/|\\*))(([^ >\"'=\\n\\t#;].*?)|(\"(.+)\")"
~ "|('(.+)')){1})|(\\[(\\w(\\w|-)+)\\])|(\\[()\\]))( |\\t)*"
~ "(( |\\t)(#|;|\\/\\/|\\/\\*).*)?$";
/**
* Parameter and its value with the ability to convert to the desired data type
@ -69,8 +73,6 @@ private:
return;
}
string pattern = "^ *(\\w+)(( +=> +)|( += +))(?!\\/\\/)(([^ >\"'\\n#;].*?)|"
~ "(\"(.+?)\")|('(.+?)')){1} *( #.*?)?( ;.*?)?( \\/\\/.*)?$";
auto regular = regex(pattern, "m");
while (!configuration.eof())