[all-commits] [llvm/llvm-project] f2dc17: [mlir][ods] Fix StringRef initialization in builders
Lei Zhang via All-commits
all-commits at lists.llvm.org
Tue Jan 21 11:12:32 PST 2020
Branch: refs/heads/master
Home: https://github.com/llvm/llvm-project
Commit: f2dc179d686a77de8daa1b31c8984b39823e9a3d
https://github.com/llvm/llvm-project/commit/f2dc179d686a77de8daa1b31c8984b39823e9a3d
Author: Lei Zhang <antiagainst at google.com>
Date: 2020-01-21 (Tue, 21 Jan 2020)
Changed paths:
M mlir/include/mlir/TableGen/Attribute.h
M mlir/test/mlir-tblgen/op-attribute.td
M mlir/tools/mlir-tblgen/OpDefinitionsGen.cpp
Log Message:
-----------
[mlir][ods] Fix StringRef initialization in builders
For the generated builder taking in unwrapped attribute values,
if the argument is a string, we should avoid wrapping it in quotes;
otherwise we are always setting the string attribute to contain
the string argument's name. The quotes come from StrinAttr's
`constBuilderCall`, which is reasonable for string literals, but
not function arguments containing strings.
Differential Revision: https://reviews.llvm.org/D72977
More information about the All-commits
mailing list