Skip to content

Commit

Permalink
MDL-67114 scssphp: php74 compatibility local fixes
Browse files Browse the repository at this point in the history
Note they are already available upstream, versions 1.0.4 and up so,
in next upgrade they will be fixed.
  • Loading branch information
stronk7 committed Jan 3, 2020
1 parent 309912c commit a6e544e
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 1 deletion.
6 changes: 5 additions & 1 deletion lib/scssphp/Compiler.php
Original file line number Diff line number Diff line change
Expand Up @@ -2664,11 +2664,15 @@ protected function shouldEval($value)
* @param array $value
* @param boolean $inExp
*
* @return array|\ScssPhp\ScssPhp\Node\Number
* @return null|array|\ScssPhp\ScssPhp\Node\Number
*/
protected function reduce($value, $inExp = false)
{

if (is_null($value)) {
return null;
}

switch ($value[0]) {
case Type::T_EXPRESSION:
list(, $op, $left, $right, $inParens) = $value;
Expand Down
9 changes: 9 additions & 0 deletions lib/scssphp/moodle_readme.txt
Original file line number Diff line number Diff line change
Expand Up @@ -7,5 +7,14 @@ Import procedure:

- Copy all the files from the folder 'src' this directory.
- Copy the license file from the project root.
- Review the local changes defined below, if any. Reapply
them if needed. If already available upstream, please remove
them from the list.

Licensed under MIT, Copyright (c) 2015 Leaf Corcoran.

Currenly using 1.0.2 plus these local changes:

- MDL-67114 : Added basic compatibility with php 7.4. This corresponds to
upstream commit https://github.com/scssphp/scssphp/commit/66675c1553b7e9d7c480d8aaedbf7c72374647cf
that is available in scssphp >= 1.0.4

0 comments on commit a6e544e

Please sign in to comment.