extract newtype function if it's present