4 class LineCommentMonoglot < Monoglot
6 def initialize(language, line_comment_tokens)
10 State.new(language, :code, :code),
11 State.new(language, :comment, :comment)
15 [ line_comment_tokens ].flatten.each_with_index do |token, index|
16 @transitions << Transition.new(language, token, :code, :comment, :to, false, index.to_s)
18 @transitions << Transition.new(language, '\n', :comment, :return, :from, false)