[petsc-dev] PETSC_DESIRE_COMPLEX vs <petsccomplex.h>
    Barry Smith 
    bsmith at mcs.anl.gov
       
    Mon Jul 28 11:58:50 CDT 2014
    
    
  
On Jul 28, 2014, at 10:39 AM, Jed Brown <jed at jedbrown.org> wrote:
> Can we loosen the order-dependence so that instructions can be
> 
>  #include <petsccomplex.h>
> 
> instead of defining PETSC_DESIRE_COMPLEX in the compilation unit?  I
> think the include is more natural and less error-prone.
  Where petsccomplex.h  simply defines PETSC_DESIRE_COMPLEX?  
   And what happens if petsccomplex.h is included after petscsys.h it will have no affect? Should it generate an error if not defined first?
  So petsccomplex.h in pseudo code would be 
      #if defined(__PETSCMATH_H)
      #error   must include petsccomplex.h BEFORE other petsc include files
      #endif
      #define PETSC_DESIRE_COMPLEX
   Seems reasonable to me.
   Barry
    
    
More information about the petsc-dev
mailing list