Fixed build on MacOS
Added workaround for Apple implementation