Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: rubinius/rubinius
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: ea419ec8c0be
Choose a base ref
...
head repository: rubinius/rubinius
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: b3606726338c
Choose a head ref

Commits on Apr 26, 2015

  1. Copy the full SHA
    bb2f37b View commit details

Commits on May 20, 2015

  1. Copy the full SHA
    05613d2 View commit details
  2. Merge pull request #3379 from d4rky-pl/master

    Clean bundler environment before running Homebrew during configuration
    brixen committed May 20, 2015
    Copy the full SHA
    3d752ba View commit details

Commits on May 21, 2015

  1. Copy the full SHA
    b23c23d View commit details

Commits on May 22, 2015

  1. Copy the full SHA
    96a0271 View commit details
  2. Updated .gitignore.

    brixen committed May 22, 2015
    Copy the full SHA
    621953b View commit details

Commits on May 23, 2015

  1. Copy the full SHA
    e5def49 View commit details
  2. implement specs for comparing a method defined via define_method and …

    …a method defined via def
    tak1n committed May 23, 2015
    Copy the full SHA
    a8397f5 View commit details

Commits on May 24, 2015

  1. Fix Method#==

    A Method defined via def has an executable attribute of class
    Rubinius::CompiledCode. On the other site a method defined via
    define_method has an executable attribute of class
    Rubinius::BlockEnvironment::AsMethod.
    
    Comparing method equality includes the comparison of executable
    equality.
    
    For comparing an executable of type Rubinius::BlockEnvironment::AsMethod
    against an executable of Rubinius::CompiledCode results in an error because it tries
    to access the block_env attribute on an Rubinius::CompiledCode object,
    which doesn't exist.
    
    This commit adds an early return like in Rubinius::CompiledCode#==
    tak1n committed May 24, 2015
    Copy the full SHA
    a97f197 View commit details
  2. Copy the full SHA
    cadc8ad View commit details
  3. Reintroduce Number arg specs for Regexp.new

    Like done in @7981f2c05671722dcf12f0d4f6bceb46cef29ff5
    tak1n committed May 24, 2015
    Copy the full SHA
    cbae591 View commit details
  4. Reintroduce TypeError raising for Regexp.new

    Regexp.new should raise a TypeError if the given Pattern is an
    Fixnum or Float object
    tak1n committed May 24, 2015
    Copy the full SHA
    a60dfb3 View commit details
  5. Merge pull request #3407 from rubinius/method-equality-3118

    Fix Method equalitiy
    jemc committed May 24, 2015
    Copy the full SHA
    73e862e View commit details
  6. Merge pull request #3408 from rubinius/regex-new-2959

    Regex new 2959
    jemc committed May 24, 2015
    Copy the full SHA
    ffa628e View commit details
  7. Vendored libsodium 1.0.3.

    brixen committed May 24, 2015
    Copy the full SHA
    d7f9443 View commit details
  8. Build libsodium.

    brixen committed May 24, 2015
    Copy the full SHA
    6cfbb77 View commit details

Commits on May 25, 2015

  1. Copy the full SHA
    e265991 View commit details
  2. Merge pull request #3410 from heftig/master

    Fix a __GNUC__ check to work with GCC 5
    brixen committed May 25, 2015
    Copy the full SHA
    92ba19d View commit details
  3. Merge pull request #3406 from rubinius/proc-curry-2951

     fix Proc#curry
    brixen committed May 25, 2015
    Copy the full SHA
    f1f0d75 View commit details
  4. Added mirror for Proc#curry. Improves #3406.

    There is still a lot of cruft in the Rubinius kernel but generally we use the
    mirror facility to implement methods that are not public Ruby API methods (and are
    generally C functions in MRI).
    brixen committed May 25, 2015
    Copy the full SHA
    93a80e0 View commit details
  5. Copy the full SHA
    0ec240a View commit details
  6. Copy the full SHA
    1857962 View commit details
  7. add 2.2 branch to ci

    tak1n committed May 25, 2015
    Copy the full SHA
    fc08625 View commit details
  8. Merge pull request #3413 from rubinius/add-2.2-to-ci

    Add 2.2 branch to travis
    Yorick Peterse committed May 25, 2015
    Copy the full SHA
    617ca4d View commit details

