× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.




Hi Justin

I think I understand what is going on.
In the source code as it stands both references to the subfield refer to
the statds DS so of course that works. But I think you intended the line
to be

st_mtime = FileStats.st_mtime;

and in that case, it still works and renames the subfield in statds.

The real clue comes from the fact that statds was originally declared in
a /INCLUDE

Refactoring does not currently process /INCLUDE and /COPY files. At this
point the refactoring has to be redone in every file. The challenge in
your example is, because the refactoring doesn't see the /include, it has
no idea that st_mtime is a subfield in the data structure referenced in the
LIKEDS. It just sees it as another dangling reference without a
definition.

This limitation is one of my next priorities but of course an RFE is always
helpful because I have many "next priorities".

Regards,

Edmund (E.H.)
Reinhardt

Technical Architect for Rational Developer for i




Phone: 1-905-413-3125 | Home: IBM
1-905-854-6195
E-mail: edmund.reinhardt@xxxxxxxxxx 8200 Warden Ave
RDi Community: ibm.biz/rdi_hub Markham, ON L6G 1C7
Find me on: LinkedIn: Canada
http://ca.linkedin.com/in/edmundreinhardt/









From: Justin Taylor <JUSTIN@xxxxxxxxxxxxx>
To: "Rational Developer for IBM i / Websphere Development Studio
Client for System i & iSeries" <wdsci-l@xxxxxxxxxxxx>
Date: 03/01/2017 04:48 PM
Subject: Re: [WDSCI-L] Refactor & Qualified DS
Sent by: "WDSCI-L" <wdsci-l-bounces@xxxxxxxxxxxx>



Here's a sample:
Ctl-opt
Debug(*Yes) Option(*SrcStmt: *NoDebugIO :*NoUnref) Optimize
(*Basic)
ExtBinInt(*Yes)
;

D p_statds s *
D statds ds Based(p_statds)
D st_mode 10u 0
D st_ino 10u 0
D st_nlink 5u 0
D st_pad 2a
D st_uid 10u 0
D st_gid 10u 0
D st_size 10i 0
D st_atime 10i 0
D st_mtime 10i 0
D st_ctime 10i 0
D st_dev 10u 0
D st_blksize 10u 0
D st_allocsize 10u 0
D st_objtype 12a
D st_codepage 5u 0
D st_reserved1 62a
D st_ino_gen_id 10u 0


//--------------------------------------------------------------------
// data structures

//--------------------------------------------------------------------
Dcl-ds FileStats likeDs(StatDs);

st_mtime = st_mtime;


*inLR = *on;
Return;


In the original code, the fixed-format code was in an /INCLUDE.






As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:
Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.