diff options
author | Andrés <andmarti@gmail.com> | 2021-03-06 15:46:10 -0300 |
---|---|---|
committer | Andrés <andmarti@gmail.com> | 2021-03-06 15:46:10 -0300 |
commit | 95e5f079a69e20ed1116d44b57400c1ccb76529b (patch) | |
tree | d29749e7f9d1fe3502547e6442fdaeb41a302d4d /src/gram.y | |
parent | 51019fd9201271cff5a88348c24974667dea0d8f (diff) |
work on issue #451
Diffstat (limited to 'src/gram.y')
-rwxr-xr-x | src/gram.y | 11 |
1 files changed, 11 insertions, 0 deletions
@@ -321,6 +321,7 @@ token S_YANKCOL %token K_VLOOKUP %token K_INDEX %token K_STINDEX +%token K_GETENT /* token K_AUTO token K_AUTOINSERT @@ -798,6 +799,16 @@ term: var { $$ = new_var(O_VAR, $1); } | '@' K_FIXED term { $$ = new('f', $3, ENULL); } | '(' '@' K_FIXED ')' term { $$ = new('F', $5, ENULL); } + | '@' K_GETENT '(' NUMBER ',' NUMBER ')' { + struct ent_ptr ep; + ep.vp = lookat($4, $6); + ep.vf = 0; + $$ = new(GETENT, new_var(O_VAR, ep), ENULL); + + // Work on issue #451. + // @sum(A0:@getent(@lastrow, 2)) + // @sum(A0:@getent("A",@lastrow)) + } | '@' K_SUM '(' var_or_range ')' { $$ = new(SUM, new_range(REDUCE | SUM, $4), ENULL); } | '@' K_SUM '(' range ',' e ')' |