From: SASADA Koichi Date: 2013-08-20T22:25:09+09:00 Subject: [ruby-core:56758] Re: [ruby-trunk - Feature #8804] ONCE syntax (2013/08/20 19:30), trans (Thomas Sawyer) wrote: > Also, can it take an optional key argument? > > def ONCE(k=nil,&b) > raise unless block_given? > ONCE_MUTEX.synchronize{ > key = k || caller(3, 1)[0] I assume that ONCE is keyword like BEGIN{} and END{}. And key will be a special key provided by compiler. Completely same feature as /#{...}/o. -- // SASADA Koichi at atdot dot net