Skip to content

Commit 5f75305

Browse files
committed
Use reference for function name in say/think for secs
1 parent d32c78e commit 5f75305

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

src/blocks/looksblocks.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ void LooksBlocks::onInit(IEngine *engine)
7474
});
7575
}
7676

77-
void LooksBlocks::compileSayOrThinkForSecs(Compiler *compiler, const std::string function)
77+
void LooksBlocks::compileSayOrThinkForSecs(Compiler *compiler, const std::string &function)
7878
{
7979
auto message = compiler->addInput("MESSAGE");
8080
auto duration = compiler->addInput("SECS");

src/blocks/looksblocks.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ class LooksBlocks : public IExtension
2424
void onInit(IEngine *engine) override;
2525

2626
private:
27-
static void compileSayOrThinkForSecs(Compiler *compiler, const std::string function);
27+
static void compileSayOrThinkForSecs(Compiler *compiler, const std::string &function);
2828
static void compileSetOrChangeEffect(Compiler *compiler, const std::string &function, const std::string &effectName, CompilerValue *arg);
2929

3030
static CompilerValue *compileSayForSecs(Compiler *compiler);

0 commit comments

Comments
 (0)