Mercurial > hg > CbC > CbC_gcc
diff gcc/c-decl.c @ 102:fdc380f80c07
fix __rectype expression
author | Nobuyasu Oshiro <dimolto@cr.ie.u-ryukyu.ac.jp> |
---|---|
date | Mon, 20 Feb 2012 15:38:52 +0900 |
parents | 5c3ad79fc15b |
children | 46ee985e4f0e |
line wrap: on
line diff
--- a/gcc/c-decl.c Thu Feb 16 18:15:22 2012 +0900 +++ b/gcc/c-decl.c Mon Feb 20 15:38:52 2012 +0900 @@ -5155,6 +5155,16 @@ } } + +#ifndef noCbC + if ( declspecs->typespec_word == cts_CbC_rec ) + { + type = build_code_segment_type (type, NULL_TREE); + IS_RECTYPE(type) = 1; + } +#endif + + /* Now figure out the structure of the declarator proper. Descend through it, creating more complex types, until we reach the declared identifier (or NULL_TREE, in an absolute declarator). @@ -5636,13 +5646,6 @@ } case cdk_pointer: { -#ifndef noCbC - if ( declspecs->typespec_word == cts_CbC_rec ) - { - type = build_code_segment_type (type, NULL_TREE); - IS_RECTYPE(type) = 1; - } -#endif /* Merge any constancy or volatility into the target type for the pointer. */ @@ -5690,6 +5693,11 @@ type = build_pointer_type (type); +#ifndef noCbC + if ( declspecs->typespec_word == cts_CbC_rec ){ + IS_RECTYPE(type) = 1; + } +#endif /* Process type qualifiers (such as const or volatile) that were given inside the `*'. */ type_quals = declarator->u.pointer_quals;