rv = errorObject->Init(rep->ucmessage, newFileUni, rep->uclinebuf,
rv = errorObject->Init(NS_REINTERPRET_CAST(const PRUnichar*, rep->ucmessage), newFileUni, NS_REINTERPRET_CAST(const PRUnichar*, rep->uclinebuf),
Reporter(JSContext *cx, const char *message, JSErrorReport *rep){    nsresult rv;    /* Use the console service to register the error. */    nsCOMPtr<nsIConsoleService> consoleService        (do_GetService("mozilla.consoleservice.1"));    /*     * Make an nsIScriptError, populate it with information from this     * error, then log it with the console service.  The UI can then     * poll the service to update the JavaScript console.     */    nsCOMPtr<nsIScriptError>        errorObject(do_CreateInstance("mozilla.scripterror.1"));        if (consoleService != nsnull && errorObject != nsnull) {        /*         * Got an error object; prepare appropriate-width versions of         * various arguments to it.         */        nsAutoString fileUni;        fileUni.AssignWithConversion(rep->filename);        const PRUnichar *newFileUni = fileUni.ToNewUnicode();                PRUint32 column = rep->uctokenptr - rep->uclinebuf;        rv = errorObject->Init(rep->ucmessage, newFileUni, rep->uclinebuf,                               rep->lineno, column, rep->flags,                               "component javascript");        nsMemory::Free((void *)newFileUni);        if (NS_SUCCEEDED(rv)) {            rv = consoleService->LogMessage(errorObject);            if (NS_SUCCEEDED(rv)) {                // We're done!  Skip return to fall thru to stderr                // printout, for the benefit of those invoking the                // browser with -console.                // return;            }        }    }    /*     * If any of the above fails for some reason, fall back to     * printing to stderr.     */    fprintf(stderr, "JS Component Loader: %s %s:%d\n"            "                     %s\n",            JSREPORT_IS_WARNING(rep->flags) ? "WARNING" : "ERROR",            rep->filename, rep->lineno,            message ? message : "<no message>");}