On 24/10/08 23:40, Brice Figureau wrote: > On 22/10/08 20:26, Brice Figureau wrote: >> Hi, >> >> On 21/10/08 17:13, Luke Kanies wrote: >>> On Oct 21, 2008, at 3:35 AM, Brice Figureau wrote: >>> >>>> I'm volunteering for this. I'll assign the ticket to myself, if nobody >>>> else wants it. >>>> [snipped] >>>> >>>> I'll keep the list posted with my progress and findings. >>> Awesome. >> I've started working on this. I'm following Luke's detailed advice in >> the ticket (ie accumulate comment content, attach it on ast nodes when >> they're found...). >> >> That's the easy part... > > That's what I thought. Until I remembered how a LR parser is working :-(
And I finally found how to solve the issue without rewriting the whole parser :-) > [snip] > Any good idea/advice to solve this issue? > Or did I miss something? I choose to push the comments on the stack on each LBRACE and pop on each RBRACE. I also fetch a reset the current stack level on each statement reduction. This way I can attach comment precisely to the puppet statement they belong to. -- Brice Figureau Days of Wonder http://www.daysofwonder.com --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
