native-endianness(3scm)
NAME π
okay so bestie, this is native-endianness β the manual page for native-endianness from the Scheme Programmer's Manual, section 3scm. Its whole job? Return the native endianness. That's it. Iconic. π
π LIBRARY π
These imports, exactly:
(import (rnrs)) ;R6RS
(import (rnrs bytevectors)) ;R6RS
β¨ SYNOPSIS β¨
(native-endianness)
π¦ DESCRIPTION π¦
This procedure returns the native endianness of the system as a symbol. The symbol is normally one of these:
bigβ Big endian. The more significant bytes come before the less significant bytes. Big-brain byte order, no cap. π§littleβ Little endian. The less significant bytes come before the more significant bytes. Tiny-first energy. π
π RETURN VALUES π
Returns a single symbol. That's the whole return, bestie β one symbol, no extras. π«Ά
πΈ EXAMPLES πΈ
(native-endianness)
=> little
So on that system, the vibe check says little. π¦
π APPLICATION USAGE π
This procedure is sometimes used when interfacing with external systems that use the native endianness to pass data. So if some outside system is like βhey, here's data in my native byte order,β this is how you ask your Scheme what that order is. π«Ά
π₯ COMPATIBILITY π₯
- This procedure exists in R6RS and is absent from R7RS-small. So if you're on R7RS-small, don't come looking for it here, bestie. π
- SRFI-74 has the native endianness as part of the
endianness(7scm)syntax. - Other endianness values may exist and they are in that case valid arguments to the system's bytevector procedures. So if you see another one, don't panic β it's valid there. No cap. π
- Most systems today are little endian, but big endian hardware also exists. Other endianness variants have died out. π
π ERRORS π
This procedure can raise exceptions with the following condition types:
&assertion(R6RS) β The wrong number of arguments was passed. So like, don't pass the wrong number of args, or it's gonna throw this at you. π
π SEE ALSO π
π STANDARDS π
R6RS. Periodt. π
π AUTHORS π
This page is part of the scheme-manpages project. It includes materials from the RnRS documents. More information can be found at https://github.com/schemedoc/manpages/. π«Ά
okay bye bestie! π this was native-endianness(3scm), dated 2021-03-09 β mwah! π
β¨
π¦ where this page comes from
- nixpkgs unstable: scheme-manpages 0-unstable-2024-02-11
- π the page's license: MIT
- Copyright (c) 2021 Gwen Weinholt
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms