Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #Tests.rakumod
- use v6.*;
- module Test {
- use Colors;
- BEGIN {
- for
- Colors:: #Is a custum module containing constants
- -> $stash {
- .raku.say;
- for $stash.grep(*.key.match(/.*/)) {
- say .key.raku ~ ' => ' ~ .value.raku;
- }
- }
- }
- }
- sub EXPORT(*@args, *%_) {
- if @args {
- my $imports := Map.new( |(EXPORT::all::{ @args.map: '&' ~ * }:p) );
- if $imports != @args {
- die "List::AllUtils doesn't know how to export: "
- ~ @args.grep( { !$imports{$_} } ).join(', ')
- }
- $imports
- }
- else {
- Map.new
- }
- }
- ##########
- Main script test.raku is just:
- #!/bin/env raku
- use Tests;
- ./test.raku ==>
- When i run that for the first time : I get a list of symbols displayed:
- Mu
- "BGND_256_MASQ" => 65280
- "uInt16" => Colors::uInt16
- "LBLACK" => 8
- "BLACK" => 0
- "LIBGMSK" => 128
- [ .... ]
- But when i run that on the second time, i get nothing, no List, no error.
- WHY ???????????????????????????????????????????????
- I suppose there's some cache tricks or else...
- What can i do to have it displayed all the time.
- Thanks!
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement