Implement constant pointers, and null specifically in the parser, bytecode writer, and
bytecode reader.
llvm-svn: 668
diff --git a/llvm/lib/Bytecode/Writer/ConstantWriter.cpp b/llvm/lib/Bytecode/Writer/ConstantWriter.cpp
index 24ceaec..dde47d5 100644
--- a/llvm/lib/Bytecode/Writer/ConstantWriter.cpp
+++ b/llvm/lib/Bytecode/Writer/ConstantWriter.cpp
@@ -141,6 +141,11 @@
break;
}
+ case Type::PointerTyID: {
+ output_vbr((unsigned)0, Out);
+ break;
+ }
+
case Type::FloatTyID: { // Floating point types...
float Tmp = (float)((const ConstPoolFP*)CPV)->getValue();
output_data(&Tmp, &Tmp+1, Out);