Sha256: cc24afe49db15b032791c8ffd76788988ffd3541a7cffcc42df89df2b2a4cd98
Contents?: true
Size: 401 Bytes
Versions: 1
Compression:
Stored size: 401 Bytes
Contents
class Proc < `Function` %x{ Proc_prototype._isProc = true; } def self.new(&block) `if (block === nil) no_block_given();` block end def to_proc self end def call(*args) `this.apply(this._s, #{args})` end def to_proc self end def to_s "#<Proc:0x0000000>" end def lambda? `!!this.$lambda` end def arity `this.length - 1` end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
opal-0.3.20 | core/proc.rb |