summaryrefslogtreecommitdiff
path: root/llama.cpp
diff options
context:
space:
mode:
authorCebtenzzre <cebtenzzre@gmail.com>2023-09-01 09:34:50 -0400
committerGitHub <noreply@github.com>2023-09-01 16:34:50 +0300
commitef156499721c67748cde01a5436cb6f0648bb4b4 (patch)
treef979837d94e3deab68d38b08ce70441123c888c8 /llama.cpp
parentd8d6977f48f1fa402ade38ad32c5b5fb1358d059 (diff)
build : fix most gcc and clang warnings (#2861)
* fix most gcc and clang warnings * baby-llama : remove commented opt_params_adam * fix some MinGW warnings * fix more MinGW warnings
Diffstat (limited to 'llama.cpp')
-rw-r--r--llama.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/llama.cpp b/llama.cpp
index 98a5da96..5ca11923 100644
--- a/llama.cpp
+++ b/llama.cpp
@@ -3600,7 +3600,7 @@ static void llama_grammar_advance_stack(
std::vector<std::vector<const llama_grammar_element *>> & new_stacks) {
if (stack.empty()) {
- new_stacks.push_back(stack);
+ new_stacks.emplace_back(stack);
return;
}
@@ -3637,7 +3637,7 @@ static void llama_grammar_advance_stack(
}
case LLAMA_GRETYPE_CHAR:
case LLAMA_GRETYPE_CHAR_NOT:
- new_stacks.push_back(stack);
+ new_stacks.emplace_back(stack);
break;
default:
// end of alternate (LLAMA_GRETYPE_END, LLAMA_GRETYPE_ALT) or middle of char range