MLIR 22.0.0git
mlir::irdl::detail::Template Class Reference

Template Code as used by IRDL-to-Cpp. More...

#include "Target/IRDLToCpp/TemplatingUtils.h"

Public Member Functions

 Template (llvm::StringRef str)
void render (llvm::raw_ostream &out, const dictionary &replacements) const
 Render will apply a dictionary to the Template and send the rendered result to the specified output stream.

Detailed Description

Template Code as used by IRDL-to-Cpp.

For efficiency, produces a bytecode representation of an input template.

  • LiteralToken: A contiguous stream of characters to be printed
  • ReplacementToken: A template variable that will be replaced

Definition at line 31 of file TemplatingUtils.h.

Constructor & Destructor Documentation

◆ Template()

mlir::irdl::detail::Template::Template ( llvm::StringRef str)
inline

Definition at line 33 of file TemplatingUtils.h.

Member Function Documentation

◆ render()

void mlir::irdl::detail::Template::render ( llvm::raw_ostream & out,
const dictionary & replacements ) const
inline

Render will apply a dictionary to the Template and send the rendered result to the specified output stream.

Definition at line 53 of file TemplatingUtils.h.

References replacement().


The documentation for this class was generated from the following file: