[infoexpression] store node_type_t rather than bool to indicate the node type
[infoexpression] use the type from the nodes rather than carrying around a separate node_type stack
Merge pull request #4916 from jmarshallnz/cleanup_node_type

Cleanup node type