Skip to content

Instantly share code, notes, and snippets.

@davidbalbert
Created June 26, 2012 23:11
Show Gist options
  • Save davidbalbert/3000005 to your computer and use it in GitHub Desktop.
Save davidbalbert/3000005 to your computer and use it in GitHub Desktop.
#!/bin/sh
make clean
make distclean
rm -rf ./build
set -e
autoconf || exit 125
(./configure --prefix=`pwd`/build/ && make && make install) || exit 125
build/bin/ruby /tmp/inner_method_test.rb
def foo
def bar
end
end
foo
if Object.instance_methods(false).include?(:bar)
puts "BAD. :bar is public"
exit(1)
end
puts "GOOD. :bar is private"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment