More cleanup, haven't tested compilation for these changes.