in reply to Can a perl program always be architecture-independent?
If your program opens a hardcoded file at "/tmp/foo.bar", then it won't work on Windows (which is why the Java cross-platform standards say you can't hardcode file paths).
Other programs may make subtle assumptions about the word size (32-bits vs. 64-bits).
Doing unlink $file won't delete the file on systems that have versioned filesystems (like VMS). In such a case, unlinking the file returns it to the previous version. You have to do while(-e $file) { unlink $file } to completely get rid of it.
Cross-platform issues are often subtle and cover a wider range of cases than any one programmer could possibly remember. The only real way to know is to try it on the platform and test throughly.
"There is no shame in being self-taught, only in not trying to learn in the first place." -- Atrus, Myst: The Book of D'ni.
|
|---|