Fixed compiler error on MacOS