Einzelnen Beitrag anzeigen

Medium

Registriert seit: 23. Jan 2008
3.679 Beiträge
 
Delphi 2007 Enterprise
 
#6

AW: Truncate float without rounding

  Alt 5. Jan 2014, 19:53
For a totally general case, an Int64 would cover the largest range out of the integer types, that might be put in by an Extended. Cardinal most notably misses the sign. It depends on what you use the number for if you could use smaller types as output. (But even an Int64 can not cover the full range of an Extended by design - not without some rather wild re-mappings.)
"When one person suffers from a delusion, it is called insanity. When a million people suffer from a delusion, it is called religion." (Richard Dawkins)
  Mit Zitat antworten Zitat