diff options
author | Pascal Rigaux <pixel@mandriva.com> | 2008-01-18 13:52:00 +0000 |
---|---|---|
committer | Pascal Rigaux <pixel@mandriva.com> | 2008-01-18 13:52:00 +0000 |
commit | f29cd86fbd748de5a623bd75b2f8ac320c5ce2b9 (patch) | |
tree | ac68dd9ae9bc47815cd1b9ba53979dc25766280d /perl-install/mygtk2.pm | |
parent | 7ee91f13918cdf5e69091006cd9f7197dc583284 (diff) | |
download | drakx-f29cd86fbd748de5a623bd75b2f8ac320c5ce2b9.tar drakx-f29cd86fbd748de5a623bd75b2f8ac320c5ce2b9.tar.gz drakx-f29cd86fbd748de5a623bd75b2f8ac320c5ce2b9.tar.bz2 drakx-f29cd86fbd748de5a623bd75b2f8ac320c5ce2b9.tar.xz drakx-f29cd86fbd748de5a623bd75b2f8ac320c5ce2b9.zip |
"my $foo if 0" semantic has changed in some cases, using the new "state" keyword instead
Diffstat (limited to 'perl-install/mygtk2.pm')
-rw-r--r-- | perl-install/mygtk2.pm | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/perl-install/mygtk2.pm b/perl-install/mygtk2.pm index f218b4e66..f1b2acece 100644 --- a/perl-install/mygtk2.pm +++ b/perl-install/mygtk2.pm @@ -2,6 +2,7 @@ package mygtk2; use diagnostics; use strict; +use feature 'state'; our @ISA = qw(Exporter); our @EXPORT = qw(gtknew gtkset gtkadd gtkval_register gtkval_modify); @@ -1118,7 +1119,7 @@ sub may_destroy { } sub root_window() { - my $root if 0; + state $root; $root ||= Gtk2::Gdk->get_default_root_window; } |