digitalmars.D.bugs - [Issue 2117] New: Please add more byteswapping support
- d-bugmail puremagic.com (20/20) May 20 2008 http://d.puremagic.com/issues/show_bug.cgi?id=2117
- Janice Caron (3/6) May 20 2008 I never did understand the difference between ntoh* and hton*. :-)
- Ingo Oeser (7/8) May 24 2008 It is a semantic difference only, not a behavioral one.
- d-bugmail puremagic.com (13/13) Jul 31 2011 http://d.puremagic.com/issues/show_bug.cgi?id=2117
http://d.puremagic.com/issues/show_bug.cgi?id=2117
Summary: Please add more byteswapping support
Product: D
Version: 2.014
Platform: PC
OS/Version: Linux
Status: NEW
Severity: enhancement
Priority: P2
Component: Phobos
AssignedTo: bugzilla digitalmars.com
ReportedBy: jlquinn optonline.net
Right now there is limited support for byteswapping. std.intrinsic includes
bswap(uint), and std.system includes a predefined constant for system
endianness.
It would be really helpful to have bswap equivalents for all basic datatypes,
as well as routines to swap between native endianness and explicit big or
little endian, ala ntohl, ntohs, htonl, htons
A related thing that would come in handy is byteswapping mmap support.
--
May 20 2008
On 20/05/2008, d-bugmail puremagic.com <d-bugmail puremagic.com> wrote:It would be really helpful to have bswap equivalents for all basic datatypes,Essentially, bswap(T)(T x)as well as routines to swap between native endianness and explicit big or little endian, ala ntohl, ntohs, htonl, htonsI never did understand the difference between ntoh* and hton*. :-)
May 20 2008
Janice Caron wrote:I never did understand the difference between ntoh* and hton*. :-)It is a semantic difference only, not a behavioral one. You can deduce the expected and actual endianess when using the semantically correct transformation. This helps (static) checkers like e.g. sparse on Linux. Best Regards Ingo Oeser
May 24 2008
http://d.puremagic.com/issues/show_bug.cgi?id=2117
Jonathan M Davis <jmdavisProg gmx.com> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |RESOLVED
CC| |jmdavisProg gmx.com
Resolution| |FIXED
PDT ---
Fixed with
https://github.com/D-Programming-Language/phobos/tree/10ef435bc416c2e41bef9be7119a00d9fd305cda
--
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
Jul 31 2011









Ingo Oeser <ioe-news rameria.de> 