exists#
Tied-hash membership test: does a key exist in %Config?
Synopsis#
if (exists $Config{useithreads}) { ... }
What you get back#
A true value when the key is part of the configuration (even if the recorded value is undef), false otherwise.
Examples#
use Config;
print exists $Config{d_fork} ? "yes" : "no"; # yes
print exists $Config{nonesuch} ? "yes" : "no"; # no
print exists $Config{useithreads} ? "yes" : "no"; # yes (value is undef)
Edge cases#
Pair
EXISTSwithFETCHto distinguish “key is absent” from “key is present but undef”.
Differences from upstream#
Fully compatible with upstream.