From 8186eff3df91c5600784ed76cde053ca65eefd3e Mon Sep 17 00:00:00 2001 From: Simon Date: Mon, 3 Dec 2018 09:58:17 +0000 Subject: [PATCH] Add comment in code to explain why we exclude REGEX for old GCC versions --- REGEX.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/REGEX.cpp b/REGEX.cpp index 498938a..b10168f 100644 --- a/REGEX.cpp +++ b/REGEX.cpp @@ -32,6 +32,11 @@ m_regex() } bool CREGEX::load() +/* Older versions of GCC appear to support REGEX but silently fail to match. Even + * though the headers exist and the code compiles and runs cleanly. The below #if block + * stops the REGEXs being loaded in these cases, effectively disabling REGEX functionality. + * The loading code is replaced with a log entry to show the user this has happened. +*/ { #if defined(__GNUC__) && (__GNUC__ <= 4) || (__GNUC__ == 4 && __GNUC_MINOR__ <= 9) LogError("REGEX is not properly supported in GCC vesions below 4.9. Not loading REGEX");