puppetlabs/puppet — pull request #1694 by ab (2013-06-06 06:57:03+00:00)
Title: Improve error messages for non-string variable names

Prior to 5ac681f, puppet would return a useful message if you attempted to treat an undef variable as a hash, like so:

$var is not a hash or array when accessing it with foo at /manifest.pp:123 on node example.com

Following that commit, puppet fails with an extremely unhelpful message because the variable is `:undef`:

Scope variable name is a Symbol, not a string on node example.com

Instead, return something helpful again, and also raise an exception that will cause line numbers to be shown.