summaryrefslogtreecommitdiff
path: root/source/Interpreter/CommandHistory.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'source/Interpreter/CommandHistory.cpp')
-rw-r--r--source/Interpreter/CommandHistory.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/source/Interpreter/CommandHistory.cpp b/source/Interpreter/CommandHistory.cpp
index 0fa25ed806ff..ca5c90692b6a 100644
--- a/source/Interpreter/CommandHistory.cpp
+++ b/source/Interpreter/CommandHistory.cpp
@@ -47,13 +47,13 @@ CommandHistory::FindString(llvm::StringRef input_str) const {
size_t idx = 0;
if (input_str.front() == '-') {
- if (input_str.drop_front(2).getAsInteger(0, idx))
+ if (input_str.drop_front(1).getAsInteger(0, idx))
return llvm::None;
if (idx >= m_history.size())
return llvm::None;
idx = m_history.size() - idx;
} else {
- if (input_str.drop_front().getAsInteger(0, idx))
+ if (input_str.getAsInteger(0, idx))
return llvm::None;
if (idx >= m_history.size())
return llvm::None;