Hello,
Vladimir Ulchenko wrote:
> now what about general purpose scoped guard which is created and used > via ON_BLOCK_EXIT(SomeFunc,Type1 var1,Type2 var2,Type3 var3) and > ON_BLOCK_EXIT_OBJ(SomeObject,TSomeObject::MemberFunc,Type1 > param1,Type2 param2,Type3 param3) > > is it possible to implement those using say generics or something?
using Barry's code, that should be as simple as
// ----- begin MakeScopeNotifier(procedure begin SomeObject.MemberFunc(param1) end); ... end; // ----- ...
-- Moritz
"Hey, it compiles! Ship it!"