1 //===- PDBSymbolCompiland.cpp - compiland details --------*- C++ -*-===//
3 // The LLVM Compiler Infrastructure
5 // This file is distributed under the University of Illinois Open Source
6 // License. See LICENSE.TXT for details.
8 //===----------------------------------------------------------------------===//
10 #include "llvm/DebugInfo/PDB/PDBSymbolCompiland.h"
11 #include "llvm/DebugInfo/PDB/PDBSymbolCompilandEnv.h"
13 #include "llvm/DebugInfo/PDB/PDBSymDumper.h"
18 using namespace llvm::pdb;
20 PDBSymbolCompiland::PDBSymbolCompiland(const IPDBSession &PDBSession,
21 std::unique_ptr<IPDBRawSymbol> Symbol)
22 : PDBSymbol(PDBSession, std::move(Symbol)) {}
24 void PDBSymbolCompiland::dump(PDBSymDumper &Dumper) const {
28 std::string PDBSymbolCompiland::getSourceFileName() const
30 std::string Result = RawSymbol->getSourceFileName();
33 auto Envs = findAllChildren<PDBSymbolCompilandEnv>();
36 while (auto Env = Envs->getNext()) {
37 std::string Var = Env->getName();
40 std::string Value = Env->getValue();