I figured out the solution. The FunctionTemplate itself should be set on the instance template rather than the function.
On Friday, February 5, 2016 at 10:54:23 AM UTC-8, [email protected] wrote: > > When I try to use Template::SetAccessorProperty, the arguments are not > passed into the FunctionCallbackInfo. > > On Friday, February 5, 2016 at 12:18:49 AM UTC-8, Jochen Eisinger wrote: >> >> You'd install the FunctionTemplate on the instance_tmpl as a getter of an >> accessor property >> >> hth >> -jochen >> >> On Fri, Feb 5, 2016 at 5:35 AM Zac Hansen <[email protected]> wrote: >> >>> >>> >>> On Thursday, February 4, 2016 at 12:44:39 PM UTC-8, [email protected] >>> wrote: >>>> >>>> This recent commit 6a118774 >>>> <https://github.com/v8/v8/commit/6a118774244d087b5979e9291d628a994f21d59d> >>>> breaks >>>> the ability to set functions as data properties on templates (ie. >>>> Template::Set will assert on a value argument that is a JSReceiver). To be >>>> more explicit, the following code no longer works: >>>> >>>> fn = FunctionTemplate::New(isolate, <some c++ binding>)->GetFunction(); >>>> fn->SetName(fn_name); >>>> instance_tmpl->Set(fn_name, fn); >>>> >>>> What is the appropriate mechanism to achieve this same functionality >>>> now? >>>> >>> -- >>> -- >>> v8-users mailing list >>> [email protected] >>> http://groups.google.com/group/v8-users >>> --- >>> You received this message because you are subscribed to the Google >>> Groups "v8-users" group. >>> To unsubscribe from this group and stop receiving emails from it, send >>> an email to [email protected]. >>> For more options, visit https://groups.google.com/d/optout. >>> >> -- -- v8-users mailing list [email protected] http://groups.google.com/group/v8-users --- You received this message because you are subscribed to the Google Groups "v8-users" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/d/optout.
