dzamlo / rust-bitfield

This crate provides macros to generate bitfield-like struct.
Apache License 2.0
157 stars 19 forks source link

The inner of the newtype is alway public #10

Open ithinuel opened 6 years ago

ithinuel commented 6 years ago

It would be nice to be able to hide the inner element of the "newtypes".

dzamlo commented 6 years ago

My reasoning was that bitfield is only a thin wrapper around the inner type and as such you will likely want to have access to the inner type. But it may make sense to have it private by default, if you don't add pub.