libsass
libsass copied to clipboard
Nested decendent selector becomes unested (regresssion)
input.scss
From bootstrap 3
@mixin table-row-variant($state, $background) {
.table > thead > tr,
.table > tbody > tr,
.table > tfoot > tr {
> td.#{$state},
> th.#{$state},
&.#{$state} > td,
&.#{$state} > th {
background-color: $background;
}
}
}
@include table-row-variant(active, green);
Actual results
libsass 3.6.2 libsass 3.6.3
> td.active,
> th.active,
.table > thead > tr.active > td,
.table > thead > tr.active > th,
.table > tbody > tr.active > td,
.table > tbody > tr.active > th,
.table > tfoot > tr.active > td,
.table > tfoot > tr.active > th {
background-color: green;
}
Expected result
libsass 3.6.1
.table > thead > tr > td.active,
.table > thead > tr > th.active,
.table > thead > tr.active > td,
.table > thead > tr.active > th,
.table > tbody > tr.active > td,
.table > tbody > tr.active > th,
.table > tfoot > tr.active > td,
.table > tfoot > tr.active > th {
background-color: green;
}
version info: libsass-python Bad
$ sassc --version
sassc 0.19.4 (sass/libsass 3.6.3)
Bad
$ sassc --version
sassc 0.19.3 (sass/libsass 3.6.2)
Good
$ sassc --version
sassc 0.19.2 (sass/libsass 3.6.1)
Minimal reproduction case:
parent {
td,
&.#{active} {
foo: bar;
}
}
Sorry for the regression, was a small oversight on my side :( And unfortunately the specs didn't catch this one either ...
@mgreter Please add a spec to sass-spec that covers this (and follows the style guide).