Index: config/auto/headers.pm =================================================================== --- config/auto/headers.pm (revision 40217) +++ config/auto/headers.pm (working copy) @@ -104,6 +104,16 @@ if ( $conf->data->get_p5('OSNAME') eq "msys" ) { push @extra_headers, qw(sysmman.h netdb.h); } + + if ( $conf->data->get_p5('OSNAME') eq "MSWin32" ) { + # Microsoft provides two annotations mechanisms. __declspec, which has been + # around for a while, and Microsoft's standard source code annotation + # language (SAL), introduced with Visual C++ 8.0. + # See , + # . + push @extra_headers, qw(sal.h); + } + return @extra_headers; } Index: config/auto/msvc.pm =================================================================== --- config/auto/msvc.pm (revision 40217) +++ config/auto/msvc.pm (working copy) @@ -90,13 +90,6 @@ # To disable deprecation, use _CRT_SECURE_NO_DEPRECATE. See online help # for details. $conf->data->add( " ", "ccflags", "-D_CRT_SECURE_NO_DEPRECATE" ); - - # Microsoft provides two annotations mechanisms. __declspec, which has been - # around for a while, and Microsoft's standard source code annotation - # language (SAL), introduced with Visual C++ 8.0. - # See , - # . - $conf->data->set( HAS_MSVC_SAL => 1 ); } return 1; } Index: include/parrot/compiler.h =================================================================== --- include/parrot/compiler.h (revision 40215) +++ include/parrot/compiler.h (working copy) @@ -99,25 +99,21 @@ */ #define UNUSED(a) /*@-noeffect*/if (0) (void)(a)/*@=noeffect*/; -/* 64-bit CL has some problems, so this section here is going to try to fix them */ -#ifdef PARROT_HAS_MSVC_SAL -# ifdef _WIN64 - /* CL64 can't seem to find sal.h, so take that out of the equation */ -# undef PARROT_HAS_MSVC_SAL - /* CL64 complains about not finding _iob, so this might fix it */ - - -# endif -#endif - -#ifdef PARROT_HAS_MSVC_SAL +#ifdef PARROT_HAS_HEADER_SAL +/* + * Microsoft provides two annotations mechanisms. __declspec, which has been + * around for a while, and Microsoft's standard source code annotation + * language (SAL), introduced with Visual C++ 8.0. + * See , + * . + */ # include # define PARROT_CAN_RETURN_NULL /*@null@*/ __maybenull # define PARROT_CANNOT_RETURN_NULL /*@notnull@*/ __notnull #else # define PARROT_CAN_RETURN_NULL /*@null@*/ # define PARROT_CANNOT_RETURN_NULL /*@notnull@*/ -#endif +#endif /* PARROT_HAS_HEADER_SAL */ #define PARROT_DEPRECATED __attribute__deprecated__ @@ -142,7 +138,7 @@ /* Function argument instrumentation */ /* For explanations of the annotations, see http://www.splint.org/manual/manual.html */ -#ifdef PARROT_HAS_MSVC_SAL +#ifdef PARROT_HAS_HEADER_SAL # define NOTNULL(x) /*@notnull@*/ __notnull x /* The pointer passed may not be NULL */