Getting Started Documentation Glish Learn More Programming Contact Us
Version 1.9 Build 1556
News FAQ
Search Home


next up previous contents index
Next: Exceptions Up: Programming Tips Previous: Portability

Examples - Warnings

#include <stddef.h>

   ....

   struct MyStruct {
      int x;
      int y;
   };


   ...

   int theYOffset = offsetof(MyStruct, y);

   ...

class A {
public:
   A() : y(9), x(7+y) {};   // NO !!! y may not be initialized before x
private:
   int x;
   int y;
}; // A


next up previous contents index
Next: Exceptions Up: Programming Tips Previous: Portability   Contents   Index
Please send questions or comments about AIPS++ to aips2-request@nrao.edu.
Copyright © 1995-2000 Associated Universities Inc., Washington, D.C.

Return to AIPS++ Home Page
2006-10-15