----- Original Message -----
> On Jul 5, 2011, at 1:37 PM, Brice Figureau wrote:
> 
> > On 05/07/11 21:36, Luke Kanies wrote:
> >> This is primarily two changes:
> >> 
> >> * Add [] and []= to Puppet::Parser::Scope
> >> * Replace lookupvar/setvar usage with those two methods
> >> 
> >> The first was pretty simple, but the second ended up touching a
> >> lot of files.
> > 
> > What's the underlying purpose (ie the big plan behind) of those
> > changes?
> 
> Hiera (Arri's extlookup replacement) needs Scope to have hash-like
> behavior, and this is to provide that.
> 
> Once I added the methods, I realized how ugly the existing methods
> were, and it made sense to clean the whole thing up from there.
> 
> Sorry, that should have been in my commit - I'll fix that.

I think hiera aside this is a great improvement, it behaves more ruby like
and less surprising, scope will just work how people who know ruby would think
it would work and thats a big win.

If in a template using foo would return nil if its unset that would be a 
big win too, means has_variable?("foo") can go away, not sure how related that
is to your refactor though.

-- 
You received this message because you are subscribed to the Google Groups 
"Puppet Developers" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/puppet-dev?hl=en.

Reply via email to