Issue #18672 has been updated by Charlie Sharpsteen. Status changed from Accepted to Duplicate
Duplicate of #14301. ---------------------------------------- Bug #18672: Cannot use empty hash literal in case statement https://projects.puppetlabs.com/issues/18672#change-89325 * Author: Andrew Parker * Status: Duplicate * Priority: Normal * Assignee: * Category: language * Target version: * Affected Puppet version: 2.7.19 * Keywords: language parser * Branch: ---------------------------------------- As reported by Peter Bauer on the puppet-dev mailing list (<https://groups.google.com/forum/#!msg/puppet-dev/bYF1XMKPZ2M/nGNl_-5K1nEJ>), the following code will produce a parse error: <pre> $boole = true $testvar = $boole ? { true => {}, default => { hans => franz }, } </pre> The error: <pre> Could not parse for environment production: Syntax error at '{'; expected '}' at /tmp/test.pp:3 </pre> An even simpler example is: <pre> > puppet apply -e "notify(true ? { true => {} })" Error: Could not parse for environment production: Syntax error at '{'; expected '}' at line 1 on node aparker.corp.puppetlabs.net Error: Could not parse for environment production: Syntax error at '{'; expected '}' at line 1 on node aparker.corp.puppetlabs.net </pre> -- You have received this notification because you have either subscribed to it, or are involved in it. To change your notification preferences, please click here: http://projects.puppetlabs.com/my/account -- You received this message because you are subscribed to the Google Groups "Puppet Bugs" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. Visit this group at http://groups.google.com/group/puppet-bugs?hl=en. For more options, visit https://groups.google.com/groups/opt_out.
