This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Patch, ObjC, ObjC++, Darwin] Remove "-fobjc-sjlj-exceptions"


The Objective C/C++ exceptions model is, currently, completely determined by the combination of runtime {gnu, next} and ABI {m32/V1, m64/V2}.

Thus, the "-fobjc-sjlj-exceptions" command line option is redundant and may be removed.
(note that trunk clang doesn't even accept the option, although xcode 4.6.3 still does).

The patch below removes the action of the flag, and produces a warning if the User puts it on a c/l.

This has been in use for some time on my *-darwin* systems and has been tested also on x86_64-linux. 
 
The option is apparently undocumented in the current User's manual, hence, there are no adjustments to documentation.

OK for trunk?
Iain

gcc/c-family:

	* c-opts.c (c_common_post_options): Remove handling of
	flag_objc_sjlj_exceptions.
	* c.opt (fobjc-sjlj-exceptions): Issue a warning if this
	option is given.

gcc:
	* config/darwin.c (darwin_override_options): Remove handling
	of flag_objc_sjlj_exceptions.

gcc/objc:

	* objc-act.c (objc_begin_try_stmt): Find the exceptions model
	in force from the runtime structure rather than a command line
	flag.
	* objc-gnu-runtime-abi-01.c (objc_gnu_runtime_abi_01_init): Set
	up the exceptions model and handle conflicting User selections.
	* objc-next-runtime-abi-02.c (objc_next_runtime_abi_02_init): 
	Likewise.
	* objc-next-runtime-abi-01.c (OBJC_SJLJ_EXCEPTIONS): Define true.
	(objc_next_runtime_abi_01_init): Set up the exceptions model and
	 handle conflicting User selections.
	(next_runtime_01_initialize, objc_build_exc_ptr, finish_try_stmt): 
	Use OBJC_SJLJ_EXCEPTIONS rather than a flag.
	* objc-runtime-hooks.h (objc_exceptions_model_t): New enum.
	(objc_runtime_hooks): Add exceptions model.

Attachment: remove-fobjc-sjlj-except-diff.txt
Description: Text document



Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]