sync'ing implementation from objc II