Re: [fpc-pascal] Custom assignment operators

2012-03-30 Thread Sven Barth
Am 30.03.2012 17:40 schrieb "Mark Morgan Lloyd" < markmll.fpc-pas...@telemetry.co.uk>: > > A few weeks ago somebody (Martin?) suggested I got round an endianness issue by doing this: > > typeWordLE= packed record b0, b1: byte; end; > > operator := (wle: WordLE): word; > > begin > .. > > It work

[fpc-pascal] Custom assignment operators

2012-03-30 Thread Mark Morgan Lloyd
A few weeks ago somebody (Martin?) suggested I got round an endianness issue by doing this: typeWordLE= packed record b0, b1: byte; end; operator := (wle: WordLE): word; begin .. It works well, except that attempting to use an assignment inside the operator definition immediately recurse