Talk:Comet32

From CometWiki

(Difference between revisions)
Jump to: navigation, search
Line 4: Line 4:
<li> Robert has a problem with it also, details on Forum. Just typing this to see how it appears.  How do you know who says what on a Wiki ?
<li> Robert has a problem with it also, details on Forum. Just typing this to see how it appears.  How do you know who says what on a Wiki ?
 +
 +
The real problem with the str() function is the use of numeric expressions as the argument to the function. The C16 accumulator was implicitly defined as length 16.8. The c32 accumulator  may be much larger. It is currently defined as 64.32.
 +
 +
It is consistent to strip leading spaces from the string, otherwise, you would not know the actual result.
 +
 +
That said, we are open to any change like this if everyone wants it. I just think it is short sighted to always want C32 to behave exactly like c16.
 +
 +
We could also only strip the string if the argument were an expression. We could also, treat expressions as arguments to the str function as if the accumulator were 16.8.
 +
 +
 +
Changing from one version of a language to another requires a re-compile. It is really the only opportunity we have to change behavior. I think we should also look at the obsolete fields in fstat() for instance.
 +
 +
The other big change is the unexpected error 1 if a numeric expression overflows the variable it is assigned to.
 +
 +
Length 3.2 & local I
 +
 +
i = 1234
 +
 +
will produce an excp=1.

Revision as of 21:42, 16 May 2009

Str() Function - changed operation.

  • As mentioned on Forum, I use the Str() function to convert a numeric to string for a percentage that is then used in the key of a file to rank slaes. This change negates that.
  • Robert has a problem with it also, details on Forum. Just typing this to see how it appears. How do you know who says what on a Wiki ? The real problem with the str() function is the use of numeric expressions as the argument to the function. The C16 accumulator was implicitly defined as length 16.8. The c32 accumulator may be much larger. It is currently defined as 64.32. It is consistent to strip leading spaces from the string, otherwise, you would not know the actual result. That said, we are open to any change like this if everyone wants it. I just think it is short sighted to always want C32 to behave exactly like c16. We could also only strip the string if the argument were an expression. We could also, treat expressions as arguments to the str function as if the accumulator were 16.8. Changing from one version of a language to another requires a re-compile. It is really the only opportunity we have to change behavior. I think we should also look at the obsolete fields in fstat() for instance. The other big change is the unexpected error 1 if a numeric expression overflows the variable it is assigned to. Length 3.2 & local I i = 1234 will produce an excp=1.
  • Personal tools