Core::unitAt: return ref, not pointer. + few changes