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

Closed 14 years ago

#1004 closed defect (fixed)

inf is a number in TOL on linux

Reported by: Jorge Owned by: Jorge
Priority: high Milestone: Mantainance
Component: Kernel Version:
Severity: critical Keywords:
Cc: scanner, constant

Description

inf is considered a number in TOL when running on linux but not when running on windows.

The following code:

Real {
  WriteLn("inf="<<inf);
  Real inf = 2;
  Real b = 3;
  If(inf<b, WriteLn("2 < 3"),WriteLn("2 > 3") );
  inf
};

will output:

  • on linux: 2>3
  • on windows: 2<3

Change History (20)

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

Priority: highesthigh

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

Resolution: fixed
Status: newclosed

(In [3236]) Fixes #1004

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

(In [3237]) Fixes #1004

comment:4 Changed 14 years ago by Víctor de Buen Remiro

La sentencia

Real inf = 2;

debería dar un error.

Habría que comprobar si asa lo mismo con otros números especiales como nan

comment:5 Changed 14 years ago by Víctor de Buen Remiro

también sería bueno que en el interfaz salga resaltada como palabra clave inf

comment:6 Changed 14 years ago by Víctor de Buen Remiro

(In [3267]) Refs #1004

comment:7 Changed 14 years ago by Víctor de Buen Remiro

(In [3268]) Fixes #1004

comment:8 Changed 14 years ago by Víctor de Buen Remiro

(In [3269]) Refs #1004

comment:9 Changed 14 years ago by Víctor de Buen Remiro

Resolution: fixed
Status: closedreopened

Existen muchos problema de compatibilidad hacia atrás por lo que resulta demasiado complicado cambiar todo el código que utiliza variables llamadas inf, INF, Inf o cualquier otra combinación de mayúsculas y minúsculas.

comment:10 Changed 14 years ago by Víctor de Buen Remiro

Resolution: fixed
Status: reopenedclosed

(In [3271]) Fixes #1004

comment:11 Changed 14 years ago by Víctor de Buen Remiro

(In [3272]) Refs #1004

comment:12 Changed 14 years ago by Víctor de Buen Remiro

(In [3273]) Refs #1004

comment:13 Changed 14 years ago by Pedro Gea

Sería conveniente deshacer también el resaltado de esta palabra. Véase [3267]

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

Ya estaba hecho.

comment:15 Changed 14 years ago by Pedro Gea

(In [3280]) Se elimina el resaltado en tolbase de la palabra "inf".
Refs #1004

comment:16 Changed 14 years ago by Jorge

(In [3289]) refs #1004, el PutValue de "inf", "+inf", "-inf" debe resultar en un valor desconocido.

comment:17 Changed 14 years ago by Pedro Gea

Resolution: fixed
Status: closedreopened

Parece ser que de algún modo el problema persiste. Véase MMS#712.

comment:18 Changed 14 years ago by Pedro Gea

El problema puede estar relacionado con el comportamiento diferente de la sentencia:

Text FormatReal(1/0);

en los distintos operativos.

comment:19 Changed 14 years ago by Víctor de Buen Remiro

Owner: changed from Víctor de Buen Remiro to Jorge
Status: reopenedassigned

comment:20 Changed 14 years ago by Jorge

Resolution: fixed
Status: assignedclosed

(In [3683]) closes #1004, la representación Text de los infinitos 1/0 y -1/0 es evaluable en la gramática Real dando como resultado el Real correspondiente.

Note: See TracTickets for help on using tickets.