Maybe I'm unusual. But in C++ I'm always super-careful (one might say anal
retentive) about keeping my headers as clean of implementation details as
humanly possible. I don't think forgetting a `priv` would ever be an issue.
But I'm not everyone.

On Wed, May 29, 2013 at 11:34 PM, Mikhail Zabaluev <
mikhail.zabal...@gmail.com> wrote:

> Hi,
>
> I have a strong point against it: your crates are going to be christmas
> trees of exposed APIs unless you are careful. This has a runtime cost,
> increases the risk of breaking the ABI more often than you should, and
> often results in unintentional APIs that you may be later beholden to
> maintain.
>
> Look at the tragedy of failing to use -fvisibility=hidden when building
> shared libraries with gcc.
>
> Best regards,
>   Mikhail
>
>
> 2013/5/30 Gábor Lehel <illiss...@gmail.com>
>
> Currently Rust has different default visibilities in different places:
>> - `mod` items are private
>> - `struct` fields and `enum` variants are public
>> - `trait` methods are public
>> - `impl` methods are private
>> - `impls for` are public (by necessity)
>>
>> I propose to change this to:
>> - Everything not `priv` is public
>>
>


-- 
Your ship was destroyed in a monadic eruption.
_______________________________________________
Rust-dev mailing list
Rust-dev@mozilla.org
https://mail.mozilla.org/listinfo/rust-dev

Reply via email to