[Kaleidoscope] Fix symbol resolver to search in reverse order.

This should allow more recent definitions of functions in the Kaleidoscope REPL
to override old ones, as the tutorial text promises.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@354598 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/examples/Kaleidoscope/include/KaleidoscopeJIT.h b/examples/Kaleidoscope/include/KaleidoscopeJIT.h
index a2b0fee..162dcfe 100644
--- a/examples/Kaleidoscope/include/KaleidoscopeJIT.h
+++ b/examples/Kaleidoscope/include/KaleidoscopeJIT.h
@@ -46,7 +46,7 @@
       : Resolver(createLegacyLookupResolver(
             ES,
             [this](const std::string &Name) {
-              return ObjectLayer.findSymbol(Name, true);
+              return findMangledSymbol(Name);
             },
             [](Error Err) { cantFail(std::move(Err), "lookupFlags failed"); })),
         TM(EngineBuilder().selectTarget()), DL(TM->createDataLayout()),