Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- def change_local_a
- ObjectSpace.each_object(String) do |x|
- if x == "xyzzy"
- x.replace "plugh"
- end
- end
- end
- def afunction
- a = "xyzzy"
- puts a
- change_local_a
- puts a
- end
- afunction
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement