(WIP) Immutable headnodes

This is probably worth looking at now; there's still some work to do, but it's roughly the shape I'm shooting for.
So it is.  In that case, I repeat my sentiment about things like this being confusing---looks like I was the confused one.