std_csetjmp.h revision 169691
1251212Spfg// -*- C++ -*- forwarding header. 2219639Smm 3219639Smm// Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005 4219639Smm// Free Software Foundation, Inc. 5219639Smm// 6219639Smm// This file is part of the GNU ISO C++ Library. This library is free 7219639Smm// software; you can redistribute it and/or modify it under the 8219639Smm// terms of the GNU General Public License as published by the 9219639Smm// Free Software Foundation; either version 2, or (at your option) 10219639Smm// any later version. 11219639Smm 12219639Smm// This library is distributed in the hope that it will be useful, 13219639Smm// but WITHOUT ANY WARRANTY; without even the implied warranty of 14219639Smm// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 15219639Smm// GNU General Public License for more details. 16219639Smm 17219639Smm// You should have received a copy of the GNU General Public License along 18219639Smm// with this library; see the file COPYING. If not, write to the Free 19219639Smm// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, 20219639Smm// USA. 21219639Smm 22219639Smm// As a special exception, you may use this file as part of a free software 23219639Smm// library without restriction. Specifically, if other files instantiate 24219639Smm// templates or use macros or inline functions from this file, or you compile 25219639Smm// this file and link it with other files to produce an executable, this 26219639Smm// file does not by itself cause the resulting executable to be covered by 27219639Smm// the GNU General Public License. This exception does not however 28219639Smm// invalidate any other reasons why the executable file might be covered by 29219639Smm// the GNU General Public License. 30219639Smm 31219639Smm/** @file csetjmp 32219639Smm * This is a Standard C++ Library file. You should @c #include this file 33251212Spfg * in your programs, rather than any of the "*.h" implementation files. 34251212Spfg * 35251212Spfg * This is the C++ version of the Standard C Library header @c setjmp.h, 36251212Spfg * and its contents are (mostly) the same as that header, but are all 37251212Spfg * contained in the namespace @c std (except for names which are defined 38237021Spfg * as macros in C). 39219639Smm */ 40237021Spfg 41237021Spfg// 42237021Spfg// ISO C++ 14882: 20.4.6 C library 43237021Spfg// 44237021Spfg 45237021Spfg#ifndef _GLIBCXX_CSETJMP 46237021Spfg#define _GLIBCXX_CSETJMP 1 47237021Spfg 48237021Spfg#pragma GCC system_header 49237021Spfg 50237021Spfg#include <bits/c++config.h> 51237021Spfg#include <setjmp.h> 52237021Spfg 53237021Spfg// Get rid of those macros defined in <setjmp.h> in lieu of real functions. 54237021Spfg#undef longjmp 55237021Spfg 56237021Spfg// Adhere to section 17.4.1.2 clause 5 of ISO 14882:1998 57237021Spfg#ifndef setjmp 58237021Spfg#define setjmp(env) setjmp (env) 59237021Spfg#endif 60237021Spfg 61237021Spfg_GLIBCXX_BEGIN_NAMESPACE(std) 62237021Spfg 63237021Spfg using ::jmp_buf; 64237021Spfg using ::longjmp; 65237021Spfg 66237021Spfg_GLIBCXX_END_NAMESPACE 67237021Spfg 68237021Spfg#endif 69237021Spfg