system('whatever'); if ($?) { warn "whatever failed\n"; }