What exactly does this code do?