abstract out toplevelcomments a bit