Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Dynamic module loading by require in another modules has broken recently? #5996

Closed
p6rt opened this issue Jan 10, 2017 · 5 comments
Closed

Comments

@p6rt
Copy link

p6rt commented Jan 10, 2017

Migrated from rt.perl.org#130535 (status was 'resolved')

Searchable as RT130535$

@p6rt
Copy link
Author

p6rt commented Jan 10, 2017

From asato.wakisaka@gmail.com

With recent moarvm, loading modules dynamically by require :​:("Some​::Module") in another module fails and throws error.
Here are sample codes to reproduce​: https://github.com/skaji/Crust-issue

The sample codes above works fine in rakudo-2016.11, but throws exception like "No such symbol 'C​::B'" in recent one.

$ perl6 -version
This is Rakudo version 2016.12-239-gc405f0672 built on MoarVM version 2016.12-71-g331a6b43
implementing Perl 6.c.

And, it runs properly when the "require" is placed under main, not in the module. (ref​: skaji/Crust-issue#1 )

It seems recent changes about lexical "use" affected?

Regards.

Asato Wakisaka (github.com/astj)

@p6rt
Copy link
Author

p6rt commented Jan 12, 2017

From @LLFourn

Confirmed. As you say, it's probably because require hasn't been updated to
the new lexical importing design like "use" has. A few of the tests
probably have to be re-written for require as well.

LL
On Wed, Jan 11, 2017 at 6​:27 AM Asato Wakisaka <perl6-bugs-followup@​perl.org>
wrote​:

# New Ticket Created by Asato Wakisaka
# Please include the string​: [perl #​130535]
# in the subject line of all future correspondence about this issue.
# <URL​: https://rt-archive.perl.org/perl6/Ticket/Display.html?id=130535 >

With recent moarvm, loading modules dynamically by require
:​:("Some​::Module") in another module fails and throws error.
Here are sample codes to reproduce​: https://github.com/skaji/Crust-issue

The sample codes above works fine in rakudo-2016.11, but throws exception
like "No such symbol 'C​::B'" in recent one.

$ perl6 -version
This is Rakudo version 2016.12-239-gc405f0672 built on MoarVM version
2016.12-71-g331a6b43
implementing Perl 6.c.

And, it runs properly when the "require" is placed under main, not in the
module. (ref​: skaji/Crust-issue#1 )

It seems recent changes about lexical "use" affected?

Regards.

Asato Wakisaka (github.com/astj)

@p6rt
Copy link
Author

p6rt commented Jan 12, 2017

The RT System itself - Status changed from 'new' to 'open'

@p6rt
Copy link
Author

p6rt commented Mar 6, 2017

From @niner

Fixed by commits 63cf5cac00, 3e86d0fa9a, 5b98caa35a and 6771deefa4.

@p6rt
Copy link
Author

p6rt commented Mar 6, 2017

@niner - Status changed from 'open' to 'resolved'

@p6rt p6rt closed this as completed Mar 6, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant