Lines Matching defs:file
1313 PyObject *err_msg, PyObject *obj, PyObject *file)
1317 if (PyFile_WriteObject(err_msg, file, Py_PRINT_RAW) < 0) {
1320 if (PyFile_WriteString(": ", file) < 0) {
1325 if (PyFile_WriteString("Exception ignored in: ", file) < 0) {
1330 if (PyFile_WriteObject(obj, file, 0) < 0) {
1332 if (PyFile_WriteString("<object repr() failed>", file) < 0) {
1336 if (PyFile_WriteString("\n", file) < 0) {
1341 if (PyFile_WriteObject(err_msg, file, Py_PRINT_RAW) < 0) {
1344 if (PyFile_WriteString(":\n", file) < 0) {
1350 if (PyTraceBack_Print(exc_tb, file) < 0) {
1366 if (PyFile_WriteString("<unknown>", file) < 0) {
1373 if (PyFile_WriteObject(modulename, file, Py_PRINT_RAW) < 0) {
1378 if (PyFile_WriteString(".", file) < 0) {
1391 if (PyFile_WriteString("<unknown>", file) < 0) {
1396 if (PyFile_WriteObject(qualname, file, Py_PRINT_RAW) < 0) {
1404 if (PyFile_WriteString(": ", file) < 0) {
1407 if (PyFile_WriteObject(exc_value, file, Py_PRINT_RAW) < 0) {
1409 if (PyFile_WriteString("<exception str() failed>", file) < 0) {
1415 if (PyFile_WriteString("\n", file) < 0) {
1419 /* Explicitly call file.flush() */
1420 PyObject *res = _PyObject_CallMethodNoArgs(file, &_Py_ID(flush));
1435 PyObject *file = _PySys_GetAttr(tstate, &_Py_ID(stderr));
1436 if (file == NULL || file == Py_None) {
1442 Py_INCREF(file);
1444 err_msg, obj, file);
1445 Py_DECREF(file);
1605 /* Set file and line information for the current exception.
1772 or hit the end of the file; if pLastChar is \n,