diff options
author | David Schultz <das@FreeBSD.org> | 2009-03-25 05:10:32 +0000 |
---|---|---|
committer | David Schultz <das@FreeBSD.org> | 2009-03-25 05:10:32 +0000 |
commit | e4c3a7fc88f7466a228104f3c43ef5f494295e95 (patch) | |
tree | 6d5dc77c91888f6828d8d9ee714938ac2b52462c /contrib | |
parent | 09b29530db6689afca2d2d8f90dfd2a7303249cd (diff) | |
download | src-e4c3a7fc88f7466a228104f3c43ef5f494295e95.tar.gz src-e4c3a7fc88f7466a228104f3c43ef5f494295e95.zip |
Merge an important change that I mistakenly left out when merging C99
inline function support. This should fix instances where gcc
spuriously reports the following error:
error: nested function 'foo' declared but never defined
Notes
Notes:
svn path=/head/; revision=190404
Diffstat (limited to 'contrib')
-rw-r--r-- | contrib/gcc/c-decl.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/contrib/gcc/c-decl.c b/contrib/gcc/c-decl.c index 7e4cffc7ae9b..64a6fa8fb85a 100644 --- a/contrib/gcc/c-decl.c +++ b/contrib/gcc/c-decl.c @@ -798,7 +798,9 @@ pop_scope (void) && DECL_ABSTRACT_ORIGIN (p) != p) TREE_ADDRESSABLE (DECL_ABSTRACT_ORIGIN (p)) = 1; if (!DECL_EXTERNAL (p) - && DECL_INITIAL (p) == 0) + && DECL_INITIAL (p) == 0 + && scope != file_scope + && scope != external_scope) { error ("nested function %q+D declared but never defined", p); undef_nested_function = true; |