[toplevel] Restore 8.6 goal printing behavior.
[toplevel] Restore 8.6 goal printing behavior.

When porting the toplevel to the STM, the logic for goal printing was
simplified too much under optimistic assumptions. The idea was not to
rely on the `vernac_classifier` which is an internal and complicated
beast.

However, it seems there are many cases to consider other than
`is_query`, so at the risk of reimplementing the classifier we revert
to the old approach of using the full classification.

This gives maximum 8.6 compatibility, with the pitfall of having to
call the classifier. Indeed, due to the dynamic nature of the "undo
classifier", we cannot call it after `Stm.add`, as the document tree
will be not the right one, making the classification of undo commands
incorrect (actually raising an error "Cannot undo").

JasonGross/coq,letouzey/coq-wip,coq/coq,ppedrot/coq,Zimmi48/coq,letouzey/coq-wip,Zimmi48/coq,Matafou/coq,letouzey/coq-wip,Matafou/coq,william-lawvere/coq,maximedenes/coq,ppedrot/coq,JasonGross/coq,gares/coq,ejgallego/coq,Zimmi48/coq,coq/coq,gares/coq,ejgallego/coq,SkySkimmer/coq,gares/coq,letouzey/coq-wip,maximedenes/coq,SkySkimmer/coq,SkySkimmer/coq,ejgallego/coq,ppedrot/coq,william-lawvere/coq,silene/coq,william-lawvere/coq,ppedrot/coq,ejgallego/coq,Lionel-Rieg/coq,amintimany/coq,letouzey/coq-wip,coq/coq,coq/coq,SkySkimmer/coq,silene/coq,gares/coq,Zimmi48/coq,gares/coq,JasonGross/coq,amintimany/coq,maximedenes/coq,Lionel-Rieg/coq,amintimany/coq,silene/coq,JasonGross/coq,ppedrot/coq,Lionel-Rieg/coq,Matafou/coq,maximedenes/coq,maximedenes/coq