move ref-counting into detail::notify