pilif / sacy

Smarty Asset Compiler (warning: all branches but master are subject to force pushes)
http://pilif.github.com/sacy
MIT License
34 stars 12 forks source link

sacy.php will not compile on php 5.2 #10

Closed ghost closed 12 years ago

ghost commented 12 years ago

The use of CoffeeScript's namespace, Coffeescript\compile($js);, on line 294 in sacy_JavaScriptRenderHandler::processFile causes it to fail compilation on php 5.2 installs.

Also, the static keyword on line 266 in sacy_JavaScriptRenderHandler::willTransformType kills the compilation. It can be changed to self safely as nothing extends that class and is how that function is called elsewhere.

pilif commented 12 years ago

The coffe one, I won't be able to fix as I'm really not willing to patch third party libraries - especially not for something like supporting an unsupported version of the language.

The other one, I'll look into.

ghost commented 12 years ago

I submitted a pull request for all the issues I mentioned, including the coffee script issue. If the system is 5.3 and coffee script is installed, it will work. Other wise, if 5.2 it will not support coffeescript.

pilif commented 12 years ago

Merged your pull request (thanks a lot and sorry for being so late - lots of other stuff to do).