fix reversal of top-level things