Skip to content

Commit d50ce73

Browse files
committed
Fix issue and compiler warnings
1 parent ae3dc50 commit d50ce73

File tree

4 files changed

+9
-4
lines changed

4 files changed

+9
-4
lines changed

src/ast.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,8 +56,8 @@ namespace Sass {
5656
case SASS_COMMA: return ", ";
5757
case SASS_SPACE: return " ";
5858
case SASS_DIV: return " / ";
59+
default: return "";
5960
}
60-
return "";
6161
}
6262

6363
/////////////////////////////////////////////////////////////////////////

src/ast_expressions.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -384,12 +384,13 @@ namespace Sass {
384384
case PLUS: strm << Character::$plus; break;
385385
case MINUS: strm << Character::$minus; break;
386386
case SLASH: strm << Character::$slash; break;
387+
default: break;
387388
}
388389
if (optype_ == NOT) {
389390
strm << Character::$space;
390391
}
391392
strm << operand_->toString();
392-
return strm.str();;
393+
return strm.str();
393394
}
394395

395396
/////////////////////////////////////////////////////////////////////////

src/ast_nodes.cpp

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -614,7 +614,7 @@ namespace Sass {
614614
else if (const List* list = isaList()) {
615615
if (list->empty()) return false;
616616
sass::vector<sass::string> result;
617-
if (list->separator() != SASS_SPACE) {
617+
if (list->separator() == SASS_COMMA) {
618618
for (auto complex : list->elements()) {
619619
List* cplxLst = complex->isaList();
620620
String* cplxStr = complex->isaString();
@@ -627,6 +627,9 @@ namespace Sass {
627627
else return false;
628628
}
629629
}
630+
else if (list->separator() == SASS_DIV) {
631+
return false;
632+
}
630633
else {
631634
for (auto compound : list->elements()) {
632635
String* cmpdStr = compound->isaString();

src/inspect.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -663,8 +663,9 @@ namespace Sass {
663663
return compressed ? "," : ", ";
664664
case SASS_DIV:
665665
return compressed ? "/" : " / ";
666+
default:
667+
return "";
666668
}
667-
return "";
668669
}
669670

670671
void Inspect::visitList(List* list)

0 commit comments

Comments
 (0)