lang: Wrap Mac specific bits in an Autorelease pool

This prevents objects leaking when this code is called in a routine.

Signed-off-by: Scott Wilson <i@scottwilson.ca>