mirror of
https://github.com/haml/haml.git
synced 2022-11-09 12:33:31 -05:00
[Sass] [SCSS] Document sass/scss/script_parser.rb.
This commit is contained in:
parent
d2f8d14cb0
commit
f028f4c43c
1 changed files with 6 additions and 0 deletions
|
@ -1,8 +1,14 @@
|
|||
module Sass
|
||||
module SCSS
|
||||
# A subclass of {Sass::Script::Parser}
|
||||
# that can be used as a subcomponent of {SCSS::Parser}.
|
||||
# In particular, the parser doesn't raise an error
|
||||
# when there's more content in the lexer once lexing is done.
|
||||
class ScriptParser < Sass::Script::Parser
|
||||
private
|
||||
|
||||
# Instead of raising an error when the parser is done,
|
||||
# rewind the StringScanner so that it hasn't consumed the final token.
|
||||
def assert_done
|
||||
@lexer.unpeek!
|
||||
end
|
||||
|
|
Loading…
Add table
Reference in a new issue