You are getting that because your PHP is EXTREMELY OLD. This error appears only on PHP 5.4 or earlier.
PHP 5.4 reached end of life: 3 Sep 2015 (2 years, 7 months ago)
It’s already PHP 7.2. PHP 7 is about 4 times faster then PHP 5. Only this should be the reason to upgrade. More and more code will stop supporting outdated PHP versions. Please consider upgrade and you won’t be hitting issues like this.
Also PHP 5.4 has several security issues that are not fixed and not going to be fixed, because it’s no longer supported or updated.
Anyway, please use PHP version that is currently officially supported (http://php.net/supported-versions.php) – PHP 5.6, PHP 7.0, PHP 7.1 or PHP 7.2. SNAP is fully tested and has no issues with any of those versions.