Join GitHub today
GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.
Sign upDerive Debug for FontGroup and its components #8908
Conversation
highfive
commented
Dec 9, 2015
|
Thanks for the pull request, and welcome! The Servo team is excited to review your changes, and you should hear from @larsbergstrom (or someone else) soon. |
|
@bors-servo r+ |
|
|
|
Thank you for your PR! |
|
|
Derive Debug for FontGroup and its components In order to enable `#[derive(Debug)]` on HashMap (used by Font), this also requires applying trait bounds to HashMap itself (rather than just the impl) -- which is probably better anyway. <!-- Reviewable:start --> [<img src="https://reviewable.io/review_button.png" height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/8908) <!-- Reviewable:end -->
|
|
|
This is bad: The macos platform implementation ultimately goes back to core_font::CTFont, which doesn't implement Debug... Not sure how to deal with this. Implement it in core_font, and depend on the updated version? (This is kinda getting out of hand, for a simple debug convenience feature...) Or maybe just add a dummy impl Debug for CTFont for now in the files using it?... |
|
Also, don't know how to test the macos build without running that system myself?... |
|
We can run |
Derive Debug for CTFont, CTFontCollection, CTFontDescriptor These are all the structs as far as I can see. Note that this is entirely untested... Let's see whether I got it right :-) (Needed for servo/servo#8908 ) <!-- Reviewable:start --> [<img src="https://reviewable.io/review_button.png" height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/core-text-rs/45) <!-- Reviewable:end -->
Derive Debug for CTFont, CTFontCollection, CTFontDescriptor These are all the structs as far as I can see. Note that this is entirely untested... Let's see whether I got it right :-) (Needed for servo/servo#8908 ) <!-- Reviewable:start --> [<img src="https://reviewable.io/review_button.png" height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/core-text-rs/45) <!-- Reviewable:end -->
|
I added the platform/macos bits. It's entirely untested, though -- let's see what the build bot makes of it... |
|
Looks good so far... Will it actually build on MacOS? :-) |
|
@bors-servo try |
Derive Debug for FontGroup and its components In order to enable `#[derive(Debug)]` on HashMap (used by Font), this also requires applying trait bounds to HashMap itself (rather than just the impl) -- which is probably better anyway. <!-- Reviewable:start --> [<img src="https://reviewable.io/review_button.png" height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/8908) <!-- Reviewable:end -->
|
|
|
@antrik your PR compiles fine right now, it's just the intermittents that's causing an issue. |
|
@bors-servo retry |
Derive Debug for FontGroup and its components In order to enable `#[derive(Debug)]` on HashMap (used by Font), this also requires applying trait bounds to HashMap itself (rather than just the impl) -- which is probably better anyway. <!-- Reviewable:start --> [<img src="https://reviewable.io/review_button.png" height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/8908) <!-- Reviewable:end -->
|
Doh. @bors-servo try- force r+ |
|
|
|
@bors-servo r- force |
|
@bors-servo r=Ms2ger |
|
|
|
@bors-servo r- force |
1 similar comment
|
@bors-servo r- force |
antrik commentedDec 9, 2015
In order to enable
#[derive(Debug)]on HashMap (used by Font), this also requires applying trait bounds to HashMap itself (rather than just the impl) -- which is probably better anyway.