summaryrefslogtreecommitdiff
path: root/sample/export.rb
blob: ea6c5aeaebe8d26dcabe0d89f67f9f6d3ac936db (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
# methos access permission
# output:
#	foobar
#	foo

class foo
  export(\printf)
end

def foobar
  print "foobar\n"
end

f = foo.new
#foo.unexport(\printf)
foo.export(\foobar)
f.foobar
f.printf "%s\n", foo