PageRenderTime 4ms CodeModel.GetById 1ms app.highlight 1ms RepoModel.GetById 2ms app.codeStats 0ms

/scalate-jruby/src/main/resources/haml-3.0.25/lib/sass/scss/script_lexer.rb

http://github.com/scalate/scalate
Ruby | 15 lines | 11 code | 1 blank | 3 comment | 1 complexity | e90b8cf989a13e8b09b7e388b56e8438 MD5 | raw file
 1module Sass
 2  module SCSS
 3    # A mixin for subclasses of {Sass::Script::Lexer}
 4    # that makes them usable by {SCSS::Parser} to parse SassScript.
 5    # In particular, the lexer doesn't support `!` for a variable prefix.
 6    module ScriptLexer
 7      private
 8
 9      def variable
10        return [:raw, "!important"] if scan(Sass::SCSS::RX::IMPORTANT)
11        _variable(/(\$)(#{Sass::SCSS::RX::IDENT})/)
12      end
13    end
14  end
15end