Tíquete #20056

Illegal result of cast.

: 2009-12-30 00:25 Última Atualização: 2010-03-05 23:59

Relator:
Dono:
Tipo:
Estado:
Fechado
Componente:
Marcos:
Prioridade:
9 - Highest
Gravidade:
9 - Highest
Resolução:
Fixed
Arquivo:
Nenhum

Details

Cast result of float -> int is incorrect.

public class FloatCastTest
{
  public static void main(String[] args) throws Exception
  {
    float f = Integer.MAX_VALUE + 0.0f;
    int i = (int) f;
    System.out.println("f=" + f + " i=" + i);
  }
}

Results:

f=2.1474836E9 i=-2147483648

Ticket History (3/4 Histories)

2009-12-30 00:25 Updated by: freebeans
  • New Ticket "Illegal result of cast." created
2009-12-30 00:25 Updated by: freebeans
  • Gravidade Update from 5 - Medium to 9 - Highest
2010-02-02 01:46 Updated by: freebeans
  • Resolução Update from Nenhum to Fixed
  • Marco Update from (Nenhum) to jvm0.4.8
Comentário

Fixed f2i, d2i, d2f, d2l instructions.

2010-03-05 23:59 Updated by: freebeans
  • Estado Update from Aberto to Fechado
  • Ticket Close date is changed to 2010-03-05 23:59

Attachment File List

No attachments

Editar

Please login to add comment to this ticket » Login