develooper Front page | perl.perl5.porters | Postings from April 2007

Newx() vs New()

Thread Next
From:
Tels
Date:
April 6, 2007 14:16
Subject:
Newx() vs New()
Message ID:
200704062317.35651@bloodgate.com
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Moin,

just for the record, today I was bitten by the (un)expected[0] change from 
New() to Newx() - I had looked up in perldoc perlguts how to do that, wrote 
the code, tested it, only to get a fail report.

Turns out Newx() is new in 5.8.8, but you don't see that from just reading 
the doc about Newx(), so I ended up writing code that would *only* run on 
5.8.8 but not 5.8.7 or anything earlier. Ooops.[1]

All the best,

Tels

[0] Afterwards I remembered the discussion about that changes. :)
[1] Luckily, there is ppport.h, but it's kinda silly to increase a 
distribution by 50% just for some #define Newx(a,b,c) New(0,a,b,c) ...

- -- 
 Signed on Fri Apr  6 23:12:45 2007 with key 0x93B84C15.
 View my photo gallery: http://bloodgate.com/photos
 PGP key on http://bloodgate.com/tels.asc or per email.

 Firefox: What are you trying to tell me, that I can block pop-ups?

 Morpheus: I'm trying to tell you that when you're ready, you won't have
 to. 

  -- Skyshadow (508) on 2004-11-30 at /.
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.2 (GNU/Linux)

iQEVAwUBRhbVD3cLPEOTuEwVAQJ0Kwf/RXBAQpEWfjylMb1sWt+HowO/ym/Ndi8s
2DB1SvFhQnHCG6v5xx83jIqAV6M/LoujmbWbEoPAjoyKGv/BAge1UZDGtn7UyHri
XLgL6w9L5Bp8h7e9KjtGz1UVwzXHxYfdQhyZbBhp6JE3sj8HdlIlfkSJ3LMAcsPa
OpfHOzb4J4Kd4ZF2MZULZGkC5LiOS4ll3XgG+Vi3CRdcZkPaMbRL/g8l7RK/5O0J
MEeuKKAqmm8rpynRnSPvYZKkiojc/aX7ZgQhVLpFqteJglq/ME8L36sLexamEUnQ
9FEoCdkE9tuLpCsFCEI2WkYfKDmnCkEaJolqwo1nUoTWlFN5dC6AMQ==
=Ich0
-----END PGP SIGNATURE-----

Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About