Closed Bug 1380789 Opened 8 years ago Closed 8 years ago

stylo: Uplift a few assertions to nightly

Categories

(Core :: CSS Parsing and Computation, enhancement)

enhancement
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla56
Tracking Status
firefox56 --- fixed

People

(Reporter: emilio, Assigned: emilio)

References

Details

Attachments

(1 file, 1 obsolete file)

This will hopefully help us diagnose faster the bugs we currently have no STR for.
Blocks: 1380684
You should use MOZ_DIAGNOSTIC_ASSERT for the gecko-side assertions. It would be nice if we did something similar in Rust, but it would take some build config glue.
Comment on attachment 8886335 [details] stylo: Assert our stuff properly. https://reviewboard.mozilla.org/r/157076/#review162358 ::: commit-message-01c02:1 (Diff revision 2) > +stylo: Assert our stuff properly. r?heycam Sub-optimal commit message. :-) ::: servo/ports/geckolib/glue.rs:2740 (Diff revision 2) > + // TODO(emilio): Downgrade to debug assertions when close to release. > + assert!(data.has_styles(), "Resolving style on unstyled element"); > + assert!(element.has_current_styles(&*data), > + "Resolving style on element without current styles"); Agreed, this should help us get better error reports, rather than whatever weirdness returning default computed values would cause. Once we are close to release and reverting these to debug assertions, we should consider lazily computing the actual styles (rather than default computed values).
Attachment #8886335 - Flags: review?(cam) → review+
Comment on attachment 8886334 [details] Bug 1380789: Uplift the type assertions to nightly. https://reviewboard.mozilla.org/r/157074/#review162360 r=me with just using MOZ_DIAGNOSTIC_ASSERT.
Attachment #8886334 - Flags: review?(cam) → review+
Attachment #8886335 - Attachment is obsolete: true
Pushed by ecoal95@gmail.com: https://hg.mozilla.org/integration/autoland/rev/e9ec92fd4f47 Uplift the type assertions to nightly. r=heycam
Pushed by ecoal95@gmail.com: https://hg.mozilla.org/integration/autoland/rev/6a689b0db251 followup: Fixup alignment in macro definitions. r=whitespace-only
Depends on: 1381844
Depends on: 1386596
No longer depends on: 1386596
Depends on: 1386596
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: