MC: Constify MCAsmLayout argument to MCExpr::EvaluteAs...

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@98380 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/lib/MC/MCExpr.cpp b/lib/MC/MCExpr.cpp
index 0ca2ad8..8d84f53 100644
--- a/lib/MC/MCExpr.cpp
+++ b/lib/MC/MCExpr.cpp
@@ -145,7 +145,7 @@
 
 /* *** */
 
-bool MCExpr::EvaluateAsAbsolute(int64_t &Res, MCAsmLayout *Layout) const {
+bool MCExpr::EvaluateAsAbsolute(int64_t &Res, const MCAsmLayout *Layout) const {
   MCValue Value;
   
   if (!EvaluateAsRelocatable(Value, Layout) || !Value.isAbsolute())
@@ -177,7 +177,8 @@
   return true;
 }
 
-bool MCExpr::EvaluateAsRelocatable(MCValue &Res, MCAsmLayout *Layout) const {
+bool MCExpr::EvaluateAsRelocatable(MCValue &Res,
+                                   const MCAsmLayout *Layout) const {
   switch (getKind()) {
   case Target:
     return cast<MCTargetExpr>(this)->EvaluateAsRelocatableImpl(Res, Layout);
diff --git a/lib/Target/X86/X86MCTargetExpr.cpp b/lib/Target/X86/X86MCTargetExpr.cpp
index de56d31..cfcf702 100644
--- a/lib/Target/X86/X86MCTargetExpr.cpp
+++ b/lib/Target/X86/X86MCTargetExpr.cpp
@@ -37,7 +37,7 @@
 }
 
 bool X86MCTargetExpr::EvaluateAsRelocatableImpl(MCValue &Res,
-                                                MCAsmLayout *Layout) const {
+                                              const MCAsmLayout *Layout) const {
   // FIXME: I don't know if this is right, it followed MCSymbolRefExpr.
   
   // Evaluate recursively if this is a variable.
diff --git a/lib/Target/X86/X86MCTargetExpr.h b/lib/Target/X86/X86MCTargetExpr.h
index 56011eb..a82e142 100644
--- a/lib/Target/X86/X86MCTargetExpr.h
+++ b/lib/Target/X86/X86MCTargetExpr.h
@@ -41,7 +41,7 @@
                                  MCContext &Ctx);
   
   void PrintImpl(raw_ostream &OS) const;
-  bool EvaluateAsRelocatableImpl(MCValue &Res, MCAsmLayout *Layout) const;
+  bool EvaluateAsRelocatableImpl(MCValue &Res, const MCAsmLayout *Layout) const;
 };
   
 } // end namespace llvm