builtins: made sort non-const

Currently, there's a lot of writeback going on with case and bind. This
makes virtually any function need to handle writeback.