This brings us up to date with Changeset 1376. Also a lot of fiddling around with types (that was probably a bit reckless). Still compiles and runs in Windows and Linux.