[PATCH] D22403: FileCheck Enhancement - pattern templates.

Elena Lepilkina via llvm-commits llvm-commits at lists.llvm.org
Wed Jul 20 00:08:58 PDT 2016


eklepilkina added a comment.

In https://reviews.llvm.org/D22403#488644, @aprantl wrote:

> Using CHECK-lines to define meta-variables without checking anything diverges from FileCheck's usual behavior.


Execuse me, but I didn't understand what do you mean.  FileCheck variables are defined in check strings too. And about "without checking": there is checking of earlier definition of this pattern. What do you want to check more?

> I would expect something more like CHECK-DEFINE-PATTERN


There is no problem to rename.

> or even passing the patterns to FileCheck on the command line instead.


There may be a lot of patterns. Do you mean passing file with patterns?

> The syntax of \#, #:, \= is different from what we usually have in FileCheck where we usually use double-brackets "[[" to escape. Why is it so different? Is this borrowed from some other language that users can be expected to have some familiarity with?


This syntax was based on simple regular expressions where \ is escaping character. Syntax is a difficult question. Do you suggest using something like #pattern_name, [[:variable_name]], [[=variable_value]]?
I don't know how users will be better so I would like to know more opinions.


https://reviews.llvm.org/D22403





More information about the llvm-commits mailing list