Nightly has bigger data size than stable?

I'm puzzled by this result I'm seeing on my CI, which indicates that my tiny set is taking more space on nightly than on the stable compiler. Any ideas why this might be? I don't normally expect data structure layout to depend on compiler version.

1 Like

The implementation of HashMap was changed recently. Type sizes are not guaranteed unless explicitly documented so.

6 Likes

There's some discussion of reducing the size here:
https://github.com/rust-lang/hashbrown/issues/69

2 Likes

Ah yes, somehow I'd forgotten that I used a HashMap inside TinyMap, and it didn't occur to me therefore that a library change could be responsible. Thanks!

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.