Factoring code to remove duplicates and standardizing the treatment for binding rules and clauses.

This should make bug tracking easier, if, and once, it compiles cleanly again.