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

#241 closed defect (fixed)

Click right botton in object inspector fails

Reported by: César Pérez Álvarez Owned by: Javier Portugal
Priority: highest Milestone:
Component: Interface Version: head
Severity: blocker Keywords:
Cc:

Description

I obtain this error when click right botton in object inspector:

can't read "ipNameGui(CONTENT)": no such element in array
can't read "ipNameGui(CONTENT)": no such element in array

while executing

"lindex $ipNameGui(CONTENT) 0"

(procedure "::TolInspector::ReadUserFunctions" line 34)
invoked from within

"::TolInspector::ReadUserFunctions"

(procedure "::TolInspector::PostVariable" line 23)
invoked from within

"::TolInspector::PostVariable 509 201"

(command bound to event)

Change History (3)

comment:1 Changed 20 years ago by César Pérez Álvarez

Actually the error only occurs with a piece of code. If we comile this:


FILE : untitled.tol
PURPOSE:


INCLUDES

Set Include(PathIniSadd(0));


FUNCTIONS


PROCEDURES

Real Cont = 0;
Set fun(Real n, Set acu)
{

Real (Cont := Cont+1);
Set (acu := acu << Copy(Cont) ?);
If(GT(Cont, 4), Empty, fun(n, acu))

};
Set g = fun(3, Copy(Empty));

Real Conta = 0;
Set funa(Real n)
{

Text WriteLn("<<1 "<<ObjectExist("Set", "acu"));


Set If(ObjectExist("Set", "acu"), Empty, Set acu = Empty);
Real (Conta := Conta+1);
Text WriteLn("<<2 "<<ObjectExist("Set", "acu"));
Set (acu := acu << Copy(Conta) ?);
If(GT(Conta, 4), Empty, funa(n))

};
Set ga= funa(3);

Set a = Empty;

The error related in this bug appears

comment:2 Changed 20 years ago by Javier Portugal

Status: newassigned

comment:3 Changed 20 years ago by Javier Portugal

Resolution: fixed
Status: assignedclosed

This code modifies object Empty, making it not 'Empty'. Definitions of GUI User
functions used objet Empty to express no arguments or no value list. And as it
wasn't empty, the were some errors.

Note: See TracTickets for help on using tickets.