Annotation of parser3/src/main/pa_exception.C, revision 1.13
1.13 ! parser 1: /** @file
! 2: Parser: exception class.
! 3:
! 4: Copyright (c) 2001 ArtLebedev Group (http://www.artlebedev.com)
! 5:
! 6: Author: Alexander Petrosyan <paf@design.ru> (http://design.ru/paf)
! 7: */
! 8: static const char *RCSId="$Id: pa_exception.C,v 1.12 2001/08/27 12:02:24 parser Exp $";
! 9:
! 10: #include <stdio.h>
! 11: #include <stdlib.h>
! 12:
! 13: #include "pa_common.h"
! 14: #include "pa_exception.h"
! 15:
! 16: void Exception::_throw(const String *atype, const String *acode,
! 17: const String *aproblem_source,
! 18: const char *comment_fmt, ...) const {
! 19: ftype=atype;
! 20: fcode=acode;
! 21: fproblem_source=aproblem_source;
! 22:
! 23: if(comment_fmt) {
! 24: va_list args;
! 25: va_start(args, comment_fmt);
! 26: vsnprintf(fcomment, MAX_STRING, comment_fmt, args);
! 27: va_end(args);
! 28: } else
! 29: fcomment[0]=0;
! 30:
! 31: int *p=(int *)(void *)&mark;
! 32: for(int i=0; i<sizeof(mark)/sizeof(int); i++)
! 33: printf("%08X,", *p++);
! 34: printf("\n");
! 35:
! 36: longjmp(mark, 1);
! 37: }
E-mail: