lib/sass/script/parser.rb in sass-3.5.0.pre.rc.1 vs lib/sass/script/parser.rb in sass-3.5.0
- old
+ new
@@ -5,29 +5,29 @@
# The parser for SassScript.
# It parses a string of code into a tree of {Script::Tree::Node}s.
class Parser
# The line number of the parser's current position.
#
- # @return [Fixnum]
+ # @return [Integer]
def line
@lexer.line
end
# The column number of the parser's current position.
#
- # @return [Fixnum]
+ # @return [Integer]
def offset
@lexer.offset
end
# @param str [String, StringScanner] The source text to parse
- # @param line [Fixnum] The line on which the SassScript appears.
+ # @param line [Integer] The line on which the SassScript appears.
# Used for error reporting and sourcemap building
- # @param offset [Fixnum] The character (not byte) offset where the script starts in the line.
+ # @param offset [Integer] The character (not byte) offset where the script starts in the line.
# Used for error reporting and sourcemap building
# @param options [{Symbol => Object}] An options hash; see
- # {file:SASS_REFERENCE.md#sass_options the Sass options documentation}.
+ # {file:SASS_REFERENCE.md#Options the Sass options documentation}.
# This supports an additional `:allow_extra_text` option that controls
# whether the parser throws an error when extra text is encountered
# after the parsed construct.
def initialize(str, line, offset, options = {})
@options = options
@@ -818,11 +818,12 @@
def interpolation_deprecation(interpolation)
return if @options[:_convert]
location = "on line #{interpolation.line}"
location << " of #{interpolation.filename}" if interpolation.filename
Sass::Util.sass_warn <<WARNING
-DEPRECATION WARNING #{location}: \#{} interpolation near operators will be simplified
-in a future version of Sass. To preserve the current behavior, use quotes:
+DEPRECATION WARNING #{location}:
+\#{} interpolation near operators will be simplified in a future version of Sass.
+To preserve the current behavior, use quotes:
#{interpolation.to_quoted_equivalent.to_sass}
You can use the sass-convert command to automatically fix most cases.
WARNING