Skip to content

Commit

Permalink
Merge pull request #7 from MartinRogalla/patch-1
Browse files Browse the repository at this point in the history
Note on specifying multiple clauses for a single binding rule.
  • Loading branch information
Guido Wachsmuth authored and Guido Wachsmuth committed Nov 11, 2014
2 parents cf6fc56 + 9ac9754 commit d3349ff
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions milestone2-analysis/day6.md
Original file line number Diff line number Diff line change
Expand Up @@ -177,6 +177,15 @@ You can specify this scoping behaviour in a binding rule:

The pattern of this rule matches programs and its `scopes` clause specifies that this is a scope for class names.

When using multiple clauses in your patterns, be sure to assign them with the same binding rule. If they are spread across multiple binding rules it can occur that some clauses are ignored. The following is an example of correct usage when using multiple clauses:

Bar(name): defines Bar name scopes Foo, Tux

as compared to incorrect usage:

Bar(name): defines Bar
Bar(name): scopes Foo, Tux

#### More Name Binding Rules

You are now able to complete the name binding rules for MiniJava. You should come up with:
Expand Down

0 comments on commit d3349ff

Please sign in to comment.