Am 28.11.2013 18:33 schrieb "Tomas Hajny" :
> > This looks like a missing declaration of one variant of the dec
function.
Aside from what Tomas said: there us no declaration of Dec(), because it is
a compiler intrinsic and thus directly converted by the compiler into code.
Regards,
Sven
_
On Thu, November 28, 2013 18:12, Klaus Hartnegg wrote:
> Sorry, I forgot to mention there is {$Q-} in the source.
I believe that $Q- covers overflow checks, not range checks.
> The trick was indeed to use dec(longint(a),b). However I had missed one
> place in the code, so I got another runtime e
Klaus Hartnegg wrote:
Hi,
How can I subtract two longwords such that when the result becomes
negative, it rolls over?
A := A - B triggers runtime error 201 when the result is negative.
dec (A,B) rolls over, but triggers runtime error 201 when A is higher
than the highest possible value of l
Sorry, I forgot to mention there is {$Q-} in the source.
The trick was indeed to use dec(longint(a),b). However I had missed one
place in the code, so I got another runtime error from there.
But why does it only work with longint, and not with longword?
This looks like a missing declaration o
On Thu, November 28, 2013 17:37, Klaus Hartnegg wrote:
Hi,
> How can I subtract two longwords such that when the result becomes
> negative, it rolls over?
>
> A := A - B triggers runtime error 201 when the result is negative.
>
> dec (A,B) rolls over, but triggers runtime error 201 when A is hig
Hi,
How can I subtract two longwords such that when the result becomes
negative, it rolls over?
A := A - B triggers runtime error 201 when the result is negative.
dec (A,B) rolls over, but triggers runtime error 201 when A is higher
than the highest possible value of longint.
Is dec only d
Dennis Poon wrote:
when using lnet to connect to a remote server at DomainName : Port e.g.
yahoo.com : 80
in file lCommon.pp line 492:
function StrToNetAddr(const IP : String) : Sockets.in_addr;inline;
begin
result := Sockets.StrToNetAddr(IP);
end;
The above function did not raise exceptio
On Thu, November 28, 2013 09:03, Sven Barth wrote:
> Am 28.11.2013 08:33, schrieb Andreas Schneider:
>> Maybe a bit late, but that might not be true. If Timothy really talks
>> about _object_ (and not _class(TObject)_) it should work as he does
>> it. Also Destroy would probably be appropriate. Jus
Am 28.11.2013 08:33, schrieb Andreas Schneider:
Maybe a bit late, but that might not be true. If Timothy really talks
about _object_ (and not _class(TObject)_) it should work as he does
it. Also Destroy would probably be appropriate. Just saying :-) The
actual type defs used are missing.
Unli