use strict;
use warnings;
use Gtk2 '-init';

my $window = Gtk2::Gdk::Window -> new(undef, { window_type => 'toplevel', });

my $attr= { window_type => 'child', };
my $child= Gtk2::Gdk::Window -> new($window, $attr);

$child->destroy;

