X-Git-Url: http://demsky.eecs.uci.edu/git/?a=blobdiff_plain;f=include%2Fllvm%2FAsmParser%2FParser.h;h=c362a1774399f98d2a7f84b1dfd5f82f33701b5e;hb=b12ab608fe80d5597090063ee3d72377d7560914;hp=ab440cc47c77118d415d3583fb2d1352c3561660;hpb=97eadf21c8ec4dd5e1e669edb3b454231bd4d27a;p=oota-llvm.git diff --git a/include/llvm/AsmParser/Parser.h b/include/llvm/AsmParser/Parser.h index ab440cc47c7..c362a177439 100644 --- a/include/llvm/AsmParser/Parser.h +++ b/include/llvm/AsmParser/Parser.h @@ -50,8 +50,7 @@ std::unique_ptr parseAssemblyString(StringRef AsmString, SMDiagnostic &Error, LLVMContext &Context); -/// This function is the low-level interface to the LLVM Assembly Parser. -/// ParseAssemblyFile and ParseAssemblyString are wrappers around this function. +/// parseAssemblyFile and parseAssemblyString are wrappers around this function. /// @brief Parse LLVM Assembly from a MemoryBuffer. /// @param F The MemoryBuffer containing assembly /// @param Err Error result info. @@ -59,6 +58,18 @@ std::unique_ptr parseAssemblyString(StringRef AsmString, std::unique_ptr parseAssembly(std::unique_ptr F, SMDiagnostic &Err, LLVMContext &Context); +/// This function is the low-level interface to the LLVM Assembly Parser. +/// This is kept as an independent function instead of being inlined into +/// parseAssembly for the convenience of interactive users that want to add +/// recently parsed bits to an existing module. +/// +/// @param F The MemoryBuffer containing assembly +/// @param M The module to add data to. +/// @param Err Error result info. +/// @return true on error. +bool parseAssemblyInto(std::unique_ptr F, Module &M, + SMDiagnostic &Err); + } // End llvm namespace #endif