close Warning: Can't synchronize with repository "(default)" (/var/svn/tolp does not appear to be a Subversion repository.). Look in the Trac log for more information.

Opened 20 years ago

Closed 20 years ago

Last modified 18 years ago

#216 closed defect (fixed)

Function "Text Argumets". It does not use the optional parameters

Reported by: rcsoto Owned by: danirus
Priority: lowest Milestone:
Component: Text Version: 1.1.2
Severity: minor Keywords:
Cc:

Description

The function "Text Argumets" it has two optional parameters:

Real argNum=0
Text infoType={"";"TYPE";"NAME"}

and it does not make case to any value that is indicated to him for these
arguments.

In addition, the description of the function, does not clarify since they are had to
use the mentioned parameters.

Example 1:

The following calls return the same
Text Arguments(TextFind);
Text Arguments(TextFind,0,"TYPE");
Text Arguments(TextFind,0,"NAME");

Example 2:

If in the second argument, we passed a value different from zero "0", the
function does not return anything
Text Arguments(TextFind,1);

Change History (3)

comment:1 Changed 20 years ago by danirus

Status: newassigned

comment:2 Changed 20 years ago by danirus

Resolution: fixed
Status: assignedclosed

This bug has been resolved.
The problem was a never initialize attribute argTable_ (BOperator class), and
after its initialization, there was a duplicate of that attribute in class
BStandardOperator, that hide the visibility of the first from BOperator class.
For BUserFunction instances, argTable_ must be initialize in
BUserFunction::Compile method. Their constructor methods haven't enough data to
initialize that attribute.

Now you can try:

_
Real f(Real p1, Text p2) { p1*p1 };
Text args1 = Arguments(f, 1, "NAME");
Text args2 = Arguments(Arguments, 2, "TYPE");

comment:3 Changed 18 years ago by Víctor de Buen Remiro

bug_file_loc: http://cvs.tol-project.org/viewcvs.cgi/tol_tests/tol/Bugzilla/bug_000216
Note: See TracTickets for help on using tickets.