Skip to content
This repository has been archived by the owner on Feb 4, 2019. It is now read-only.

Better parsing of statement lists #322

Merged
merged 3 commits into from
Dec 17, 2014

Conversation

sburnicki
Copy link
Member

These commits fix the issue described in #7.
It was a real pain to modify this grammar correctly, but I finally managed to get a grammar with even less shift/reduce conflicts as before :)

@@ -1181,6 +1213,7 @@ public void Pipeline3Test()

static dynamic ParseInput(string s)
{
PowerShellGrammar.Parser.Context.TracingEnabled = true;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

what is this for?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If this flag is set, the parser will trace what kind of shifts and reductions it performs.
When I tried different ways of writing this grammar, it turned out to be very useful for understanding the problems my grammar had while I debugged my tests.

@JayBazuzi
Copy link
Contributor

should i have merged this first? there is a conflict now :-(

@sburnicki
Copy link
Member Author

Nope, both pull requests include changes to the same lines. I'll merge it and update it.

JayBazuzi added a commit that referenced this pull request Dec 17, 2014
Better parsing of statement lists
@JayBazuzi JayBazuzi merged commit 65b0966 into Pash-Project:master Dec 17, 2014
@sburnicki sburnicki deleted the statement_sep branch December 17, 2014 19:33
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants