Skip to content

Commit

Permalink
ClangTidy issue in lib/system/Route.hpp #1296
Browse files Browse the repository at this point in the history
  • Loading branch information
HIROSN committed Aug 22, 2024
1 parent 5116b27 commit 7ff3234
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
4 changes: 2 additions & 2 deletions lib/system/Route.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -102,12 +102,12 @@ namespace MAT_NS_BEGIN {
void operator()(TRealArgs&& ... args) const
{
for (IRoutePassThrough<TArgs...>* target : m_passthroughs) {
if (!(*target)(std::forward<TRealArgs>(args) ...)) {
if (!(*target)(args ...)) {
return;
}
}
if (m_target) {
(*m_target)(std::forward<TRealArgs>(args) ...);
(*m_target)(args ...);
}
}

Expand Down
6 changes: 3 additions & 3 deletions tests/unittests/RouteTests.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ TEST_F(RouteTests, SourceCallsSink)
RouteSource<> source0;
source0 >> sink0;

RouteSource<int, bool&, NonCopyableThing const&, Canary, std::vector<int>&&> source5;
RouteSource<int, bool&, NonCopyableThing const&, Canary, std::vector<int>&> source5;
source5 >> sink5;


Expand All @@ -137,10 +137,10 @@ TEST_F(RouteTests, SourceCallsSink)
SetArgReferee<1>(true),
InvokeArgument<3>()
));
source5(123, flag, thing, canary, std::move(data));
source5(123, flag, thing, canary, data);
EXPECT_THAT(flag, true);
EXPECT_THAT(canary, Eq("alive"));
EXPECT_THAT(data, IsEmpty());
EXPECT_THAT(data, Not(IsEmpty()));
}

TEST_F(RouteTests, PassThroughsAreInvokedInBetween)
Expand Down

0 comments on commit 7ff3234

Please sign in to comment.