[all-commits] [llvm/llvm-project] 78530c: Add indented raw_ostream class
Jacques Pienaar via All-commits
all-commits at lists.llvm.org
Sat Oct 3 08:54:08 PDT 2020
Branch: refs/heads/master
Home: https://github.com/llvm/llvm-project
Commit: 78530ce65375fa02bc96019e5cc9d73db8adaca4
https://github.com/llvm/llvm-project/commit/78530ce65375fa02bc96019e5cc9d73db8adaca4
Author: Jacques Pienaar <jpienaar at google.com>
Date: 2020-10-03 (Sat, 03 Oct 2020)
Changed paths:
A mlir/include/mlir/Support/IndentedOstream.h
M mlir/lib/Support/CMakeLists.txt
A mlir/lib/Support/IndentedOstream.cpp
M mlir/tools/mlir-tblgen/CMakeLists.txt
M mlir/tools/mlir-tblgen/OpDocGen.cpp
M mlir/tools/mlir-tblgen/RewriterGen.cpp
A mlir/unittests/Support/CMakeLists.txt
A mlir/unittests/Support/IndentedOstreamTest.cpp
Log Message:
-----------
Add indented raw_ostream class
Class simplifies keeping track of the indentation while emitting. For every new line the current indentation is simply prefixed (if not at start of line, then it just emits as normal). Add a simple Region helper that makes it easy to have the C++ scope match the emitted scope.
Use this in op doc generator and rewrite generator.
Differential Revision: https://reviews.llvm.org/D84107
More information about the All-commits
mailing list