Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Formatting: Execute runformat #6741

Merged
merged 1 commit into from
Aug 30, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 10 additions & 10 deletions test/cfg/emscripten.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -13,14 +13,14 @@
void em_asm_test()
{
// inline some JavaScript
EM_ASM(alert('hello'););
MAIN_THREAD_EM_ASM(alert('hello main thread'););
EM_ASM(alert('hello'); );
MAIN_THREAD_EM_ASM(alert('hello main thread'); );

// pass parameters to JavaScript
EM_ASM(
{
console.log('I received: ' + [$0, $1]);
},
{
console.log('I received: ' + [$0, $1]);
},
100, 35.5);

// pass a string to JavaScript
Expand Down Expand Up @@ -73,16 +73,16 @@ void main_thread_em_asm_ptr_test()
// cppcheck-suppress leakReturnValNotUsed
MAIN_THREAD_EM_ASM_PTR(
return stringToNewUTF8("Hello");
);
);
}

EM_JS(void, two_alerts, (), {
alert('hai');
alert('bai');
});
alert('hai');
alert('bai');
});
EM_JS(void, take_args, (int x, float y), {
console.log('I received: ' + [x, y]);
});
});

void em_js_test()
{
Expand Down
2 changes: 1 addition & 1 deletion test/cfg/std.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -5179,7 +5179,7 @@ struct S_std_as_const { // #12974
std::list<int> l;
};

void containerOutOfBounds_std_string(std::string &var) { // #11403
void containerOutOfBounds_std_string(std::string &var) { // #11403
std::string s0{"x"};
// cppcheck-suppress containerOutOfBounds
var+= s0[2];
Expand Down
4 changes: 2 additions & 2 deletions test/cli/shared-items-project/Main/MainFile.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,6 @@

int main(void)
{
Shared::TestClass test{};
return 0;
Shared::TestClass test{};
return 0;
}
10 changes: 4 additions & 6 deletions test/cli/shared-items-project/Shared/TestClass.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,8 @@

using namespace Shared;

TestClass::TestClass()
{
}
TestClass::TestClass()
{}

TestClass::~TestClass()
{
}
TestClass::~TestClass()
{}
2 changes: 1 addition & 1 deletion test/cli/shared-items-project/Shared/TestClass.h
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ namespace Shared
{
class TestClass
{
public:
public:
explicit TestClass();
virtual ~TestClass();
};
Expand Down
4 changes: 3 additions & 1 deletion test/cli/whole-program/odr1.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,9 @@
class C : public Base
{
public:
void f() override { std::cout << "1"; }
void f() override {
std::cout << "1";
}
};

Base *c1_create()
Expand Down
4 changes: 3 additions & 1 deletion test/cli/whole-program/odr2.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,9 @@
class C : public Base
{
public:
void f() override { std::cout << "2"; }
void f() override {
std::cout << "2";
}
};

Base *c2_create()
Expand Down
2 changes: 1 addition & 1 deletion tools/defines/float.c
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
#include "stdio.h"

#define PRINT_DEF(d, f) \
fprintf(stdout, ";"#d"=%"#f, d)
fprintf(stdout, ";"#d "=%"#f, d)

int main(void)
{
Expand Down
2 changes: 1 addition & 1 deletion tools/defines/limits.c
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
#include "stdio.h"

#define PRINT_DEF(d, f) \
fprintf(stdout, ";"#d"=%"#f, d)
fprintf(stdout, ";"#d "=%"#f, d)

int main(void)
{
Expand Down
4 changes: 2 additions & 2 deletions tools/defines/stdint.c
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
#include "stdio.h"

#define PRINT_DEF(d, f) \
fprintf(stdout, ";"#d"=%"#f, d)
fprintf(stdout, ";"#d "=%"#f, d)

#define PRINT_DEF_N(d1, d2, f) \
do { \
Expand Down Expand Up @@ -40,5 +40,5 @@ int main(void)
PRINT_DEF(WINT_MIN, d);
PRINT_DEF(WINT_MAX, d);

return 0;
return 0;
}
Loading