Sha256: fff730f1704969a48afe52e03ff006dbe0b9f682d4c32403595c8cc639e93bfa
Contents?: true
Size: 557 Bytes
Versions: 24
Compression:
Stored size: 557 Bytes
Contents
#!/usr/bin/env ruby require 'rubygems' require 'bundler/setup' require 'benchmark/ips' require 'punchblock/translator/asterisk/channel' channel_string = 'abc123' channel = Punchblock::Translator::Asterisk::Channel.new('abc123') class Wrapper def initialize(string) @string = string end def to_s @string end end wrapper = Wrapper.new 'abc123' Benchmark.ips do |ips| ips.report("string nesting") { "SIP/#{channel_string}" } ips.report("wrapper nesting") { "SIP/#{wrapper}" } ips.report("delegate nesting") { "SIP/#{channel}" } end
Version data entries
24 entries across 24 versions & 1 rubygems