Commits on May 26, 2015

  1. Merge remote-tracking branch 'origin' into 1.8.7

    Conflicts:
    	configure
    	gems_list.txt
    	kernel/common/kernel.rb
    	kernel/common/load_order.txt
    	kernel/common/proc.rb
    	kernel/common/regexp.rb
    	kernel/delta/rubinius.rb
    	spec/ruby/core/method/shared/eql.rb
    	spec/ruby/core/proc/curry_spec.rb
    brixen committed May 26, 2015
    Copy the full SHA
    7d440f9 View commit details
  2. Copy the full SHA
    b360672 View commit details
Showing 474 changed files with 99,143 additions and 186 deletions.
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -79,6 +79,9 @@ Gemfile.installed.lock

/vm/test/ruby.h

# rubysl-digest installs this header
vm/include/capi/ruby/digest.h

/kernel/signature.rb

# Generated documentation
1 change: 1 addition & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -27,6 +27,7 @@ branches:
only:
- master
- 1.8.7
- 2.2
- /^v\d+\./

notifications:
25 changes: 23 additions & 2 deletions configure
Original file line number Diff line number Diff line change
@@ -450,6 +450,7 @@ class Configure

feature "execinfo", true
feature "vendor-zlib", false
feature "vendor-libsodium", true
feature "alloc-tracking", false
feature "fibers", true
feature "dtrace", false
@@ -570,8 +571,12 @@ class Configure
if which
config = File.join(which, "llvm-config")
elsif @darwin
out = `brew list llvm | grep '/llvm-config$'`
config = out.chomp if $?.success?
if macports?
config = macports_llvm_config
else
out = Bundler.with_clean_env { `brew list llvm | grep '/llvm-config$'` }
config = out.chomp if $?.success?
end
end
end

@@ -1151,6 +1156,11 @@ int main() { return tgetnum(""); }
@include_dirs << "#{@vendored_libdir}/zlib"
@lib_dirs << "#{@vendored_libdir}/zlib"
end

if @features["vendor-libsodium"].value
@include_dirs << "#{@vendored_libdir}/libsodium/src/libsodium/include"
@lib_dirs << "#{@vendored_libdir}/libsodium/src/libsodium/.libs/"
end
end

def detect_features
@@ -1216,6 +1226,10 @@ int main() { return tgetnum(""); }
@defines << "HAVE_INOTIFY"
end

if has_function("gettid", ["unistd.d", "sys/types.h"])
@defines << "HAVE_GETTID"
end

# glibc has useless lchmod() so we don't try to use lchmod() on linux
if !@linux and has_function("lchmod", ["sys/stat.h", "unistd.h"])
@have_lchmod = true
@@ -1257,6 +1271,12 @@ int main() { return tgetnum(""); }
end
end

unless @features["vendor-libsodium"].value
unless has_header("sodium.h")
failure "sodium.h is required"
end
end

unless has_header("openssl/ssl.h")
failure "openssl/ssl.h is required"
end
@@ -1535,6 +1555,7 @@ int main() { return tgetnum(""); }
:bsd => @bsd,
:linux => @linux,
:vendor_zlib => @features["vendor-zlib"].value,
:vendor_libsodium => @features["vendor-libsodium"].value,
:vm_release_h => @vm_release_h,
:bootstrap_gems => @bootstrap_gems,
:runtime_gems => @runtime_gems,
1 change: 1 addition & 0 deletions kernel/common/block_environment.rb
Original file line number Diff line number Diff line change
@@ -105,6 +105,7 @@ def ==(other)
# when given a Proc.
#
# The methods are equal if the BEs are equal.
return false unless other.kind_of? AsMethod

@block_env == other.block_env
end
4 changes: 4 additions & 0 deletions kernel/common/capi.rb
Original file line number Diff line number Diff line change
@@ -68,5 +68,9 @@ def self.rb_eval_string_wrap(str)
def self.clean_binding
return Rubinius::VariableScope.current
end

def self.rb_block_proc(env)
Rubinius::Mirror::Proc.from_block ::Proc, env
end
end
end
1 change: 1 addition & 0 deletions kernel/common/load_order.txt
Original file line number Diff line number Diff line change
@@ -4,6 +4,7 @@ autoload.rbc
module.rbc
binding.rbc
proc.rbc
proc_mirror.rbc
enumerable.rbc
enumerator.rbc
argf.rbc
16 changes: 3 additions & 13 deletions kernel/common/proc.rb
Original file line number Diff line number Diff line change
@@ -1,17 +1,7 @@
class Proc

