mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-08-07 12:28:24 +00:00
Fix a bug in FileCheck that wouldn't let define variables as follows:
; CHECK: [[VAR:[a-z]]] The problem was that to find the end of the regex var definition, it was simplistically looking for the next ]] and finding the incorrect one. A better approach is to count nesting of brackets (taking escaping into account). This way the brackets that are part of the regex can be discovered and skipped properly, and the ]] ending is detected in the right place. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@169109 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
7
test/FileCheck/regex-brackets.txt
Normal file
7
test/FileCheck/regex-brackets.txt
Normal file
@@ -0,0 +1,7 @@
|
||||
// RUN: FileCheck -input-file %s %s
|
||||
|
||||
op r1
|
||||
op r2, [x r1]
|
||||
; CHECK: op [[REG:r[0-9]]]
|
||||
; CHECK: op [[REG2:r[0-9]]], [x [[REG]]]
|
||||
|
Reference in New Issue
Block a user