Sha256: 197cafd34d70a134a76c4dbd10389ce47d7336797615bf215b997d985519ac62

Contents?: true

Size: 233 Bytes

Versions: 3

Compression:

Stored size: 233 Bytes

Contents

module Basic101

  class AscFunction < Function

    def name
      'ASC'
    end

    def call(runtime, args)
      check_args args, [BasicString]
      value = args.first.eval(runtime)
      value.to_string.asc
    end

  end

end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
basic101-0.4.0 lib/basic101/asc_function.rb
basic101-0.2.0 lib/basic101/asc_function.rb
basic101-0.1.0 lib/basic101/asc_function.rb