Bytes, chars, ints, etc (gnu algol 68, C, ...)

chris hermansen clhermansen@gmail.com
Fri Jan 16 21:06:35 GMT 2026


James and everyone,

On Fri, Jan 16, 2026 at 12:43 PM jpl <jpl.algol68@gmail.com> wrote:

> Thanks to all for the responses.  There is high educational value to
> them and have learned quite much,
>

100% in agreement there - lots of self-learning, too.  Thanks to all!

>
> I started this thread due to some concern if we would be able to know
> the exact byte sizes of our variables.
>
> In turn this relates to binary transput of these variables.  For
> example, writing binary output files that would allow decoding by byte
> counting.  Actually, I do not know if Algol68 has a way to create
> "byte-packed records" (aka structs), but that connects a bit too.
>

I seem to be edging closer to writing some transput code... assuming I get
to that point, my goal is to more or less follow what the Java folks do
with binary transput, which is to write and read binary values in a
canonical fashion, so that they can be written on a bigendian machine and
read on a littleendian machine, and vice versa.

I was also thinking that, while debugging, it could be useful to write and
read binary as JSON or hexadecimal strings.


-- 
Chris Hermansen · clhermansen "at" gmail "dot" com

C'est ma façon de parler.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://gcc.gnu.org/pipermail/algol68/attachments/20260116/7cc1c1ca/attachment.htm>


More information about the Algol68 mailing list