Make sure a rewritten query always has a body
When using a query like SELECT ("x" AS ?x) WHERE {} the current query rewriter implementation will actually drop the body entirely, resulting in a rewritten query of SELECT ("x" AS ?x) which is not valid SPARQL.
Now the rewriter makes sure to always set a body, even if it is empty.
Bug: T434501
CC: @lerickson