× 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.




Chuck,

Thank you for your response. Until now I did not consider retrieving the debug view from the compiled object. That is an interesting idea. But honestly I do not want to go this way, because the goal is to open the RPGUnit test case (that failed working) for edit mode in the LPEX editor. Hence I need to map the overall source line number (option = *NOSRCSTMT) or the source sequence number (option = *SRCSTMT) to the row number of the source member.

Thank you also for pointing out the stream file problem. I did not yet spend any thoughts on stream files, because we still use source members.

In fact I like the idea of improving the QSYSEditableRemoteSourceFileMember API to do the required mapping. Maybe it was even better if IBM would change the QWVRCSTK API to return the row number of the source to avoid mapping at all. Actually that is what we need for stream files. Right?

For now I think I stay with the current solution, knowing, that it is not perfect.

Regards,

Thomas.

-----Ursprüngliche Nachricht-----
Von: WDSCI-L [mailto:wdsci-l-bounces@xxxxxxxxxxxx] Im Auftrag von CRPence
Gesendet: Donnerstag, 11. Dezember 2014 17:28
An: wdsci-l@xxxxxxxxxxxx
Betreff: Re: [WDSCI-L] How to map statement number of QWVRCSTK API to source sequence number?

On 11-Dec-2014 01:41 -0600, Thomas Raddatz wrote:

Does someone have a clever idea how to map the statement identifier
returned by the "Retrieve Call Stack (QWVRCSTK) API" to the source
line number of the source member?

I am not sure _how to get there from here_, but the following may assist in finding a path:

When using the green-screen debugger Start Debug (STRDBG), within the Display Module Source, issue F19=Left; the Source Sequence (SRCSEQ) and Source Date (SRCDAT) are shown [at least given the /source/ was derived from Source Physical File Member vs STMF, but the identity of the\which member is not there]. AFaIK that information comes from the Statement View Text produced for a debug-capable executable, and the information is there irrespective the choice of Source Statement Option that is specified on OPTION(); IIRC any Debug View (DBGVIEW) other than *NONE ensures that effect. There are Debug APIs that give access to that and other "debug views". IIRC there is also a Text View which is more directly the original source member(s).?

<<SNIP>> great if would not have to scan the source member and if
would work for *NOSRCSTMT, too.

Even with the SrcSeq available from a [Statement] Debug View, that value still would need to be translated into a RRN, and still would be an effective scan; e.g. select rrn(srcf) into :line_nbr from srcMbr where srcseq=:srcseq_from_dbg_view

I infer that statement attempts to imply "It would be great if the Edit method could\might be enhanced to accept a SrcSeq value that is then used by that method to locate the corresponding RRN\line-number [which is the current input]; i.e. a means to avoid, for anyone wanting that capability, from themselves having to code the scanning to locate the desired line number.

--
Regards, Chuck
--
This is the Rational Developer for IBM i / Websphere Development Studio Client for System i & iSeries (WDSCI-L) mailing list To post a message email: WDSCI-L@xxxxxxxxxxxx To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/wdsci-l
or email: WDSCI-L-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives at http://archive.midrange.com/wdsci-l.

--
IMPORTANT NOTICE:
This email is confidential, may be legally privileged, and is for the
intended recipient only. Access, disclosure, copying, distribution, or
reliance on any of it by anyone else is prohibited and may be a criminal
offence. Please delete if obtained in error and email confirmation to the sender.

As an Amazon Associate we earn from qualifying purchases.

This thread ...

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.