Allow using code in itemenums

This avoids closing all itemenums after(!) a code section.