Skip to content

Commit 3c37826

Browse files
mgreterxzyfer
authored andcommitted
Fix Attribute Selector equal compare operator (#2350)
Fixes #2347
1 parent 3d73948 commit 3c37826

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

src/ast.cpp

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -661,10 +661,11 @@ namespace Sass {
661661
{
662662
if (Attribute_Selector_Ptr_Const w = Cast<Attribute_Selector>(&rhs))
663663
{
664-
return *this == *w;
664+
return is_ns_eq(rhs) &&
665+
name() == rhs.name() &&
666+
*this == *w;
665667
}
666-
return is_ns_eq(rhs) &&
667-
name() == rhs.name();
668+
return false;
668669
}
669670

670671
bool Pseudo_Selector::operator== (const Pseudo_Selector& rhs) const

0 commit comments

Comments
 (0)