Message-ID: <002801c09131$90b3c760$9c11893e@oemcomputer> From: "Stephen Silver" To: "DJGPP Workers" Subject: setjmp.h - namespace std patch Date: Wed, 7 Feb 2001 18:12:40 -0000 MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 4.72.3110.1 X-MimeOLE: Produced By Microsoft MimeOLE V4.72.3110.3 Reply-To: djgpp-workers AT delorie DOT com Here's the setjmp.h patch. One slight complication here is that the C++ standard requires setjmp to be a macro, but DJGPP defines it as a function. I don't think this is really a problem, so rather than attempting to fix it, I've just made sure that setjmp is visible in the global namespace. Stephen *** include/setjmp.h.old Thu Jun 3 17:22:28 1999 --- include/setjmp.h Mon Feb 5 18:33:00 2001 *************** *** 5,8 **** --- 5,9 ---- #ifdef __cplusplus + namespace std { extern "C" { #endif *************** *** 41,45 **** --- 42,67 ---- #ifdef __cplusplus } + } #endif #endif /* !__dj_include_setjmp_h_ */ + + + #if defined(__cplusplus) && !defined(__dj_ENFORCE_ANSI_FREESTANDING) + + using std::setjmp; + + #ifndef __dj_via_cplusplus_header_ + + using std::longjmp; + using std::jmp_buf; + + #ifndef __STRICT_ANSI__ + + using std::sigjmp_buf; + using std::sigsetjmp; + using std::siglongjmp; + + #endif /* !__STRICT_ANSI__ */ + #endif /* !__dj_via_cplusplus_header_ */ + #endif /* __cplusplus && !__dj_ENFORCE_ANSI_FREESTANDING */