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

#246 closed defect (fixed)

TOL doesn't recognize local structs

Reported by: imendez Owned by: danirus
Priority: normal Milestone:
Component: Various Version: 1.1.2
Severity: normal Keywords:
Cc:

Description

I think this code shows that TOL doesn't recognize local structs:

Set s = For(1, 2, Set(Real n)
{

Struct AuxSt(Real Orden, Real Doble);
Set c = n, n*2 ?;
PutStructure("AuxSt", c)

});

because if you define the struct at the global level, everything works rigth:

Struct AuxSt(Real Orden, Real Doble);
Set s = For(1, 2, Set(Real n)
{

Set c = n, n*2 ?;
PutStructure("AuxSt", c)

});

Regards

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

Bug fixed.
Now we can create Struct's inside local scopes, but we must be aware that each
Struct has a type Set associated. Then we can not create two Set, one Struct and
one explicit Set, both of them with the same name.
_
(Only for developers Info)
Still remains a problem related with virtual method Mode() of BSyntaxObject.

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_000246
Note: See TracTickets for help on using tickets.