Exception on Singleton


#1

e$B!!$5$5$@$G$9!#e(B

require ‘singleton’
class C
include Singleton
end
p C.instance

#=>
/home/ko1/ruby/trunk/lib/singleton.rb:109:in instance': undefined methodsynchronize’ for nil:NilClass (NoMethodError)
from …/trunk/test.rb:6:in `’

e$B!!$3$N$h$&$J%W%m%0%i%`$,F0$+$J$/$J$C$F$$$k$h$&$G$9!#B?J,!“e(Bivar2
e$B4X78$G!“e(B
Singleton e$B$G;H$&e(B @mutex e$B$H$$$&JQ?t$,e(B nil
e$B$K$J$C$F$$$k$N$G!”$=$NJU$Ke(B
e$BM}M3$,$”$k$s$8$c$J$$$+$H;W$$$^$9!#e(B

e$B!!$H$3$m$G!"$3$NJQ99$Oe(B test-all e$B$r9T$C$F!“e(Btest
e$B$,:G8e$^$GAv$i$J$$$H$$$&e(B
e$B$3$H$G%9%0$K5$$,$D$-$^$7$?!#e(Btest-all
e$B$O!”;d$NNOITB-$G$^$@$^$@$9$Y$Fe(B OK
e$B$K$O$J$C$F$$$^$;$s$,!"$H$j$"$($::G8e$^$GAv$j$-$k$3$H$O3NG’$7$F$$$^$9!#%Ge(B
e$B%0%l!<%I$N;n83$K$OMxMQ$G$-$k$+$H;W$$$^$9$N$G!"%3%_%C%HA0$K$43NG’D:$1$l$Pe(B
e$B$H;W$$$^$9!#e(B


#2

e$B!!$5$5$@$G$9!%e(B

SASADA Koichi wrote:

e$B!!$3$N$h$&$J%W%m%0%i%`$,F0$+$J$/$J$C$F$$$k$h$&$G$9!#B?J,!“e(Bivar2 e$B4X78$G!“e(B
Singleton e$B$G;H$&e(B @mutex e$B$H$$$&JQ?t$,e(B nil e$B$K$J$C$F$$$k$N$G!”$=$NJU$Ke(B
e$BM}M3$,$”$k$s$8$c$J$$$+$H;W$$$^$9!#e(B

e$B!!:G=i!$$3$NJU$Oe(B ivar2
e$B$N<BAu$,$^$:$$$N$+$J!$$H;W$C$?$s$G$9$,!$$A$g$C$He(B
e$B$h$/$o$+$j$^$;$s$G$7$?!%$J$s$H$J$/!$0U?^$7$?5sF0$K$J$C$F$$$k$h$&$J5$$b$7e(B
e$B$^$9!%e(B

e$B!!<BAu$,@5$7$$$H$7$F!$BP=h$H$7$F$O!$e(B

  1. Singleton e$B$N<BAu$rJQ$($k!Je(B@mutex e$B$re(B @mutex__
    e$B$K$9$k!$$J$I!Ke(B
  2. @_v e$B$G%/%i%9%m!<%+%k%$%s%9%?%s%9JQ?t$H$9$k$N$r$d$a$ke(B

e$B$K$J$k$+$H;W$$$^$9!%$I$&$7$?$b$s$G$7$g$&$+!%e(B1
e$B$NBP=h$GF0$/$3$H$O3NG’$7$^e(B
e$B$7$?!%e(B

e$B!!8D?ME*$K$O!$e(B@_v
e$B$N$h$&$J%$%s%9%?%s%9JQ?t$O4{$KBt;3$"$k$N$G!$e(B@_v e$B0J30$Ne(B
e$BABr;h$rLO:w$9$k!J$?$H$($P!$e(B@.v e$B$de(B @v!e$B!$e(B@v@
e$B$H$+!K$N$b$"$j$J$N$G$O$J$$$+e(B
e$B$J$H;W$&$N$G$9$,!$$I$&$G$7$g$&$+!%e(BMatze$B$K$C$-$G;6!97+$jJV$5$l$?OCBj$G!$$$e(B
e$B$^$5$iH?BP0U8+8@$&$J$h!$$H$$$&$3$H$J$N$+$b$7$l$^$;$s$,!%8D?ME
$K$Oe(B
@.v
e$B$,$$$$$G$9!%$G!$e(B$.v
e$B$,%9%l%C%I%m!<%+%kJQ?t!%e(B@v@e$B$He(B$v$e$B$NAH$b$$$$$+!%e(B


#3

e$B$^$D$b$He(B e$B$f$-$R$m$G$9e(B

In message “Re: [ruby-dev:30332] Re: exception on Singleton”
on Wed, 14 Feb 2007 15:58:19 +0900, SASADA Koichi removed_email_address@domain.invalid
writes:

|e$B!!e(B@v e$B$r%/%i%9%m!<%+%k%$%s%9%?%s%9JQ?t$K$9$k$H$$$&7o$r9M$($F$$$?$s$G$9e(B
|e$B$,!"%U%!%$%k%m!<%+%k$J$b$N$K$9$k$H$$$&$N$O$@$a$+$J$!!"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$&$3$H$,$d$j$E$i$/$J$j!"$^$:$$5$$b$7$^$9!#e(B

e$B!!$I$&$G$7$g$&$+!#e(B


#5

e$B!!$5$5$@$G$9!#e(B

e$B!!%/%i%9%m!<%+%k%$%s%9%?%s%9JQ?t$NBP0F$G$9!#e(B

e$B!!e(B@(v)
e$B$J$s$F$N$O%-%b%$$G$9$+$M$’!#$H$j$"$($:!":#$^$G=P$F$-$?$H$O;W$($Je(B
e$B$$JQ?tI=5-$@$H;W$$$^$9!#e(B

e$B!!$G!"e(B$(v)
e$B$G%9%l%C%I%m!<%+%kJQ?t!Je(BThread#[:v]e$B$HF1$8!)!K!#e(B


#6

e$B$^$D$b$He(B e$B$f$-$R$m$G$9e(B

In message “Re: [ruby-dev:30345] class local instance variable (was: Re:
exception on Singleton)”
on Thu, 15 Feb 2007 11:19:28 +0900, SASADA Koichi removed_email_address@domain.invalid
writes:

|e$B!!8D?ME*$K$O!"$J$k$Y$/$J$i8_49@-$,$"$C$?$[$&$,$$$$$J$!!"$H;W$C$F$$$^$9!#e(B
|e$B$3$NJQ99$G9,$;$K$J$k?M$,$I$l$/$i$$$$$k$N$+!"$"$s$^$jA[Dj$7$F$$$J$$$N$Ge(B

e$B!V$J$k$Y$/8_49@-!W$H$$$&E@$K$OH?BP$7$^$;$s$,!"8_49@-$N$?$a$Ke(B
e$B@_7W$r$f$,$a$k$N$O$b$C$H%@%a$@$H;W$C$F$$$^$9!#e(B

|e$B!!$H$3$m$G!“e(Btest/unit e$B$N%F%9%H$G!”%F%9%H;~$Ke(B @result e$B$H$$$&%$%s%9%?%s%9e(B
|e$BJQ?t$X!"%F%9%HMQ$K:n$C$?GI@8%/%i%9$+$i%"%/%;%9$7$h$&$H$7$F<:GT$7$F$$$^e(B
|e$B$9!#2?$+2sHr:v$O$J$$$+$H;W$C$Fe(B *eval e$B$r9M$($F$$?$s$G$9$,!";W$$$D$-$^$;e(B
|e$B$s$G$7$?!#%/%i%9%m!<%+%k%$%s%9%?%s%9JQ?t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$,$$$$$J$!!"$H;W$C$F$$$^$9!#e(B
e$B$3$NJQ99$G9,$;$K$J$k?M$,$I$l$/$i$$$$$k$N$+!"$"$s$^$jA[Dj$7$F$$$J$$$N$Ge(B
e$B!J$.$c$C$H$$$C$FIT9,$;$K$J$k?M$NA[A|$J$i=PMh$k$s$G$9$,!K!#e(B

e$B!!$H$3$m$G!“e(Btest/unit e$B$N%F%9%H$G!”%F%9%H;~$Ke(B @result
e$B$H$$$&%$%s%9%?%s%9e(B
e$BJQ?t$X!"%F%9%HMQ$K:n$C$?GI@8%/%i%9$+$i%"%/%;%9$7$h$&$H$7$F<:GT$7$F$$$^e(B
e$B$9!#2?$+2sHr:v$O$J$$$+$H;W$C$Fe(B *eval
e$B$r9M$($F$
$?$s$G$9$,!";W$$$D$-$^$;e(B
e$B$s$G$7$?!#%/%i%9%m!<%+%k%$%s%9%?%s%9JQ?t$X%"%/%;%9$9$k$?$a$N%j%U%l%/%7%ge(B
e$B%s%a%=%C%I$O@
$1$k$s$G$7$g$&$+!#e(B

e$B!!$H$j$"$($:!“e(B@_result e$B$re(B @v_result
e$B$N$h$&$K$7$F2r7h$7$?$s$G$9$,!”%F%9%He(B
e$B$N$?$a$K2D;k@-!J!)!K$r9-$2$k$N$OK\KvE>E]$@$J$!!"$H$$$&5$$,$7$F$$$^$9!#e(B


#8

e$B$^$D$b$He(B e$B$f$-$R$m$G$9e(B

In message “Re: [ruby-dev:30346] Re: class local instance variable”
on Thu, 15 Feb 2007 11:33:04 +0900, SASADA Koichi removed_email_address@domain.invalid
writes:

|e$B!!%/%i%9%m!<%+%k%$%s%9%?%s%9JQ?t$NBP0F$G$9!#e(B
|
|e$B!!e(B@(v) e$B$J$s$F$N$O%-%b%$$G$9$+$M$’!#$H$j$"$($:!":#$^$G=P$F$-$?$H$O;W$($Je(B
|e$B$$JQ?tI=5-$@$H;W$$$^$9!#e(B
|
|e$B!!$G!"e(B$(v) e$B$G%9%l%C%I%m!<%+%kJQ?t!Je(BThread#[:v]e$B$HF1$8!)!K!#e(B

e$BBP0F$,=P$k$N$O$9$P$i$7$$$3$H$@$H;W$$$^$9$,!“e(B@(v)e$B$G$R$H$D$NJQe(B
e$B?t$H8@$&$N$O$”$^$j$K$bH~$7$/$J$$!#%=%U%H%&%’%"9)3X$N4QE@$+$ie(B
e$B$O%=%U%H%&%’%“JQ99$N1F6A$r8BDjE*$K$9$k$?$a$G$-$k$@$1%9%3!<%We(B
e$B$N>.$5$$JQ?t$NMxMQ$r>)Ne$7$?$$$o$1$G$9$,!”$=$l$,e(B@(v)e$B$G$O$`$7e(B
e$B$m!V;H$&$J!W$H8@$C$F$k$h$&$J$b$N$G$7$g$&!#e(B


#9

e$B$^$D$b$He(B e$B$f$-$R$m$G$9e(B

In message “Re: [ruby-dev:30349] Re: class local instance variable”
on Thu, 15 Feb 2007 14:14:26 +0900, SASADA Koichi removed_email_address@domain.invalid
writes:

|e$B!!;d$N463P$@$H!":#$^$GJQ?tL>$N0lIt$H$7$FMxMQ2DG=$@$C$?e(B “" e$B$,!“FC<l$J5-e(B
|e$B9f$H$7$FG’<1$5$l$k$3$H$N$[$&$,!”$A$g$C$H$I$&$J$s$@$m$&!"$H46$8$^$7$?e(B
|e$B!Je(B"@
” e$B$G$R$H$D!"$@$+$i$3$l$K$O$"$?$i$J$$!"$H$$$&$3$H$+$b$7$l$^$;$se(B
|e$B$,!K!#46$8$GC}$C$F$b$7$g$&$,$J$$$+!#e(B@(v) e$B$@$H!"$J$s$H$J$/8BDjE*$J46$8$,e(B
|e$B$7$FNI$$$+$J!"$H;W$C$F@h$NEj9F$K$J$j$^$7$?!#e(B

e$BA0$K$b=q$$$?DL$j!V$A$g$C$H$I$&$J$s$@$m$&!W$H$$$&463P$rH]Dj$Oe(B
e$B$7$^$;$s$,!"Be0F$H$7$F$N!Ve(B@(v)e$B!W$K$O;?@.$G$-$^$;$s!#e(B

|e$B!!$A$J$_$K!“1dD9@~>e$G%V%m%C%/%m!<%+%kJQ?t$Ne(B pref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