Skip to content

Commit dd9e8a0

Browse files
committed
Error when stringifying empty lists for function calls
1 parent 57cb27a commit dd9e8a0

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

src/eval.cpp

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -797,6 +797,11 @@ namespace Sass {
797797
Env* env = environment();
798798
if (!env->has(full_name)) {
799799
if (!env->has("*[f]")) {
800+
for (Argument* arg : args->elements()) {
801+
if (List* ls = dynamic_cast<List*>(arg->value())) {
802+
if (ls->size() == 0) error("() isn't a valid CSS value.", c->pstate());
803+
}
804+
}
800805
args = static_cast<Arguments*>(args->perform(this));
801806
Function_Call* lit = SASS_MEMORY_NEW(ctx.mem, Function_Call,
802807
c->pstate(),

0 commit comments

Comments
 (0)