inline some exception raises

avoid allocating the memory for the obj