Auto merge of #12918 - hsinewu:12902-typedefs, r=Manishearth

12902 typedefs

<!-- Please describe your changes on the following line: -->
Using type alias instead of newtype.
Removing duplicated implementation, it's already inherited.
No more type constructors and foo.0
---
<!-- Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `__` with appropriate data: -->
- [X] `./mach build -d` does not report any errors
- [X] `./mach test-tidy` does not report any errors
- [X] These changes fix #12902 (github issue number if applicable).

<!-- Either: -->
- [X] These changes do not require tests because it's refactoring.

<!-- Pull requests that do not address these steps are welcome, but they will require additional verification as part of the review process. -->

<!-- Reviewable:start -->
---
This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/12918)
<!-- Reviewable:end -->
This commit is contained in:
bors-servo 2016-08-22 06:01:03 -05:00 committed by GitHub
commit daee53cb76
5 changed files with 17 additions and 55 deletions

View file

@ -704,12 +704,12 @@ mod shorthand_serialization {
authored: None
});
let position = DeclaredValue::Value(PositionContainer(
let position = DeclaredValue::Value(
Position {
horizontal: LengthOrPercentage::Length(Length::from_px(7f32)),
vertical: LengthOrPercentage::Length(Length::from_px(4f32))
}
));
);
let repeat = DeclaredValue::Value(Repeat::repeat_x);
let attachment = DeclaredValue::Value(Attachment::scroll);
@ -755,12 +755,12 @@ mod shorthand_serialization {
authored: None
});
let position = DeclaredValue::Value(PositionContainer(
let position = DeclaredValue::Value(
Position {
horizontal: LengthOrPercentage::Length(Length::from_px(7f32)),
vertical: LengthOrPercentage::Length(Length::from_px(4f32))
}
));
);
let repeat = DeclaredValue::Value(Repeat::repeat_x);
let attachment = DeclaredValue::Value(Attachment::scroll);
@ -805,12 +805,12 @@ mod shorthand_serialization {
authored: None
});
let position = DeclaredValue::Value(PositionContainer(
let position = DeclaredValue::Value(
Position {
horizontal: LengthOrPercentage::Length(Length::from_px(0f32)),
vertical: LengthOrPercentage::Length(Length::from_px(0f32))
}
));
);
let repeat = DeclaredValue::Value(Repeat::repeat_x);
let attachment = DeclaredValue::Value(Attachment::scroll);