summaryrefslogtreecommitdiff
path: root/include/llvm/Module.h
diff options
context:
space:
mode:
authorDan Gohman <gohman@apple.com>2007-06-26 00:38:49 +0000
committerDan Gohman <gohman@apple.com>2007-06-26 00:38:49 +0000
commitbc9d89e6a2d685de7db90013a37e1a60a4ef38de (patch)
tree1c8321a99c5a695be1b8836c7a41e504d2006062 /include/llvm/Module.h
parent837a600a90f77e010b2f7866fc7c3ba993fc9694 (diff)
downloadllvm-bc9d89e6a2d685de7db90013a37e1a60a4ef38de.tar.gz
llvm-bc9d89e6a2d685de7db90013a37e1a60a4ef38de.tar.bz2
llvm-bc9d89e6a2d685de7db90013a37e1a60a4ef38de.tar.xz
Add a convenince member function for appending strings to a module's
module-level asm string data. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37726 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/llvm/Module.h')
-rw-r--r--include/llvm/Module.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/include/llvm/Module.h b/include/llvm/Module.h
index 8cd35f25be..9bd02ec50f 100644
--- a/include/llvm/Module.h
+++ b/include/llvm/Module.h
@@ -174,6 +174,13 @@ public:
/// Set the module-scope inline assembly blocks.
void setModuleInlineAsm(const std::string &Asm) { GlobalScopeAsm = Asm; }
+ /// Append to the module-scope inline assembly blocks, automatically
+ /// appending a newline to the end.
+ void appendModuleInlineAsm(const std::string &Asm) {
+ GlobalScopeAsm += Asm;
+ GlobalScopeAsm += '\n';
+ }
+
/// @}
/// @name Function Accessors
/// @{