in reply to $! vs the @_ passed to your SIG(DIEWARN) handler

$! is really just errno and so can only be set to a finite number of string values. For example,

$!= "Oops"; print $!;
prints nothing because the first line sets $! to 0 and the text associated with errno == 0 is the empty string. So $! can't (in general) be the same as the error message string that gets passed into a __WARN__ handler.

See "man strerror" (or your C compiler's documentation) for more on what ends up in $!.

        - tye (but my friends call me "Tye")