Subject: | theme attribute is ineffective |
neither setting the PERL_METASYNTACTIC_THEME environment variable (for perl-metasyntactic) nor setting the theme attribute on the Acme::PPIx::MetaSyntactic constructor affects the variable names in the output, they remain from the 'haddock' theme; this applies to passing both strings ('dilbert', f.e.) or Acme::MetaSyntactic objects.
perl 5.24.3; Moo 2.003004; Type::Tiny 1.004002; Acme::MetaSyntactic 1.014
The following code
perl 5.24.3; Moo 2.003004; Type::Tiny 1.004002; Acme::MetaSyntactic 1.014
The following code
use Acme::PPIx::MetaSyntactic;
use feature 'say';
# my $acme = "Acme::PPIx::MetaSyntactic"->new(theme => 'dilbert', document => \<<'END');
my $acme = "Acme::PPIx::MetaSyntactic"->new(theme => Acme::MetaSyntactic->new('dilbert'), document => \<<'END');
my $acme = "Acme::PPIx::MetaSyntactic"->new(theme => Acme::MetaSyntactic->new('dilbert'), document => \<<'END');
use constant PLACE => "World";
sub join_spaces {
return join " ", @_;
}
my @greetings = qw(Hello);
say join_spaces($greetings[0], PLACE);
END
say $acme->document;
produces the following output
use constant PROFITEUR => "World";
sub cyclotron {
return join " ", @_;
}
my @terroriste = qw(Hello);
say cyclotron($terroriste[0], PROFITEUR);