Mercurial > hg > CbC > CbC_llvm
comparison lib/DebugInfo/PDB/PDB.cpp @ 83:60c9769439b8 LLVM3.7
LLVM 3.7
author | Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp> |
---|---|
date | Wed, 18 Feb 2015 14:55:36 +0900 |
parents | |
children | afa8332a0e37 |
comparison
equal
deleted
inserted
replaced
78:af83660cff7b | 83:60c9769439b8 |
---|---|
1 //===- PDB.cpp - base header file for creating a PDB reader -----*- C++ -*-===// | |
2 // | |
3 // The LLVM Compiler Infrastructure | |
4 // | |
5 // This file is distributed under the University of Illinois Open Source | |
6 // License. See LICENSE.TXT for details. | |
7 // | |
8 //===----------------------------------------------------------------------===// | |
9 | |
10 #include "llvm/DebugInfo/PDB/PDB.h" | |
11 | |
12 #include "llvm/ADT/StringRef.h" | |
13 #include "llvm/Config/config.h" | |
14 #include "llvm/DebugInfo/PDB/IPDBSession.h" | |
15 #include "llvm/DebugInfo/PDB/PDB.h" | |
16 | |
17 #if HAVE_DIA_SDK | |
18 #include "llvm/DebugInfo/PDB/DIA/DIASession.h" | |
19 #endif | |
20 | |
21 using namespace llvm; | |
22 | |
23 std::unique_ptr<IPDBSession> llvm::createPDBReader(PDB_ReaderType Type, | |
24 StringRef Path) { | |
25 // Create the correct concrete instance type based on the value of Type. | |
26 #if HAVE_DIA_SDK | |
27 return std::unique_ptr<DIASession>(DIASession::createFromPdb(Path)); | |
28 #endif | |
29 return nullptr; | |
30 } |