diff options
| author | bors <bors@rust-lang.org> | 2019-06-12 07:38:01 +0000 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2019-06-12 07:38:01 +0000 |
| commit | 3f511ade5b0bc42028e42b81392feec770d90ead (patch) | |
| tree | cb5c0d96ce58721918115a689274280c0de8e722 /src/librustc_data_structures | |
| parent | c4797fa4f4a696b183b3aa1517ee22c78d0f5d7a (diff) | |
| parent | 1eaaf440d5173f090d6e937f4b4cffec6c038984 (diff) | |
| download | rust-3f511ade5b0bc42028e42b81392feec770d90ead.tar.gz rust-3f511ade5b0bc42028e42b81392feec770d90ead.zip | |
Auto merge of #60669 - c410-f3r:attrs-fn, r=petrochenkov
Allow attributes in formal function parameters Implements https://github.com/rust-lang/rust/issues/60406. This is my first contribution to the compiler and since this is a large and complex project, I am not fully aware of the consequences of the changes I have made. **TODO** - [x] Forbid some built-in attributes. - [x] Expand cfg/cfg_attr
Diffstat (limited to 'src/librustc_data_structures')
| -rw-r--r-- | src/librustc_data_structures/thin_vec.rs | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/librustc_data_structures/thin_vec.rs b/src/librustc_data_structures/thin_vec.rs index 52f23f4893e..6692903cd4f 100644 --- a/src/librustc_data_structures/thin_vec.rs +++ b/src/librustc_data_structures/thin_vec.rs @@ -66,3 +66,9 @@ impl<T: HashStable<CTX>, CTX> HashStable<CTX> for ThinVec<T> { (**self).hash_stable(hcx, hasher) } } + +impl<T> Default for ThinVec<T> { + fn default() -> Self { + Self(None) + } +} |
