_begin_ code improvements