[nnc] Fix switch construction with default case (#1709)
authorПавел Ильютченко/AI Tools Lab /SRR/Assistant Engineer/삼성전자 <p.iliutchenk@partner.samsung.com>
Tue, 9 Oct 2018 11:20:55 +0000 (14:20 +0300)
committerРоман Михайлович Русяев/AI Tools Lab /SRR/Staff Engineer/삼성전자 <r.rusyaev@samsung.com>
Tue, 9 Oct 2018 11:20:55 +0000 (14:20 +0300)
* add assert(false) to default case of switch statement

Signed-off-by: Pavel Iliutchenko <p.iliutchenk@partner.samsung.com>
contrib/nnc/passes/interpreter/ops/Pool.cpp

index 7e2adee..f5a425a 100644 (file)
@@ -85,6 +85,9 @@ std::vector<TensorVariant> Pool::operator()()
             //Skip all elements outside input range
             continue;
           }
+          default: {
+            assert(false && "Invalid border type for pooling");
+          }
         }
       }
       out = poolingFunc(out, in);