On Fri, Feb 28, 2014 at 8:43 PM, Niko Matsakis <n...@alum.mit.edu> wrote:
> On Fri, Feb 28, 2014 at 08:15:18PM +0100, Matthieu Monrocq wrote: > > Maybe one way of preventing completely un-annotated pieces of data would > be > > a lint that just checks that at least one property (Send, Freeze, ...) > or a > > special annotation denoting their absence has been selected for each > > public-facing type. By having a #[deriving(...)] "mandatory", it makes it > > easier for the lint pass to flag un-marked types without even having to > > reason whether or not the type would qualify. > > Buried in the the very last sentence was this idea: > > "One way to mitigate this problem would be to have a lint for when an > impl of some kind (etc) would be legal, but isn't implemented, at > least for publicly exported types in library crates." > > This seems to be similar to what you suggest. > > Yes, I was actually rebounding on it. The main issue with the lint as you proposed is that if I *want* a linear type without any property, the lint will continuously bug me. Thus the idea of #[deriving(None)] (or whatever name) to shut the lint down, because once you start ignoring warnings, you miss the important ones. -- Matthieu > > Niko >
_______________________________________________ Rust-dev mailing list Rust-dev@mozilla.org https://mail.mozilla.org/listinfo/rust-dev