def self.__from_block__(env)
Rubinius.primitive :proc_from_env

if Rubinius::Type.object_kind_of? env, Rubinius::BlockEnvironment
raise PrimitiveFailure, "Proc.__from_block__ primitive failed to create Proc from BlockEnvironment"
else
begin
env.to_proc
rescue Exception
raise ArgumentError, "Unable to convert #{env.inspect} to a Proc"
end
end
# The compiler must be fixed before this method can be removed.
Rubinius::Mirror::Proc.from_block self, env
end

def self.new(*args)
@@ -35,7 +25,7 @@ def self.new(*args)
end
end

block = __from_block__(env)
block = Rubinius::Mirror::Proc.from_block self, env

if block.class != self
block = block.dup
22 changes: 22 additions & 0 deletions kernel/common/proc_mirror.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
module Rubinius
class Mirror
class Proc < Mirror
def self.from_block(klass, env)
begin
return Rubinius.invoke_primitive :proc_from_env, env, klass
rescue Rubinius::Internal => exc
if Type.object_kind_of? env, BlockEnvironment
msg = "unable to create Proc from BlockEnvironment"
raise PrimitiveFailure, msg, exc
end
end

begin
env.to_proc
rescue Exception
raise ArgumentError, "Unable to convert #{env.inspect} to a Proc"
end
end
end
end
end
2 changes: 2 additions & 0 deletions kernel/common/regexp.rb
Original file line number Diff line number Diff line change
@@ -318,6 +318,8 @@ def initialize(pattern, opts=nil, lang=nil)
if pattern.kind_of?(Regexp)
opts = pattern.options
pattern = pattern.source
elsif pattern.kind_of?(Fixnum) or pattern.kind_of?(Float)
raise TypeError, "can't convert Fixnum into String"
elsif opts.kind_of?(Fixnum)
opts = opts & (OPTION_MASK | KCODE_MASK) if opts > 0
elsif opts
1 change: 0 additions & 1 deletion kernel/delta/rubinius.rb
Original file line number Diff line number Diff line change
@@ -320,5 +320,4 @@ def self.current_file
cs = Rubinius::ConstantScope.of_sender
return cs.absolute_active_path
end

end
16 changes: 16 additions & 0 deletions rakelib/blueprint.rb
Original file line number Diff line number Diff line change
@@ -161,6 +161,22 @@
files << zlib
end

if Rubinius::BUILD_CONFIG[:vendor_libsodium]
sodium = i.external_lib "vendor/libsodium" do |l|
l.cflags = ["-I#{src}/vendor/libsodium/src/libsodium/include"] + gcc.cflags
l.objects = [l.file("src/libsodium/.libs/libsodium.a")]
l.to_build do |x|
unless File.exist?("Makefile")
x.command "sh -c ./configure"
end

x.command make
end
end
gcc.add_library sodium
files << sodium
end

if Rubinius::BUILD_CONFIG[:windows]
winp = i.external_lib "vendor/winpthreads" do |l|
l.cflags = ["-I#{src}/vendor/winpthreads/include"] + gcc.cflags
162 changes: 0 additions & 162 deletions spec/ruby/core/proc/curry_spec.rb

This file was deleted.

12 changes: 12 additions & 0 deletions spec/ruby/core/regexp/new_spec.rb
Original file line number Diff line number Diff line change
@@ -12,3 +12,15 @@
describe "Regexp.new given a Regexp" do
it_behaves_like :regexp_new_regexp, :new
end

describe "Regexp.new given a Fixnum" do
it "raises a TypeError" do
lambda { Regexp.new(1) }.should raise_error(TypeError)
end
end

describe "Regexp.new given a Float" do
it "raises a TypeError" do
lambda { Regexp.new(1.0) }.should raise_error(TypeError)
end
end
10 changes: 10 additions & 0 deletions vendor/.gitignore
Original file line number Diff line number Diff line change
@@ -47,3 +47,13 @@ zlib/minigzip
zlib/minigzipsh
zlib/zconf.h
zlib/zlib.pc

# libsodium
libsodium/config.log
libsodium/config.status
libsodium/libsodium-uninstalled.pc
libsodium/libsodium.pc
libsodium/libtool
libsodium/src/libsodium/include/sodium/version.h
libsodium/**/Makefile
libsodium/**/.dirstamp
Loading