title: Generic way of identifying native functions in Node js
body: <p>Is there any general way to identify native functions in Node.js?</p>
  
  <p>For example, to test for a native function in the browser, I would use this -
  <code>
  function isNative(fn) {
      return (/{\s*[native code]\s*}/).test('' + fn);
  }
  </code></p>
  
  <p>Is there something similar we can use for detecting native Node.js functions like fs.readFile and so on?</p>
  
  <p>I guess one way would be to check to cache the functions available in the GLOBAL variable before the start of the program, is there a more elegant way though?</p>
  
  <p>Thanks!</p>