revert emacs <= 22 matte/flatten changes i made