Merge pull request #1759 from brianmckenna/CES_FCN

parse projection functions
This commit is contained in:
Ward Fisher 2020-07-14 17:35:37 -06:00 committed by GitHub
commit cee0a9332d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 6 additions and 2 deletions

View File

@ -114,6 +114,7 @@ qualifyprojectionnames(DCEprojection* proj)
NCerror ncstat = NC_NOERR;
NClist* fullpath = nclistnew();
if (proj->discrim == CES_VAR) {
ASSERT((proj->discrim == CES_VAR
&& proj->var->annotation != NULL
&& ((CDFnode*)proj->var->annotation)->ocnode != NULL));
@ -129,6 +130,7 @@ fprintf(stderr,"qualify: %s -> ",
fprintf(stderr,"%s\n",
dumpprojection(proj));
#endif
}
nclistfree(fullpath);
return ncstat;
}
@ -138,6 +140,7 @@ static NCerror
qualifyprojectionsizes(DCEprojection* proj)
{
size_t i,j;
if (proj->discrim == CES_VAR) {
ASSERT(proj->discrim == CES_VAR);
#ifdef DEBUG
fprintf(stderr,"qualifyprojectionsizes.before: %s\n",
@ -168,6 +171,7 @@ fprintf(stderr,"qualifyprojectionsizes.before: %s\n",
fprintf(stderr,"qualifyprojectionsizes.after: %s\n",
dumpprojection(proj));
#endif
}
return NC_NOERR;
}

View File

@ -58,7 +58,7 @@ projection:
segmentlist
{$$=projection(parsestate,$1);}
| function
{$$=$1;}
{$$=projection(parsestate,$1);}
;
function:

View File

@ -1305,7 +1305,7 @@ yyreduce:
case 13:
#line 61 "dce.y" /* yacc.c:1646 */
{(yyval)=(yyvsp[0]);}
{(yyval)=projection(parsestate,(yyvsp[0]));}
#line 1310 "dcetab.c" /* yacc.c:1646 */
break;