Sha256: bb16d0aad1e194c74e0e34a692ff309e78bf65cae6501afefda5fc4d535c9b6d
Contents?: true
Size: 772 Bytes
Versions: 163
Compression:
Stored size: 772 Bytes
Contents
# frozen_string_literal: false require 'mkmf' have_func("rb_enc_raise", "ruby.h") have_func("rb_enc_interned_str", "ruby.h") # checking if String#-@ (str_uminus) dedupes... ' begin a = -(%w(t e s t).join) b = -(%w(t e s t).join) if a.equal?(b) $CFLAGS << ' -DSTR_UMINUS_DEDUPE=1 ' else $CFLAGS << ' -DSTR_UMINUS_DEDUPE=0 ' end rescue NoMethodError $CFLAGS << ' -DSTR_UMINUS_DEDUPE=0 ' end # checking if String#-@ (str_uminus) directly interns frozen strings... ' begin s = rand.to_s.freeze if (-s).equal?(s) && (-s.dup).equal?(s) $CFLAGS << ' -DSTR_UMINUS_DEDUPE_FROZEN=1 ' else $CFLAGS << ' -DSTR_UMINUS_DEDUPE_FROZEN=0 ' end rescue NoMethodError $CFLAGS << ' -DSTR_UMINUS_DEDUPE_FROZEN=0 ' end create_makefile 'json/ext/parser'
Version data entries
163 entries across 161 versions & 21 rubygems