chiark
/
gitweb
/
~mdw
/
mLib
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Add lots of references to manual pages, and fix a typo.
[mLib]
/
exc.c
diff --git
a/exc.c
b/exc.c
index 7bdc15f8d01b163355665b0ccdb7629378f9f0f7..0b5cf3ed87f4fdb1560da2f17f78742fc9536829 100644
(file)
--- a/
exc.c
+++ b/
exc.c
@@
-1,6
+1,6
@@
/* -*-c-*-
*
/* -*-c-*-
*
- * $Id: exc.c,v 1.
3 1999/05/06 19:51:35
mdw Exp $
+ * $Id: exc.c,v 1.
5 1999/05/19 20:27:11
mdw Exp $
*
* Structured exception handling in C
*
*
* Structured exception handling in C
*
@@
-30,6
+30,13
@@
/*----- Revision history --------------------------------------------------*
*
* $Log: exc.c,v $
/*----- Revision history --------------------------------------------------*
*
* $Log: exc.c,v $
+ * Revision 1.5 1999/05/19 20:27:11 mdw
+ * Change naming to match newer mLib conventions.
+ *
+ * Revision 1.4 1999/05/17 20:35:30 mdw
+ * Output uncaught exception types in hex, because they're easier to
+ * translate that way.
+ *
* Revision 1.3 1999/05/06 19:51:35 mdw
* Reformatted the LGPL notice a little bit.
*
* Revision 1.3 1999/05/06 19:51:35 mdw
* Reformatted the LGPL notice a little bit.
*
@@
-53,7
+60,7
@@
__exc_hnd *__exc_list = 0;
/*----- Functions ---------------------------------------------------------*/
/*----- Functions ---------------------------------------------------------*/
-/* --- @
exc__
duff@ --- *
+/* --- @duff@ --- *
*
* Arguments: @exc_extype type@ = type of duff exception
* @exc_exval val@ = extra data supplied
*
* Arguments: @exc_extype type@ = type of duff exception
* @exc_exval val@ = extra data supplied
@@
-63,18
+70,18
@@
__exc_hnd *__exc_list = 0;
* Use: Default handler when everything goes wrong.
*/
* Use: Default handler when everything goes wrong.
*/
-static void
exc__
duff(exc_extype type, exc_exval val)
+static void duff(exc_extype type, exc_exval val)
{
{
- fprintf(stderr, "fatal error: uncaught exception (type = %l
u
)\n", type);
+ fprintf(stderr, "fatal error: uncaught exception (type = %l
x
)\n", type);
abort();
}
abort();
}
-/* --- @
exc__
duffproc@ --- *
+/* --- @duffproc@ --- *
*
* Current handler when there are no more exceptions left.
*/
*
* Current handler when there are no more exceptions left.
*/
-static exc__uncaught
exc__duffproc = exc__
duff;
+static exc__uncaught
duffproc =
duff;
/* --- @exc_uncaught@ --- *
*
/* --- @exc_uncaught@ --- *
*
@@
-87,9
+94,9
@@
static exc__uncaught exc__duffproc = exc__duff;
exc__uncaught exc_uncaught(exc__uncaught proc)
{
exc__uncaught exc_uncaught(exc__uncaught proc)
{
- exc__uncaught p =
exc__
duffproc;
+ exc__uncaught p = duffproc;
if (proc)
if (proc)
-
exc__
duffproc = proc;
+ duffproc = proc;
return (p);
}
return (p);
}
@@
-142,7
+149,7
@@
void __exc_rethrow(exc_extype type, exc_exval val)
{
__exc_hnd *p = __exc_list;
if (!p)
{
__exc_hnd *p = __exc_list;
if (!p)
-
exc__
duffproc(type, val);
+ duffproc(type, val);
p->type = type;
p->val = val;
__exc_list = p->next;
p->type = type;
p->val = val;
__exc_list = p->next;