Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / fpc-devel / 2009-12

[arm] tStream.position

3 messages · 2 people ·

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

Dariusz Mazur

Hi
there is problem with something like that

var
  ts : tStream;
begin
  ts:=tStream.create;
  ts.position:=2;
// here arm write ERange Error
// on trace setPosition
//  is very big number, like 15300000000000,,,,
  ts.free;
end;

platform : ARM with soft float

Darek

Reply by email

Mattias Gärtner
to Dariusz Mazur

Zitat von Dariusz Mazur :

Show quoted text 8 lines
Hi there is problem with something like that var ts : tStream; begin ts:=tStream.create;

ouch.
TStream is an abstract class.
Maybe the keyword 'abstract' should be added, so that the compiler warns.

Show quoted text 9 lines
ts.position:=2; // here arm write ERange Error // on trace setPosition // is very big number, like 15300000000000,,,, ts.free; end; platform : ARM with soft float

It is wrong on every platform.

Mattias

Reply by email

Dariusz Mazur
to Mattias Gärtner

Mattias Gärtner pisze:

Show quoted text 14 lines
Zitat von Dariusz Mazur : > Hi > there is problem with something like that > > > var > ts : tStream; > begin > ts:=tStream.create; ouch. TStream is an abstract class. Maybe the keyword 'abstract' should be added, so that the compiler warns.

No,
I've start form tMemoryStream
there is property position
which invoke setPosition
which invoke seek

abstract does'nt matter

Show quoted text 16 lines
> ts.position:=2; > // here arm write ERange Error > // on trace setPosition > // is very big number, like 15300000000000,,,, > ts.free; > end; > > > platform : ARM with soft float It is wrong on every platform. Mattias
Darek

Reply by email