blob: 76dc67956a2904c0e48f92d405ab8cf52263d7f3 [file] [log] [blame]
RUN: printf "%%s\n" "\"" | FileCheck %s --check-prefix=CHECK1
RUN: printf "%%s\n" '"' | FileCheck %s --check-prefix=CHECK1
RUN: printf "%%s\n" 'a[b\c' | FileCheck %s --check-prefix=CHECK2
RUN: printf "%%s\n" "a[b\\c" | FileCheck %s --check-prefix=CHECK2
RUN: printf "%%s\n" 'a\b\\c\\\\d' | FileCheck %s --check-prefix=CHECK3
RUN: printf "%%s\n" "a\\b\\\\c\\\\\\\\d" | FileCheck %s --check-prefix=CHECK3
CHECK1: {{^"$}}
CHECK2: {{^a\[b\\c$}}
CHECK3: {{^a\\b\\\\c\\\\\\\\d$}}
On Windows, with MSYS based tools, the following commands fail though:
RUNX: printf "%%s\n" 'a[b\c\\d' | FileCheck %s --check-prefix=CHECK4
RUNX: printf "%%s\n" "a[b\\c\\\\d" | FileCheck %s --check-prefix=CHECK4
CHECK4: {{^a\[b\\c\\\\d$}}