Sha256: 5dbc6d5d82c1e0cdbec711289984acf0b6924c160ae1499eff48c3b5135b1cee

Contents?: true

Size: 283 Bytes

Versions: 49

Compression:

Stored size: 283 Bytes

Contents

module Ruby2JS
  class Converter

    # (break
    #   (int 1))

    handle :break do |n=nil|
      raise NotImplementedError, "break argument #{ n.inspect }" if n
      raise NotImplementedError, "break outside of loop" if @next_token == :return
      put 'break'
    end
  end
end

Version data entries

49 entries across 49 versions & 1 rubygems

Version Path
ruby2js-2.0.8 lib/ruby2js/converter/break.rb
ruby2js-2.0.7 lib/ruby2js/converter/break.rb
ruby2js-2.0.6 lib/ruby2js/converter/break.rb
ruby2js-2.0.5 lib/ruby2js/converter/break.rb
ruby2js-2.0.4 lib/ruby2js/converter/break.rb
ruby2js-2.0.3 lib/ruby2js/converter/break.rb
ruby2js-2.0.2 lib/ruby2js/converter/break.rb
ruby2js-2.0.1 lib/ruby2js/converter/break.rb
ruby2js-2.0.0 lib/ruby2js/converter/break.rb