mclow.lists accepted this revision.
mclow.lists added a comment.
This revision is now accepted and ready to land.
Applied as revision 313056 (with minor editing)
https://reviews.llvm.org/D28224
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
timshen added a comment.
I defined and exported a macro _LIBCPP_REGEX_COMPLEXITY_FACTOR in the hope that
even when the library is shipped to the user, and when the user finds the
factor to be inappropriate, they can override it.
I'm not aware of and exported macro policy though, please advice.
timshen updated this revision to Diff 82840.
timshen added a comment.
Detect user defined _LIBCPP_REGEX_COMPLEXITY_FACTOR first.
https://reviews.llvm.org/D28224
Files:
libcxx/include/regex
libcxx/test/std/re/re.alg/re.alg.match/exponential.pass.cpp
libcxx/test/std/re/re.alg/re.alg.search/
timshen created this revision.
timshen added a reviewer: mclow.lists.
timshen added a subscriber: cfe-commits.
Herald added a reviewer: EricWF.
This prevents the backtracking regex engines from "hanging forever"
under certain input.
https://reviews.llvm.org/D28224
Files:
libcxx/include/regex