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

Closed 18 years ago

Last modified 18 years ago

#441 closed defect (fixed)

Group function doesn't work upper 2^15=32768 elements

Reported by: Víctor de Buen Remiro Owned by: Víctor de Buen Remiro
Priority: highest Milestone:
Component: SetAlgebra Version: head
Severity: blocker Keywords:
Cc:

Description

Running this code only d1 and d2 are built.


Date SetMaxDate(Set setDate) { If(EQ(Card(setDate),1), setDate[1], Group("Max",setDate)) };
Set s1 = Dates(C, y2000, Succ(y2000,C,215-3));
Set s2 = Dates(C, y2000, Succ(y2000,C,2
15-2));
Set s3 = Dates(C, y2000, Succ(y2000,C,215-1));
Set s4 = Dates(C, y2000, Succ(y2000,C,2
15 ));
Date d1 = SetMaxDate(s1);
Date d2 = SetMaxDate(s2);
Date d3 = SetMaxDate(s3);

TOL displays next messages:

Warning: La función Group ha fallado en :
Group("", setDate)
ERROR: Fallo en la función "SetMinDate"
ERROR: d3 no se pudo crear.
Warning: La función Group ha fallado en :
Group("", setDate)
ERROR: Fallo en la función "SetMinDate"
ERROR: d4 no se pudo crear.
Date d4 = SetMaxDate(s4);

Change History (4)

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

Status: newassigned

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

Same problem happens with sets of Real

Real SetMaxReal(Set setReal) { If(EQ(Card(setReal),1), setReal[1], Group("Max",setReal)) };
Set s1 = Range(1,215-1,1);
Set s2 = Range(1,2
15 ,1);
Real d1 = SetMaxReal(s1);
Real d2 = SetMaxReal(s2);

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

Resolution: fixed
Status: assignedclosed

Bug has been fixed in CVS and a test is added in tol_tests/tol/Bugzilla/bug_000441

BTmpObject<Any>::card_ and NumArgs must be int instead of short

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