freebsd-dev/contrib/gcc/cp
Pedro F. Giffuni 5bfc7db451 gcc: Add support for Apple's Block extension
Block objects [1] are a C-level syntactic and runtime feature. They
are similar to standard C functions, but in addition to executable
code they may also contain variable bindings to automatic (stack)
or managed (heap) memory. A block can therefore maintain a set of
state (data) that it can use to impact behavior when executed.

This port is based on Apple's GCC 5646 with some bugfixes from
Apple GCC 5666.3. It has some small differences with the support
in clang, which remains the recommended compiler.

Perhaps the most notable difference is that in GCC that __block
is not actually a keyword, but a macro. There will be workaround
for this issue in a near future. Other issues can be consulted in
the clang documentation [2]

For better compatiblity with Apple's GCC and llvm-gcc some related
fixes and features from Apple have been included. Support for the
non-standard nested functions in GCC is now off by default.

No effort was made to update the ObjC support since FreeBSD doesn't
carry ObjC in the base system, but some of the code crept in and
was more difficult to remove than to adjust.

Reference:
[1]
https://developer.apple.com/library/mac/documentation/Cocoa/Conceptual/Blocks/Articles/00_Introduction.html
[2]
http://clang.llvm.org/compatibility.html#block-variable-initialization

Obtained from:	Apple GCC 4.2
MFC after:	3 weeks
2014-01-05 00:43:28 +00:00
..
call.c gcc: Add support for Apple's Block extension 2014-01-05 00:43:28 +00:00
cfns.gperf
ChangeLog Revert r260073; small diff reduction wrt gcc43 and Apple GCC. 2014-01-02 13:53:53 +00:00
ChangeLog-1993
ChangeLog-1994
ChangeLog-1995
ChangeLog-1996
ChangeLog-1997
ChangeLog-1998
ChangeLog-1999
ChangeLog-2000
ChangeLog-2001
ChangeLog-2002
ChangeLog-2003
ChangeLog-2004
ChangeLog.apple gcc: Add support for Apple's Block extension 2014-01-05 00:43:28 +00:00
ChangeLog.gcc43 Revert r259619: 2013-12-20 18:16:02 +00:00
ChangeLog.tree-ssa
class.c gcc: Add support for Apple's Block extension 2014-01-05 00:43:28 +00:00
config-lang.in
cp-gimplify.c gcc: Add support for Apple's Block extension 2014-01-05 00:43:28 +00:00
cp-lang.c gcc: add femit-struct-debug support to reduce Reduce dwarf debug size 2013-11-16 01:16:24 +00:00
cp-objcp-common.c gcc: Add support for Apple's Block extension 2014-01-05 00:43:28 +00:00
cp-objcp-common.h gcc: Add support for Apple's Block extension 2014-01-05 00:43:28 +00:00
cp-tree.def gcc: Add support for label attributes and "unavailable" attribute. 2013-12-28 20:30:31 +00:00
cp-tree.h gcc: Add support for Apple's Block extension 2014-01-05 00:43:28 +00:00
cvt.c gcc: clean some warnings from -Wformat-security 2013-12-20 20:57:13 +00:00
cxx-pretty-print.c
cxx-pretty-print.h
decl2.c gcc: Add support for Apple's Block extension 2014-01-05 00:43:28 +00:00
decl.c gcc: Add support for Apple's Block extension 2014-01-05 00:43:28 +00:00
decl.h gcc: Add support for Apple's Block extension 2014-01-05 00:43:28 +00:00
dump.c gcc: Add support for label attributes and "unavailable" attribute. 2013-12-28 20:30:31 +00:00
error.c gcc: Add support for Apple's Block extension 2014-01-05 00:43:28 +00:00
except.c gcc: revert Rvalue references. 2013-12-20 18:09:34 +00:00
expr.c
friend.c
g++.1
g++spec.c Revert r260073; small diff reduction wrt gcc43 and Apple GCC. 2014-01-02 13:53:53 +00:00
init.c gcc: Add support for Apple's Block extension 2014-01-05 00:43:28 +00:00
lang-specs.h
lex.c
Make-lang.in gcc: more diff reductions against Apple GCC. 2013-12-20 14:56:52 +00:00
mangle.c gcc: Add support for Apple's Block extension 2014-01-05 00:43:28 +00:00
method.c gcc: small merges from upstream 2013-12-17 23:31:51 +00:00
name-lookup.c gcc: Add support for Apple's Block extension 2014-01-05 00:43:28 +00:00
name-lookup.h gcc: Add support for Apple's Block extension 2014-01-05 00:43:28 +00:00
NEWS
operators.def
optimize.c
parser.c gcc: Add support for Apple's Block extension 2014-01-05 00:43:28 +00:00
pt.c gcc: Add support for Apple's Block extension 2014-01-05 00:43:28 +00:00
ptree.c
repo.c
rtti.c gcc: merge upstream fix and new feature. 2013-12-20 16:01:02 +00:00
search.c
semantics.c gcc: Add support for Apple's Block extension 2014-01-05 00:43:28 +00:00
tree.c gcc: Add support for Apple's Block extension 2014-01-05 00:43:28 +00:00
typeck2.c
typeck.c gcc: Add support for Apple's Block extension 2014-01-05 00:43:28 +00:00