Subclasses, tied hashes, {get,set}_property, undefined values

Dear all,

  I ran into a strange behaviour with Glib::Object::Subclass .
  If I call set_property using a value stored in a tied hash, the
corresponding get_property returns undef. This doesn't happen if 
scalar context is forced when calling set_property.

  Please, see the attached test case.

  If $hashref is a tied hash reference (of course the 'Title'key is
$w->set_property('title', $hashref->{Title});

  then this returns undef:
$w->set_property('title', $hashref->{Title});

  Whereas the following block returns a defined value:
$w->set_property('title', scalar($hashref->{Title}));
$w->set_property('title', $hashref->{Title});

  Does anyone know why this happens?

thanks for your help,

+(split //,' .:-;!/>)|&IH%*#')[$k&15];for($i=$k=$r=0;$j=$r*$r-$i*$i

Description: Text Data

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]