<commit_before>/// Create a modifier for a module
///
/// @author [@esr360](http://twitter.com/esr360)
/// @access public
///
/// @param {string|list} $modifiers  - The modifier(s) which you wish to create
/// @param {string} $special [null] - Add special contextual options to modifier
/// @param {bool} $glue ['-'] - Desired modifier separator/glue
///
/// @example
///     @include module('button') {
///         @include modifier('large') {
///             ...
///         }
///     }
///
///     <div class="button-large">...</div>
@mixin modifier($modifiers, $special: null, $glue: $modifier-glue) {

    $this: &;
    $selectors: $this;

    $is-local-flex-type: variable-exists('config') and map-get($config, 'selector-type') == 'flex';
    $is-global-flex-type: not variable-exists('config') and $selector-type == 'flex';

    @if str-index(inspect($this), '.#{$module}') {
        @if $is-local-flex-type or $is-global-flex-type {
            $selectors: ();

            @for $i from 1 through length($this) {
                @if $i % 2 == 0 {
                    $selectors: append($selectors, nth($this, $i), comma);
                }
            }
        }
    }

    @at-root #{$selectors} {
        $this: &;
        $modifier-selectors: ();

        @each $modifier in $modifiers {
            @if $special == 'not' {
                $modifier-selectors: join($modifier-selectors, '#{$this}:not([class*="#{$glue}#{$modifier}"])', comma);<commit_msg>fixing issue with nested modifiers using node-sass<commit_after>/// Create a modifier for a module
///
/// @author [@esr360](http://twitter.com/esr360)
/// @access public
///
/// @param {string|list} $modifiers  - The modifier(s) which you wish to create
/// @param {string} $special [null] - Add special contextual options to modifier
/// @param {bool} $glue ['-'] - Desired modifier separator/glue
///
/// @example
///     @include module('button') {
///         @include modifier('large') {
///             ...
///         }
///     }
///
///     <div class="button-large">...</div>
@mixin modifier($modifiers, $special: null, $glue: $modifier-glue) {

    // BEGIN TOMFOOLERY https://github.com/sass/libsass/issues/2520
    $this: ();

    @each $selector in & {
        $selector: str-replace(inspect($selector), ' ', ', ');
        $selector: selector-parse($selector);
        $selector: list-remove-duplicates($selector);
        $selector: str-replace(inspect($selector), ', ', ' ');

        $this: append($this, $selector, comma);
    }

    $selectors: $this;
    // END TOMFOOLERY
    //$selectors: &;

    $is-local-flex-type: variable-exists('config') and map-get($config, 'selector-type') == 'flex';
    $is-global-flex-type: not variable-exists('config') and $selector-type == 'flex';

    @if str-index(inspect($this), '.#{$module}') {
        @if $is-local-flex-type or $is-global-flex-type {
            $selectors: ();

            @for $i from 1 through length($this) {
                @if $i % 2 == 0 {
                    $selectors: append($selectors, nth($this, $i), comma);
                }
            }
        }
    }

    @at-root #{$selectors} {
        $this: &;
        $modifier-selectors: ();

        @each $modifier in $modifiers {
            @if $special == 'not' {
                $modifier-selectors: join($modifier-selectors, '#{$this}:not([class*="#{$glue}#{$modifier}"])', comma);
{'fraction_non_alphanumeric': 0.20306513409961685, 'fraction_numerical': 0.006483937518420277, 'mean_word_length': 2.1838649155722325, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 7, 'https://': 1, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6320458', 'n_tokens_mistral': 1130, 'n_tokens_neox': 1064, 'n_words': 232}