Project

General

Profile

Feature #2087

add support for extent vars/fields used with a PUT statement (stream-only feature)

Added by Constantin Asofiei about 11 years ago. Updated over 7 years ago.

Status:
Closed
Priority:
Normal
Start date:
03/08/2013
Due date:
% Done:

0%

billable:
No
vendor_id:
GCD

ca_upd20130308f.zip (5.84 KB) Constantin Asofiei, 03/08/2013 01:31 PM

ca_upd20130308h.zip (5.85 KB) Constantin Asofiei, 03/08/2013 02:58 PM

ges_upd20130308g.zip (4.71 KB) Greg Shah, 03/08/2013 05:25 PM

History

#1 Updated by Constantin Asofiei about 11 years ago

4GL allows extent vars/fields to be used in a PUT statement:

def var i as char extent 5.
def stream rpt.

output stream rpt to a.txt.

i[1] = "1".
i[2] = "2".
i[3] = "3".
i[4] = "4".
i[5] = "5".

put stream rpt i[1] i[2] i[3] i[4] i[5].
put stream rpt i.

find first person.
put stream rpt person.schedule.

output stream rpt close.

For such extent cases, the var/field needs to be expanded during post-parse-fixups. Note that dynamic extent vars can not be used in this case.

The attached update solves this, and is going through conversion regression testing.

#2 Updated by Constantin Asofiei about 11 years ago

Had a regression (didn't handle the case when the PUT used a subscripted field). Back in regression testing.

#3 Updated by Greg Shah about 11 years ago

Code Review:

Could we have added this as an additional case in annotations/array_expansion.rules?

#4 Updated by Constantin Asofiei about 11 years ago

I had a feeling there was another file where this was done already for some other cases, but my brain chose to ignore it. Yes, we can add it to array_expansion, to have all in one place. Although, on a second thought, I can't tell how easy will be to integrate it with the logic in array_expansion, not just copy-paste it from the the file to this one.

#5 Updated by Constantin Asofiei about 11 years ago

The good news is that 0308h.zip has passed conversion regression testing - no changes.

#6 Updated by Greg Shah about 11 years ago

Take a look at this. I think this should do the same thing.

#7 Updated by Constantin Asofiei about 11 years ago

Thanks, that did the trick. I'm putting it through conversion regression testing.

#8 Updated by Constantin Asofiei about 11 years ago

The ges_upd20130308g.zip update has passed conversion regression testing.

#9 Updated by Greg Shah about 11 years ago

  • Status changed from WIP to Closed

Checked in as bzr revision 10273.

#10 Updated by Greg Shah over 7 years ago

  • Target version changed from Milestone 4 to Conversion Support for Server Features

Also available in: Atom PDF