File tree Expand file tree Collapse file tree 1 file changed +6
-3
lines changed Expand file tree Collapse file tree 1 file changed +6
-3
lines changed Original file line number Diff line number Diff line change @@ -9,8 +9,10 @@ class Test {
9
9
const int pattern;
10
10
11
11
public:
12
- Test (const char * _name) : name(_name), pattern(PATTERN_CHECK_VALUE) {
13
- print (" init" );
12
+ Test (const char * _name, bool print_message=true ) : name(_name), pattern(PATTERN_CHECK_VALUE) {
13
+ if (print_message) {
14
+ print (" init" );
15
+ }
14
16
}
15
17
16
18
void print (const char *message) {
@@ -39,7 +41,7 @@ class Test {
39
41
};
40
42
41
43
/* Check C++ startup initialisation */
42
- Test s (" Static" );
44
+ Test s (" Static" , false );
43
45
44
46
/* EXPECTED OUTPUT:
45
47
*******************
@@ -59,6 +61,7 @@ int main (void) {
59
61
bool result = true ;
60
62
for (;;)
61
63
{
64
+ s.print (" init" );
62
65
// Global stack object simple test
63
66
s.stack_test ();
64
67
if (s.check_init () == false )
You can’t perform that action at this time.
0 commit comments