Version française
Home     About     Download     Resources     Contact us    

This site is updated infrequently. For up-to-date information, please visit the new OCaml website at

Browse thread
[Caml-list] boxing of floats in records/classes
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: -- (:)
From: Xavier Leroy <xavier.leroy@i...>
Subject: Re: [Caml-list] boxing of floats in records/classes
> Quick question: are mutable float fields in records or classes

Yes, with the exception of records that have all fields of type float.
In the latter case, the record is represented like a float array, with
each float unboxed.

> If so, why?

Mainly because the runtime system and garbage collector support either
blocks of pointers or blocks of unboxed data, but not mixed blocks
containing both pointers and unboxed data.

- Xavier Leroy
To unsubscribe, mail Archives:
Bug reports: FAQ:
Beginner's list: