Inline a trivial function. NFC.
authorRui Ueyama <ruiu@google.com>
Wed, 28 Feb 2018 18:25:00 +0000 (18:25 +0000)
committerRui Ueyama <ruiu@google.com>
Wed, 28 Feb 2018 18:25:00 +0000 (18:25 +0000)
llvm-svn: 326347

lld/ELF/ScriptParser.cpp

index 8740f6ad5fcfd92360cb0a58a11e733bd31ee27c..0c4e523ebc87553cb8954bc4c1cb7542cfbb7350 100644 (file)
@@ -157,10 +157,6 @@ static ExprValue sub(ExprValue A, ExprValue B) {
   return {A.Sec, false, A.getSectionOffset() - B.getValue(), A.Loc};
 }
 
-static ExprValue mul(ExprValue A, ExprValue B) {
-  return A.getValue() * B.getValue();
-}
-
 static ExprValue div(ExprValue A, ExprValue B) {
   if (uint64_t BV = B.getValue())
     return A.getValue() / BV;
@@ -808,7 +804,7 @@ static Expr combine(StringRef Op, Expr L, Expr R) {
   if (Op == "-")
     return [=] { return sub(L(), R()); };
   if (Op == "*")
-    return [=] { return mul(L(), R()); };
+    return [=] { return L().getValue() * R().getValue(); };
   if (Op == "/")
     return [=] { return div(L(), R()); };
   if (Op == "<<")