Improved the query optimization/rewrite processor
Preparing for the unfielded-bug killing - added documentation to the parser code; it explains rationale behind how components are chained