-Wreturn-type warning in DFGObjectAllocationSinkingPhase.cpp
authormcatanzaro@igalia.com <mcatanzaro@igalia.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 1 Feb 2018 17:27:06 +0000 (17:27 +0000)
committermcatanzaro@igalia.com <mcatanzaro@igalia.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 1 Feb 2018 17:27:06 +0000 (17:27 +0000)
https://bugs.webkit.org/show_bug.cgi?id=182389

Reviewed by Yusuke Suzuki.

Fix the warning.

As a bonus, remove a couple unreachable breaks for good measure.

* dfg/DFGObjectAllocationSinkingPhase.cpp:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@227970 268f45cc-cd09-0410-ab3c-d52691b4dbfc

Source/JavaScriptCore/ChangeLog
Source/JavaScriptCore/dfg/DFGObjectAllocationSinkingPhase.cpp

index 8d93a9e..373c820 100644 (file)
@@ -1,3 +1,16 @@
+2018-02-01  Michael Catanzaro  <mcatanzaro@igalia.com>
+
+        -Wreturn-type warning in DFGObjectAllocationSinkingPhase.cpp
+        https://bugs.webkit.org/show_bug.cgi?id=182389
+
+        Reviewed by Yusuke Suzuki.
+
+        Fix the warning.
+
+        As a bonus, remove a couple unreachable breaks for good measure.
+
+        * dfg/DFGObjectAllocationSinkingPhase.cpp:
+
 2018-02-01  Chris Dumez  <cdumez@apple.com>
 
         Queue a microtask when a waitUntil() promise is settled
index 19ce124..91237ac 100644 (file)
@@ -1532,7 +1532,6 @@ private:
                 where->origin.withSemantic(
                     allocation.identifier()->origin.semantic),
                 OpInfo(executable));
-            break;
         }
 
         case Allocation::Kind::Activation: {
@@ -1553,7 +1552,6 @@ private:
                 where->origin.withSemantic(
                     allocation.identifier()->origin.semantic),
                 OpInfo(regExp));
-            break;
         }
 
         default:
@@ -2306,7 +2304,6 @@ private:
                 OpInfo(data),
                 Edge(base, KnownCellUse),
                 value->defaultEdge());
-            break;
         }
 
         case ClosureVarPLoc: {
@@ -2316,7 +2313,6 @@ private:
                 OpInfo(location.info()),
                 Edge(base, KnownCellUse),
                 value->defaultEdge());
-            break;
         }
 
         case RegExpObjectLastIndexPLoc: {
@@ -2326,13 +2322,14 @@ private:
                 OpInfo(true),
                 Edge(base, KnownCellUse),
                 value->defaultEdge());
-            break;
         }
 
         default:
             DFG_CRASH(m_graph, base, "Bad location kind");
             break;
         }
+
+        RELEASE_ASSERT_NOT_REACHED();
     }
 
     // This is a great way of asking value->isStillValid() without having to worry about getting