Bit.bswap

From GiderosMobile
The printable version is no longer supported and may have rendering errors. Please update your browser bookmarks and please use the default browser print function instead.
This page contains changes which are not marked for translation.


Available since: Gideros 2013.09
Class: bit

Description

Swaps the bytes of its argument and returns it. This can be used to convert little-endian 32 bit numbers to big-endian 32 bit numbers or vice versa.

(number) = bit.bswap(x)

Parameters

x: (number) number to swap

Return values

Returns (number) Swapped bytes