After updating to 1.5, the following error appears:

Parse error: syntax error, unexpected T_STATIC in \sites\all\modules\contrib\entitycache\includes\entitycache.entitycachecontrollerhelper.inc on line 96

My Drupal system still runs on PHP5.2, which is sufficient for D7.
I guess the new functionality requires higher PHP -version then Drupal 7 does.

CommentFileSizeAuthor
#5 parse_error_syntax-2619270-5.patch2.12 KBjoelpittet

Comments

johnv created an issue. See original summary.

johnv’s picture

Issue summary: View changes
joelpittet’s picture

From the project page

Don't bother using this module if you're not also going to use http://drupal.org/project/memcache or http://drupal.org/project/redis

Are you using that with 5.2?

joelpittet’s picture

Title: Parse error: syntax error, unexpected T_STATIC due to PHP5.2 » Parse error: syntax error, unexpected T_STATIC
Version: 7.x-1.5 » 7.x-1.x-dev

Actually while I disagree with the support for 5.2 this feature is only available for PHP 5.5
https://3v4l.org/B0DuC

So in your case I'd suggest upgrading.

joelpittet’s picture

Status: Active » Needs review
StatusFileSize
new2.12 KB

I think this is the way we've done this before D8.

joelpittet’s picture

This still needs 5.3 for the late binding @see https://secure.php.net/get_called_class

johnv’s picture

Regarding #3.
I posted #2149793: Don't bother using this module ??.

I dont understand that opinion, since even on my dev machine this module greatly reduces db query load.

joelpittet’s picture

It's a quote from the homepage of this... I didn't write it nor do I maintain this module.

I'm trying to help solve the problem here. 5.2 doesn't have the feature these classes are using so may be ever so hard to fix it for 5.2 but my patch fixes 5.3 up.

Also you'd get much faster site going to php 5.3 or better anyways. @see http://www.lornajane.net/posts/2012/php-5-4-benchmarks

  • catch committed a13d0d9 on 7.x-1.x authored by joelpittet
    Issue #2619270 by joelpittet: Parse error: syntax error, unexpected...
catch’s picture

Status: Needs review » Fixed

Committed/pushed to 7.1-1.x, thanks!

ey’s picture

Shouldn't we also update the project page and indicate the new requirement of PHP version 5.3 or newer?

joelpittet’s picture

Thanks @catch. @pc-wurm that wouldn't hurt I don't think. What would be cool is if the project's PHP requirement could be read on to the page automatically on all project pages. But I guess that would be in the drupal.org/infra queues.

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.

RunePhilosof’s picture

Even with this patch, I couldn't get drush rr to complete.
I needed to disable the module, upgrade the files, then enable the module again.