Bug 1236322 - Part 1: Annotate intentional switch fallthroughs to suppress -Wimplicit-fallthrough warnings in parser/. r=hsivonen

parser/html/nsHtml5Highlighter.cpp:572:9 [-Wimplicit-fallthrough] unannotated fall-through between switch labels

parser/htmlparser/nsScanner.cpp:425:7 [-Wimplicit-fallthrough] unannotated fall-through between switch labels
parser/htmlparser/nsScanner.cpp:780:7 [-Wimplicit-fallthrough] unannotated fall-through between switch labels
This commit is contained in:
Chris Peterson
2015-12-25 00:01:32 -07:00
parent dab3fbc2f4
commit 256e9f19bb
2 changed files with 6 additions and 1 deletions

View File

@@ -9,6 +9,8 @@
#include "nsString.h"
#include "nsThreadUtils.h"
#include "nsHtml5ViewSourceUtils.h"
#include "mozilla/Attributes.h"
#include "mozilla/Preferences.h"
using namespace mozilla;
@@ -568,7 +570,7 @@ nsHtml5Highlighter::FlushChars()
// the input data, because there are no reparses in the View Source
// case, so we won't need the original data in the buffer anymore.
buf[i] = '\n';
// fall through
MOZ_FALLTHROUGH;
case '\n': {
++i;
if (mCStart < i) {