X-Git-Url: https://git.lyx.org/gitweb/?a=blobdiff_plain;f=src%2Ffrontends%2Ftests%2Fbiblio.cpp;h=9fa7c237df84a76ef3732119b950ff05c17d3d0e;hb=a171c651a6802380aad7d7e24ed1a95ffa814de6;hp=3696598a3f4c7c130560af2e25f8c5a25d1fb124;hpb=f3ec89cfa15feae8aa3185413eda55f28cc6551e;p=lyx.git diff --git a/src/frontends/tests/biblio.cpp b/src/frontends/tests/biblio.cpp index 3696598a3f..9fa7c237df 100644 --- a/src/frontends/tests/biblio.cpp +++ b/src/frontends/tests/biblio.cpp @@ -2,8 +2,7 @@ #include #include - -#include "support/regex.h" +#include using namespace std; @@ -16,13 +15,13 @@ string const escape_special_chars(string const & expr) { // Search for all chars '.|*?+(){}[^$]\' // Note that '[', ']', and '\' must be escaped. - lyx::regex reg("[.|*?+(){}^$\\[\\]\\\\]"); + regex reg("[.|*?+(){}^$\\[\\]\\\\]"); // $& is a ECMAScript format expression that expands to all // of the current match // To prefix a matched expression with a single literal backslash, we // need to escape it for the C++ compiler and use: - return lyx::regex_replace(expr, reg, "\\$&"); + return regex_replace(expr, reg, "\\$&"); } @@ -49,11 +48,11 @@ public: // Attempts to find a match for the current RE // somewhere in data. - return lyx::regex_search(data, regex_); + return regex_search(data, regex_); } private: InfoMap const map_; - mutable lyx::regex regex_; + mutable regex regex_; }; @@ -77,7 +76,7 @@ void test_RegexMatch() cout << rm("hello") << endl; cout << rm("hei") << endl; } - catch (lyx::regex_error & regerr) { + catch (regex_error & regerr) { cout << regerr.what() << endl; } }