1
0
Fork 0
mirror of https://github.com/haml/haml.git synced 2022-11-09 12:33:31 -05:00

[Sass] Get rid of an unneeded method on Tree::Node.

This commit is contained in:
Nathan Weizenbaum 2009-12-24 01:28:01 -08:00
parent 66d512473c
commit fe3da64aaa
3 changed files with 2 additions and 10 deletions

View file

@ -446,7 +446,7 @@ SHORT
end
def parse_else(parent, line, text)
previous = parent.last
previous = parent.children.last
raise SyntaxError.new("@else must come after @if.") unless previous.is_a?(Tree::IfNode)
if text

View file

@ -155,6 +155,7 @@ module Sass
end
def dependencies(filename)
Files.tree_for(filename, options)
# TODO: This won't work in all cases for SCSS.
# We should store this info in the cache
# and then re-parse to get it if it's not there.

View file

@ -80,15 +80,6 @@ module Sass
@children << child
end
# Return the last child node.
#
# We need this because {Tree::Node} duck types as an Array for {Sass::Engine}.
#
# @return [Tree::Node] The last child node
def last
children.last
end
# Compares this node and another object (only other {Tree::Node}s will be equal).
# This does a structural comparison;
# if the contents of the nodes and all the child nodes are equivalent,