Beefy Boxes and Bandwidth Generously Provided by pair Networks
go ahead... be a heretic
 
PerlMonks  

Re: Writing portable code

by syphilis (Canon)
on Mar 08, 2013 at 10:23 UTC ( #1022384=note: print w/ replies, xml ) Need Help??


in reply to Writing portable code

Or (perhaps):

4. I could use Inline::C or XS:

void f(void) { #ifdef _WIN32 /* code */ #else /* other code */ #endif }
This avoids any runtime or compile-time determination of the OS. (It was already determined when the script/module was built.) And only the one file !

Cheers,
Rob


Comment on Re: Writing portable code
Download Code

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1022384]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others scrutinizing the Monastery: (11)
As of 2015-07-29 11:49 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The top three priorities of my open tasks are (in descending order of likelihood to be worked on) ...









    Results (263 votes), past polls