[llvm-commits] CVS: llvm/include/llvm/CodeGen/ELFWriter.h

Chris Lattner lattner at cs.uiuc.edu
Sun Jul 10 23:16:36 PDT 2005



Changes in directory llvm/include/llvm/CodeGen:

ELFWriter.h updated: 1.4 -> 1.5
---
Log message:

The symbol table just needs a const GlobalValue*, not a non-const one.


---
Diffs of the changes:  (+4 -5)

 ELFWriter.h |    9 ++++-----
 1 files changed, 4 insertions(+), 5 deletions(-)


Index: llvm/include/llvm/CodeGen/ELFWriter.h
diff -u llvm/include/llvm/CodeGen/ELFWriter.h:1.4 llvm/include/llvm/CodeGen/ELFWriter.h:1.5
--- llvm/include/llvm/CodeGen/ELFWriter.h:1.4	Mon Jul 11 00:15:32 2005
+++ llvm/include/llvm/CodeGen/ELFWriter.h	Mon Jul 11 01:16:24 2005
@@ -127,9 +127,8 @@
     /// added to logical symbol table for the module.  This is eventually
     /// turned into a real symbol table in the file.
     struct ELFSym {
-      GlobalValue *GV;        // The global value this corresponds to.
-      //std::string Name;       // Name of the symbol.
-      unsigned NameIdx;       // Index in .strtab of name, once emitted.
+      const GlobalValue *GV;    // The global value this corresponds to.
+      unsigned NameIdx;         // Index in .strtab of name, once emitted.
       uint64_t Value;
       unsigned Size;
       unsigned char Info;
@@ -139,8 +138,8 @@
       enum { STB_LOCAL = 0, STB_GLOBAL = 1, STB_WEAK = 2 };
       enum { STT_NOTYPE = 0, STT_OBJECT = 1, STT_FUNC = 2, STT_SECTION = 3,
              STT_FILE = 4 };
-      ELFSym(GlobalValue *gv) : GV(gv), Value(0), Size(0), Info(0),
-                                Other(0), SectionIdx(0) {}
+      ELFSym(const GlobalValue *gv) : GV(gv), Value(0), Size(0), Info(0),
+                                      Other(0), SectionIdx(0) {}
 
       void SetBind(unsigned X) {
         assert(X == (X & 0xF) && "Bind value out of range!");






More information about the llvm-commits mailing list