//===--- StmtViz.cpp - Graphviz visualization for Stmt ASTs -----*- C++ -*-===// // // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. // See https://llvm.org/LICENSE.txt for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // //===----------------------------------------------------------------------===// // // This file implements Stmt::viewAST, which generates a Graphviz DOT file // that depicts the AST and then calls Graphviz/dot+gv on it. // //===----------------------------------------------------------------------===// #include "clang/AST/StmtGraphTraits.h" #include "clang/AST/Decl.h" #include "llvm/Support/GraphWriter.h" usingnamespaceclang; void Stmt::viewAST() const { … } namespace llvm { template<> struct DOTGraphTraits<const Stmt*> : public DefaultDOTGraphTraits { … }; } // end namespace llvm