Class: Furnace::AVM2::Tokens::SupplementaryCommentToken
- Inherits:
-
Code::SurroundedToken
- Object
- Code::SurroundedToken
- Furnace::AVM2::Tokens::SupplementaryCommentToken
- Defined in:
- lib/furnace-avm2/source/implementation_tokens/supplementary_comment_token.rb
Instance Method Summary collapse
-
#initialize(origin, content, children, options = {}) ⇒ SupplementaryCommentToken
constructor
A new instance of SupplementaryCommentToken.
- #text_before ⇒ Object
Constructor Details
#initialize(origin, content, children, options = {}) ⇒ SupplementaryCommentToken
Returns a new instance of SupplementaryCommentToken.
3 4 5 6 |
# File 'lib/furnace-avm2/source/implementation_tokens/supplementary_comment_token.rb', line 3 def initialize(origin, content, children, ={}) super(origin, children, ) @content = content end |
Instance Method Details
#text_before ⇒ Object
8 9 10 11 12 13 14 |
# File 'lib/furnace-avm2/source/implementation_tokens/supplementary_comment_token.rb', line 8 def text_before if @options[:commented] "* #{@content} * " else "/* #{@content} */ " end end |