RE: ACTIVEPERL_VERSION used to be a string and so fails =822 test

2007-09-17 Thread Jan Dubois
On Fri, 14 Sep 2007, Suresh Govindachar wrote:
   ACTIVEPERL_VERSION is a string in older versions of ActivePerl.
   Googling showed ACTIVEPERL_VERSION as a number in 5.8.7 build 813;
   and we are only concerned with later buids of 5.8.8.  So I decided
   to use the following guard:
 
   #if (PERL_REVISION == 5)  (PERL_VERSION == 8)  (PERL_SUBVERSION = 8)
   #  if (ACTIVEPERL_VERSION = 822)
   #define PERL589_OR_LATER
   #  endif
   #endif

That looks good to me.

Cheers,
-Jan

___
Perl-Win32-Users mailing list
Perl-Win32-Users@listserv.ActiveState.com
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs


ACTIVEPERL_VERSION used to be a string and so fails =822 test

2007-09-14 Thread Suresh Govindachar

  Jan Dubois wrote:
  
   should be written more general like this:
  
 /* ActivePerl build 822 still identifies itself as 5.8.8 but 
  * already contains many of the changes from the upcoming 
  * Perl 5.8.9 release.
  */
 #if (ACTIVEPERL_VERSION = 822)
 #  define PERL589_OR_LATER
 #endif
 #if (PERL_REVISION == 5)  (PERL_VERSION == 8)  (PERL_SUBVERSION = 9)
 #  define PERL589_OR_LATER
 #endif
 #if (PERL_REVISION == 5)  (PERL_VERSION = 10))
 #  define PERL589_OR_LATER
 #endif
  
   And then later you just check for PERL589_OR_LATER
  
  #ifdef PERL589_OR_LATER 
  ...
  #endif

  Your suggestions were incorporated in if_perl.xs, but older
  versions of perl define

 #define ACTIVEPERL_VERSION Built  __DATE__   __TIME__

  and compilers complain about the test to compare
  ACTIVEPERL_VERSION with a number.

  One would use eq in perl, but this is C pre-processing -- how 
  could one check if ACTIVEPERL_VERSION = 822?

  Thanks,

  --Suresh


___
Perl-Win32-Users mailing list
Perl-Win32-Users@listserv.ActiveState.com
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs


RE: ACTIVEPERL_VERSION used to be a string and so fails =822 test

2007-09-14 Thread Suresh Govindachar

  ACTIVEPERL_VERSION is a string in older versions of ActivePerl.
  Googling showed ACTIVEPERL_VERSION as a number in 5.8.7 build 813;
  and we are only concerned with later buids of 5.8.8.  So I decided 
  to use the following guard:
   
  #if (PERL_REVISION == 5)  (PERL_VERSION == 8)  (PERL_SUBVERSION = 8) 
  #  if (ACTIVEPERL_VERSION = 822)
  #define PERL589_OR_LATER
  #  endif
  #endif


___
Perl-Win32-Users mailing list
Perl-Win32-Users@listserv.ActiveState.com
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs