Move the definition of *MODE* to the top of the file.
Capture source location information.