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 21 years ago

Closed 21 years ago

Last modified 18 years ago

#51 closed defect (fixed)

tol crash

Reported by: Jorge Owned by: danirus
Priority: high Milestone:
Component: Various Version: head
Severity: critical Keywords:
Cc:

Description

The following code make tol crash, for an indentical behaviour create a file
inside tol dir in development environment and insert the code given below.

Set result = Copy(Empty);

Set testIt (Text dir) {

Set dirSet = GetDir(dir);
Set result = EvalSet(dirSet[2], Set (Text subdir) {

Set If (subdir == "tests",

{Set makeTests(dir + "/tests")},
{Set testIt(dir + "/" + subdir)})

})

};

Set makeTests (Text dir) {

Set testFiles = GetDir(dir);
Set tolfiles = Select(testFiles[1], Real (Text name) {

Real If (GetFileExtension(name)=="tol", 1, 0)

});
Set tf = EvalSet(tolfiles, Text (Text name) {

Text file = dir + "/" + name;
Set lres = file? << Include(file);
Set (result := result << lres?);
file

})

};

Change History (4)

comment:1 Changed 21 years ago by danirus

Status: newassigned
Summary: tol crash tol crash

comment:2 Changed 21 years ago by Jorge

add the following line at the end of file to trigger the error:

Set testIt(".");

comment:3 Changed 21 years ago by danirus

Resolution: fixed
Status: assignedclosed

A solution for this crash, and many others that we always have had with := operator, has
just been deployed in Tol CVS. The problem appears when Tol variables used in the binary
operation := has different grammars.
This was happening because Tol programmers can create variables with same name and
different Types. The method to looking for an instance variable in Tol execution environment
is related also with this problem.

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