Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix inspect for quoted strings #2874

Merged
merged 1 commit into from
Apr 15, 2019
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 8 additions & 3 deletions src/fn_miscs.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -186,11 +186,16 @@ namespace Sass {
{
Expression* v = ARG("$value", Expression);
if (v->concrete_type() == Expression::NULL_VAL) {
return SASS_MEMORY_NEW(String_Quoted, pstate, "null");
return SASS_MEMORY_NEW(String_Constant, pstate, "null");
} else if (v->concrete_type() == Expression::BOOLEAN && v->is_false()) {
return SASS_MEMORY_NEW(String_Quoted, pstate, "false");
return SASS_MEMORY_NEW(String_Constant, pstate, "false");
} else if (v->concrete_type() == Expression::STRING) {
return Cast<String>(v);
String_Constant *s = Cast<String_Constant>(v);
if (s->quote_mark()) {
return SASS_MEMORY_NEW(String_Constant, pstate, quote(s->value(), s->quote_mark()));
} else {
return s;
}
} else {
// ToDo: fix to_sass for nested parentheses
Sass_Output_Style old_style;
Expand Down