Implement hasCode/equals for all node types

.toString() not there though, and this one is quite important...