[llvm] r183915 - Add a version of DisplayGraph that takes a StringRef.

Rafael Espindola rafael.espindola at gmail.com
Thu Jun 13 09:56:14 PDT 2013


Author: rafael
Date: Thu Jun 13 11:56:13 2013
New Revision: 183915

URL: http://llvm.org/viewvc/llvm-project?rev=183915&view=rev
Log:
Add a version of DisplayGraph that takes a StringRef.

Modified:
    llvm/trunk/include/llvm/Support/GraphWriter.h

Modified: llvm/trunk/include/llvm/Support/GraphWriter.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/Support/GraphWriter.h?rev=183915&r1=183914&r2=183915&view=diff
==============================================================================
--- llvm/trunk/include/llvm/Support/GraphWriter.h (original)
+++ llvm/trunk/include/llvm/Support/GraphWriter.h Thu Jun 13 11:56:13 2013
@@ -53,6 +53,12 @@ namespace GraphProgram {
 
 void DisplayGraph(const sys::Path& Filename, bool wait=true, GraphProgram::Name program = GraphProgram::DOT);
 
+inline void DisplayGraph(StringRef Filename, bool wait = true,
+                         GraphProgram::Name program = GraphProgram::DOT) {
+  sys::Path P(Filename);
+  DisplayGraph(P, wait, program);
+}
+
 template<typename GraphType>
 class GraphWriter {
   raw_ostream &O;





More information about the llvm-commits mailing list