in reply to Definedness of an Object

I don't know why you get that result. It doesn't happen when I try this bit that should be equivalent:
use strict; use warnings; my $dep_name = 'Salisbury'; my $dep_tip = bless( { '_location' => $dep_name, '_id' => 259, '_key' => 'SLSBRY' }, 'Object::Location' ); if ( ! defined $dep_tip ){ use Carp; croak ( "DATA ERROR: Could not find any location for '$dep_name'" ); }

Caution: Contents may have been coded under pressure.