Skip to content
This repository was archived by the owner on Oct 24, 2025. It is now read-only.

Commit 7e0c0f3

Browse files
author
Aaron Leung
committed
Making selector parsing a little more permissive.
1 parent 648073b commit 7e0c0f3

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

document_parser.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -410,7 +410,7 @@ namespace Sass {
410410
if (lex< exactly<'&'> >()) {
411411
simp1 = context.new_Node(Node::backref, path, line, lexed);
412412
}
413-
else if (lex< alternatives< type_selector, universal > >()) {
413+
else if (lex< alternatives< type_selector, universal, string_constant, number > >()) {
414414
simp1 = context.new_Node(Node::simple_selector, path, line, lexed);
415415
}
416416
else {
@@ -450,7 +450,7 @@ namespace Sass {
450450

451451
Node Document::parse_simple_selector()
452452
{
453-
if (lex< id_name >() || lex< class_name >()) {
453+
if (lex< id_name >() || lex< class_name >() || lex< string_constant >() || lex< number >()) {
454454
return context.new_Node(Node::simple_selector, path, line, lexed);
455455
}
456456
else if (peek< exactly<':'> >(position)) {

0 commit comments

Comments
 (0)