my $self = { q => CGI::Session->new("driver:mysql", undef, DBH), t => Template->new({INCLUDE_PATH => 'templates', PRE_CHOMP => 1, RELATIVE => 1}), is_new => q->is_new() # this is where the error is }; # I realize I don't know how to reference another hash element (q, which is an object reference) within the same hash