catfood has asked for the wisdom of the Perl Monks concerning the following question:
And it fails with the following error# global scope dist = "/archive/"; %warnings parameter off; ### allow parameter redefinition aa1 { environment = T; aa2 { Xlogin = "jimmy"; } }
I use the following code to read itInvalid decl item: Was expecting parameter or macro or comment or warn +ing but found "aa2 {" instead at /home/.../XMLConfigs/e.cfg line 11.
Please let me know if I am doing something stupid or the module does not work as expected. Its version 1.31 (based on the top of the scoped.pm file) I think the latest on CPAN, I did an install Config::Scoped about an hour ago. If the module is in a bad way can someone suggest a module which allows variables to be inherited and redefined in different scopes. Basically this module is what I need if I could get it to work :) . This is perl, v5.6.1 built for i386-linux#!/usr/local/bin/perl -w use strict; use Config::Scoped; use Data::Dumper; my $parser = Config::Scoped->new( file => 'e.cfg' ); my $config = $parser->parse; print Dumper($config);
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Config::Scoped module does not nest blocks as expected
by catfood (Novice) on Dec 13, 2004 at 03:01 UTC | |
|
Re: Config::Scoped module does not nest blocks as expected
by metaperl (Curate) on Dec 13, 2004 at 18:29 UTC | |
by catfood (Novice) on Dec 14, 2004 at 04:33 UTC |