You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@stdcxx.apache.org by "Martin Sebor (JIRA)" <ji...@apache.org> on 2007/11/28 06:20:44 UTC

[jira] Updated: (STDCXX-240) #define _RWSTD_NO_EXCEPTIONS when exceptions are disabled via command line option

     [ https://issues.apache.org/jira/browse/STDCXX-240?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Martin Sebor updated STDCXX-240:
--------------------------------

    Priority: Minor  (was: Major)
     Summary: #define _RWSTD_NO_EXCEPTIONS when exceptions are disabled via command line option  (was: [HP aCC] #define _RWSTD_NO_EXCEPTIONS when __HPACC_NOEH is on)

gcc #defines the macro __EXCEPTIONS when C++ exceptions are enabled. The macro is #undefined when -fno-exceptions is used on the command line. See: http://gcc.gnu.org/onlinedocs/cpp/Common-Predefined-Macros.html

When using gcc we should key in on this macro, similarly to checking __HPACC_NOEH when using HP aCC. It's likely that other compilers have similar macros that we might want to treat similarly.

Making this a general enhancement (as opposed to one specific to just HP aCC) but bumping down Priority to Minor.

> #define _RWSTD_NO_EXCEPTIONS when exceptions are disabled via command line option
> ---------------------------------------------------------------------------------
>
>                 Key: STDCXX-240
>                 URL: https://issues.apache.org/jira/browse/STDCXX-240
>             Project: C++ Standard Library
>          Issue Type: Improvement
>          Components: Build
>    Affects Versions: 4.1.2, 4.1.3, 4.1.4
>            Reporter: Martin Sebor
>            Assignee: Travis Vitek
>            Priority: Minor
>             Fix For: 4.2.1
>
>
> Moved from the Rogue Wave bug tracking database:
> Class/File: stdcomp.h
> Fix Priority: Can Fix
> Long Description: 
>   *** Dec 1 1999 6:03PM *** sebor ***
> A request for enhancement.
> Subject: define RWSTD_NO_EXCEPTIONS when __HPACC_NOEH is
> Date: Wed, 01 Dec 1999 17:11:36 -0800
> From: Chichiang Wan <wa...@cup.hp.com>
> Organization: California Language Labs
> To: oemsupport <oe...@roguewave.com>
> CC: dhandly@cup.hp.com, wanc_at_hp <wa...@cup.hp.com>
> aCC has an option +noeh.  When it is provided, __HPACC_NOEH will be
> defined.  It would be nice for users to need to only use +noeh.  For
> that,  
> RWSTD_NO_EXCEPTIONS needs to be defined conditionally. 
> =========================================================
> $ cat test.C
> #include <string>
> $ aCC +noeh -c test.C
> Error 46: "/opt/aCC/include/memory", line 493 # Exception handling is 
> not
>     enabled (do not use the +noeh flag to aCC).
>       RWSTD_THROW_NO_MSG(tmp == 0, bad_alloc);
> -- Chichiang
> ****Modified By: sebor @ May 29, 2000 10:28:25 PM****
> We should do this AND test it -- not just on aCC but in general with all compilers that support this feature.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.