# New Ticket Created by  "Tokuhiro Matsuno" 
# Please include the string:  [perl #126316]
# in the subject line of all future correspondence about this issue. 
# <URL: https://rt.perl.org/Ticket/Display.html?id=126316 >


Here is a code set.

==> foo.t <==
use v6;

class C::T {
}

use C::B;

C::B.a()

==> lib/C/B.pm <==
use v6;
unit class C::B;

method a() {
    my $pkg = 'C::M';
    require ::($pkg);
    ::($pkg).new();
    say "DONE";
}

==> lib/C/M.pm <==
use v6;
unit class C::M;

Run this script, then I get this message:
ᐅ  perl6-m -Ilib foo.t
Failed

Actually thrown at:
  in method a at /Users/tokuhirom/tmp/20151010/70df67f456ea6193434a/lib/C/B.pm:7
  in block <unit> at foo.t:8

My Perl6 version is:
ᐅ  perl6-m --version
This is perl6 version 2015.09-210-gef814c3 built on MoarVM version 
2015.09-39-g1434283

Attachment: dynamic-loading-bug.tgz
Description: Binary data

Reply via email to