[PATCH] D44459: [UpdateTestChecks] Handle IR variables with a '-' in the name
Alexander Richardson via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed Mar 14 13:34:07 PDT 2018
This revision was automatically updated to reflect the committed changes.
Closed by commit rL327564: [UpdateTestChecks] Handle IR variables with a '-' in the name (authored by arichardson, committed by ).
Repository:
rL LLVM
https://reviews.llvm.org/D44459
Files:
llvm/trunk/utils/UpdateTestChecks/common.py
Index: llvm/trunk/utils/UpdateTestChecks/common.py
===================================================================
--- llvm/trunk/utils/UpdateTestChecks/common.py
+++ llvm/trunk/utils/UpdateTestChecks/common.py
@@ -106,13 +106,14 @@
# Match things that look at identifiers, but only if they are followed by
# spaces, commas, paren, or end of the string
-IR_VALUE_RE = re.compile(r'(\s+)%([\w\.]+?)([,\s\(\)]|\Z)')
+IR_VALUE_RE = re.compile(r'(\s+)%([\w\.\-]+?)([,\s\(\)]|\Z)')
# Create a FileCheck variable name based on an IR name.
def get_value_name(var):
if var.isdigit():
var = 'TMP' + var
var = var.replace('.', '_')
+ var = var.replace('-', '_')
return var.upper()
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D44459.138448.patch
Type: text/x-patch
Size: 702 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20180314/6219a97e/attachment.bin>
More information about the llvm-commits
mailing list