Sign in
fuchsia
/
third_party
/
rust
/
9d09331e00b02f81c714b0c41ce3a38380dd36a2
/
.
/
src
/
test
/
ui
/
deriving
/
deriving-default-box.rs
blob: 237dbfaa0567468910aed5842d2999e74545b4e4 [
file
] [
log
] [
blame
]
// run-pass
#![
feature
(
box_syntax
)]
use
std
::
default
::
Default
;
#[
derive
(
Default
)]
struct
A
{
foo
:
Box
<[
bool
]>,
}
pub
fn
main
()
{
let
a
:
A
=
Default
::
default
();
let
b
:
Box
<[
_
]>
=
Box
::<[
bool
;
0
]>::
new
([]);
assert_eq
!(
a
.
foo
,
b
);
}