Proparse discussion


Another oddity

James has some code:

PROCEDURE DetermineMaximumDemandCharge :
DEFINE INPUT PARAMETER ip-CtpApplicationMeaningType LIKE ICMAS.CtpApplicationMeaningType.CtpApplicationMeaningType NO-UNDO.
DEFINE INPUT PARAMETER ip-Factor AS DECIMAL NO-UNDO.
DEFINE OUTPUT PARAMETER op-Usage AS DECIMAL NO-UNDO.
...
END PROCEDURE.


Proparse Null Pointer Exception

We think we have found a smoking gun for at least some categories of the Null Pointer Exception problem

2 21 FUNCTION fn-SAA-Complete RETURNS LOGICAL
2 22 (BUFFER ib-TIS FOR {&INC-TIS-TABLE}tt-TIS,
2 23 BUFFER ib-SAA FOR {&INC-SAA-TABLE}lb-Inc-SAA-StatusDescID) :

This from the listing to show the resolution of the parameters.

Is buffer arguments to functions something new?


LIKE

We are getting a lot of null pointer exceptions where the call stack points at this code in org.prorefactor.treeparser.Variable.assignAttributesLike(Variable.java:44)

public void assignAttributesLike(Primative likePrim) {
dataType = likePrim.getDataType();
className = likePrim.getClassName();
extent = likePrim.getExtent();
}

where 44 is the call to getDataType(). Does this mean that it is encountering a LIKE definition for a data type that is not defined, i.e., new syntax?


pdbname, ldbname, and alias

From our experience and looking at some of the sample code, it appears to me that Proparse is going to do everything in terms of the ldbname and the pdbname has no significance.

What is not clear to me is what role alias has here. I see the code to define aliases and I am using a modified version of that, but my experience is that aliases are used mostly for things like pointing to multiple DBs as DICTDB.

Does this mean that one should define an alias of DICTDB to the ldbname
which will be DICTDB? Is there a reason to define other aliases?


Bitness

Perhaps this is my ignorance of things .NET, but is there an issue about 32 bit vs 64 bit in using the Proparse DLLs?


Environment Could Not be Resolved

Struggling with my proparse instance. It was working last week and not sure what's changed, but in PDSOE (11.2.1) I'm getting reports that Environment could not be Resolved, and as soon as I Environment:instance(), my (Thomas's) program craps out with no error.


Tokenlister

I have been working on an updated version of Tokenlister, moving to OO and using the new syntax without the shim. I will confess that not being familiar with the old interface, there is a lot in Proparse.p that is obscure. But, I think I have done a reasonable job of working through the shift up to the point of the display node routine which looks like this:

  DEFINE INPUT PARAMETER theNode AS INTEGER NO-UNDO.

  DEFINE VARIABLE nodeType AS CHARACTER NO-UNDO.
  DEFINE VARIABLE child    AS INTEGER   NO-UNDO.
  ASSIGN child = parserGetHandle().

Use TTY for Runtime

With 11.5 PDSOE, I find that if I have the project and the run configuration with Use TTY for Runtime unchecked, Proparse works fine. But, if I have this flag checked, then it throws an error at the first reference to a Proparse .NET assembly. There is no error message, but the call stack points to the line with the first reference.

I have opened case 00313106 with Progress Tech Support as of 5/12/15, but thus far the support engineer seems unable to get Proparse to work in either mode. :{


backward

I am converting tokenlister to use the new API. It makes calls to proparse.p functions which make reference to the Backward class as in org.proparse.api.Backward. The Javadoc does not seem to include this class. What is its role and where can I find more about it?


New work

I've only had a few minutes here and there, but I'm working on a few things. I'm loading the Proparse svn repository into a git repository with all of the revision history (done). I'm copying over the changes made by Mike and Marian for v11 syntax (partly done). I'll load this new repository up to github as a replacement for the old svn repository. With those done, I'll be able to look at the TABLE-SCAN syntax needed by Thomas.


Syndicate content