Disallow std::regex since it's not supported by GCC 4.8.x (#3870)

This commit is contained in:
Philip Hyunsu Cho 2018-11-05 22:57:04 -08:00 committed by GitHub
parent f1275f52c1
commit 20d5abf919
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -26,6 +26,12 @@ if [ ${TASK} == "lint" ]; then
# Fail only on warnings related to XGBoost source files
(cat logtidy.txt|grep -E 'xgboost.*warning'|grep -v dmlc-core) && exit -1
echo "----------------------------"
if grep -R '<regex>' src include tests/cpp plugin jvm-packages amalgamation; then
echo 'Do not use std::regex, since it is not supported by GCC 4.8.x'
exit -1
fi
exit 0
fi