Search code examples
xpcomxulrunner

What does NS_IMETHODIMP means in a XPCOM?


I'm having trouble to find the meaning of his NS_IMETHODIMP in a XPCOM, and I would like to understand this function's signature:

NS_IMETHODIMP myConfig::GetProperty(const char *name, char **_retval NS_OUTPARAM)
{
    //...
}

Solution

  • It depends on your platform, but in general it's just a #define for nsresult. On Windows, it's a bit different, and it's a #define for nsresult __stdcall.