Class: Minjs::ECMA262::SingleLineComment
Instance Method Summary
collapse
Methods inherited from Literal
#lt?, #priority, #to_exp?
Methods inherited from Base
#add_remove_paren, #concat, #deep_dup, #replace, #to_s
Constructor Details
Returns a new instance of SingleLineComment.
801
802
803
|
# File 'lib/minjs/ecma262/lit.rb', line 801
def initialize()
@comment =
end
|
Instance Method Details
#==(obj) ⇒ Object
808
809
810
811
|
# File 'lib/minjs/ecma262/lit.rb', line 808
def ==(obj)
self.class == obj.class and
@comment == obj.
end
|
#to_js(options) ⇒ Object
813
814
815
|
# File 'lib/minjs/ecma262/lit.rb', line 813
def to_js(options)
"//#{@comment}"
end
|
#traverse(parent, &block) ⇒ Object
805
806
|
# File 'lib/minjs/ecma262/lit.rb', line 805
def traverse(parent, &block)
end
|
817
818
819
|
# File 'lib/minjs/ecma262/lit.rb', line 817
def ws?
true
end
|