WIP Tidyup and adding support for exit/enter regions