2013/2/4 David Knaack <[email protected]>

> I may not understand the scope of your question, but could you use the
> swap function?
>
> http://www.freepascal.org/docs-html/rtl/system/swap.html
>
> Like so (edited in email, not compile checked):
>
> function ReadMWord(AStream: TStream): Word;
>   var
>     MW: Word
>   begin
>     AStream.Read(MW, SizeOf(Word));
>     Result := Swap(MW);
>   end;
>

Perfect! :)

Thank you very much!

-- 
Silvio Clécio
My public projects - github.com/silvioprog
--
_______________________________________________
Lazarus mailing list
[email protected]
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus

Reply via email to