Skip to content
This repository has been archived by the owner on Oct 15, 2020. It is now read-only.

n-api: enable napi_wrap() to work with any object #269

Closed
wants to merge 3 commits into from

Commits on May 31, 2017

  1. n-api: enable napi_wrap() to work with any object

    Change to inserting an external object into the wrapper object's
    prototype chain, instead of injecting an alternate `this` object
    in the constructor callback adapter. The latter approach didn't
    work in certain scenarios because the JSRT runtime still returned
    the original `this` object.
    
    And with this change, the setting and checking of the extension
    flag, which distinguished wrapper objects from external objects,
    can be removed. I was never happy with that abuse of the extension
    flag even when I coded it.
    
    Also removing the CallbackInfo.returnValue field which is not
    used anymore (since we switched to direct return values).
    jasongin committed May 31, 2017
    Configuration menu
    Copy the full SHA
    5df5646 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    1eed263 View commit details
    Browse the repository at this point in the history

Commits on Jun 2, 2017

  1. Address review feedback

    jasongin committed Jun 2, 2017
    Configuration menu
    Copy the full SHA
    d72d02f View commit details
    Browse the repository at this point in the history