Closed Bug 1439355 Opened 8 years ago Closed 8 years ago

use static_assert instead of NS_ASSERTION in nsBinaryStream.cpp

Categories

(Core :: XPCOM, enhancement)

enhancement
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla60
Tracking Status
firefox60 --- fixed

People

(Reporter: froydnj, Assigned: froydnj)

Details

Attachments

(1 file)

The intention is a little more clear with static_assert, as well as failing sooner. (The code is probably the same, since the compiler will optimize out the checks as dead code, but meh.)
Comment on attachment 8952119 [details] [diff] [review] use static_assert instead of NS_ASSERTION in nsBinaryStream.cpp Review of attachment 8952119 [details] [diff] [review]: ----------------------------------------------------------------- ::: xpcom/io/nsBinaryStream.cpp @@ +201,1 @@ > "False assumption about sizeof(float)"); nit: fix indentation of string here and below.
Attachment #8952119 - Flags: review?(nika) → review+
Pushed by nfroyd@mozilla.com: https://hg.mozilla.org/integration/mozilla-inbound/rev/0586b21d0709 use static_assert instead of NS_ASSERTION in nsBinaryStream.cpp; r=mystor
Status: NEW → RESOLVED
Closed: 8 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla60
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: