aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/Support/MemoryBuffer.cpp
diff options
context:
space:
mode:
authorJonas Devlieghere <jonas@devlieghere.com>2020-09-15 09:36:28 -0700
committerJonas Devlieghere <jonas@devlieghere.com>2020-09-15 09:40:17 -0700
commit127faae7529aee7e8508abebbc19212ce30bbf27 (patch)
treeba439ffff10ab93c7d08df1eccf37d6e348ed1d0 /llvm/lib/Support/MemoryBuffer.cpp
parenta43e68b58b085797e2f1435765255ebd431db297 (diff)
downloadllvm-127faae7529aee7e8508abebbc19212ce30bbf27.zip
llvm-127faae7529aee7e8508abebbc19212ce30bbf27.tar.gz
llvm-127faae7529aee7e8508abebbc19212ce30bbf27.tar.bz2
[lldb] Add -l/--language option to script command
Make it possible to run the script command with a different language than currently selected. $ ./bin/lldb -l python (lldb) script -l lua >>> io.stdout:write("Hello, World!\n") Hello, World! When passing the language option and a raw command, you need to separate the flag from the script code with --. $ ./bin/lldb -l python (lldb) script -l lua -- io.stdout:write("Hello, World!\n") Hello, World! Differential revision: https://reviews.llvm.org/D86996
Diffstat (limited to 'llvm/lib/Support/MemoryBuffer.cpp')
-rw-r--r--llvm/lib/Support/MemoryBuffer.cpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/llvm/lib/Support/MemoryBuffer.cpp b/llvm/lib/Support/MemoryBuffer.cpp
index 248fb72..e31c8e6 100644
--- a/llvm/lib/Support/MemoryBuffer.cpp
+++ b/llvm/lib/Support/MemoryBuffer.cpp
@@ -457,8 +457,7 @@ getOpenFileImpl(sys::fs::file_t FD, const Twine &Filename, uint64_t FileSize,
MapSize = FileSize;
}
- if (shouldUseMmap(FD, FileSize, MapSize, Offset, RequiresNullTerminator,
- PageSize, IsVolatile)) {
+ if (false) {
std::error_code EC;
std::unique_ptr<MB> Result(
new (NamedBufferAlloc(Filename)) MemoryBufferMMapFile<MB>(