summaryrefslogtreecommitdiff
path: root/ext/Fcntl/Fcntl.pm
diff options
context:
space:
mode:
authorNicholas Clark <nick@ccl4.org>2010-10-18 19:30:12 +0200
committerNicholas Clark <nick@ccl4.org>2010-10-18 19:32:26 +0200
commit96d24b8ce2ce0411b22e29e30ee26700bb1213cf (patch)
tree6767b189834133a98c2c29aa35615e4a72a9bd3a /ext/Fcntl/Fcntl.pm
parentefe77345f79553ebc2eff1978e461a89d4448f00 (diff)
downloadperl-96d24b8ce2ce0411b22e29e30ee26700bb1213cf.tar.gz
Convert Fcntl::S_IS{LNK,SOCK,BLK,CHR,FIFO,WHT,ENFMT} to XS.
This reduces the memory usage of Fcntl by quite a bit, as the same XSUB is used by all 9 S_IS* functions.
Diffstat (limited to 'ext/Fcntl/Fcntl.pm')
-rw-r--r--ext/Fcntl/Fcntl.pm8
1 files changed, 0 insertions, 8 deletions
diff --git a/ext/Fcntl/Fcntl.pm b/ext/Fcntl/Fcntl.pm
index 76f72265ad..4032e0985d 100644
--- a/ext/Fcntl/Fcntl.pm
+++ b/ext/Fcntl/Fcntl.pm
@@ -218,14 +218,6 @@ BEGIN {
sub S_IFMT { @_ ? ( $_[0] & _S_IFMT() ) : _S_IFMT() }
sub S_IMODE { $_[0] & 07777 }
-sub S_ISLNK { ( $_[0] & _S_IFMT() ) == S_IFLNK() }
-sub S_ISSOCK { ( $_[0] & _S_IFMT() ) == S_IFSOCK() }
-sub S_ISBLK { ( $_[0] & _S_IFMT() ) == S_IFBLK() }
-sub S_ISCHR { ( $_[0] & _S_IFMT() ) == S_IFCHR() }
-sub S_ISFIFO { ( $_[0] & _S_IFMT() ) == S_IFIFO() }
-sub S_ISWHT { ( $_[0] & _S_IFMT() ) == S_IFWHT() }
-sub S_ISENFMT { ( $_[0] & _S_IFMT() ) == S_ENFMT() }
-
sub AUTOLOAD {
(my $constname = $AUTOLOAD) =~ s/.*:://;
die "&Fcntl::constant not defined" if $constname eq 'constant';