C64 ACME/C64 Studio source for preventing to overwrite $1000. To test this issue, you could write at the end of file:
_memory = *
!if _memory > $1000 { !error "memory overflows $1000 - write less code!"
}
This should prevent you from writing code that overflows the $1000 memory range.