Partially fixed up tree after merge from HEAD. More to do.