Abraxas/ECS C++ Home  Table of Contents 

Module - 80.html

ABRAXAS SOFTWARE - CodeCheck ECS C++ Test-Suite ECS C++.

ECS C++-C Test Suite for Module - 80.cpp

/*

80. Declare global functions, variables, or constants as static members of a class.

*/

// bad, should be static in class

int PI = 3.14159;
int glofoo(void);
class c80 {
  

// good

  static int global;
  
  static int glofoo( void );
  
};

Abraxas/ECS C++ Home  Table of Contents

ABRAXAS SOFTWARE - CodeCheck ECS C++ Test-Suite ECS C++