Move to make all function parameters constant.

Making use of 'const'-correctness attempts to improve readability and
lock-down the tasks a function can perform to aid focus.