[PATCH] D136469: [llvm-lit][test] Fix regex to capture scientific notation
Joel E. Denny via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri Oct 21 12:15:26 PDT 2022
jdenny added inline comments.
================
Comment at: llvm/utils/lit/tests/test-output-micro.py:42
# CHECK-NEXT: "code": "PASS",
-# CHECK-NEXT: "elapsed": {{[0-9.]+}},
+# CHECK-NEXT: "elapsed": {{[+-]?([[:digit:]]+(.[[:digit:]]*)?|.[[:digit:]]+)([eE][+-]?[[:digit:]]+)?}},
# CHECK-NEXT: "metrics": {
----------------
If the goal is to be strict, then `.` needs to be escaped to make it literal.
However, is it important to be so strict here? What about something simple like `{{[-+0-9.eE]+}}`?
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D136469/new/
https://reviews.llvm.org/D136469
More information about the llvm-commits
mailing list