Skip to content
Fetching contributors…
Cannot retrieve contributors at this time
23 lines (16 sloc) 612 Bytes
use v6;
use Test;
# L<S11/"Modules"/"There are two basic declaration syntaxes:">
plan 7;
is($?MODULE, 'Main', '$?MODULE for main module');
module Foo {
is($?PACKAGE, 'Foo', '$?PACKAGE for "module Foo {}"');
is($?CLASS, 'Main', '$?CLASS unchanged for "module Foo {}"');
is($?MODULE, 'Foo', '$?MODULE for "module Foo {}"');
module Bar {
is($?PACKAGE, 'Foo::Bar', '$?PACKAGE for "module Foo::Bar {}"');
is($?CLASS, 'Main', '$?CLASS unchanged for "module Foo::Bar {}"');
is($?MODULE, 'Foo::Bar', '$?MODULE for "module Foo::Bar {}"');
# vim: ft=perl6
Jump to Line
Something went wrong with that request. Please try again.