[parser] Remove assert about input validity

This assert is only enforcing that the input is valid, not that it is
safe. This should be deferred until validation.

Bug: dawn:578
Change-Id: I083a62292ff7ca0fc35080d8c66dabf3188c7bca
Reviewed-on: https://dawn-review.googlesource.com/c/tint/+/34480
Commit-Queue: Ryan Harrison <rharrison@chromium.org>
Auto-Submit: Ryan Harrison <rharrison@chromium.org>
Reviewed-by: dan sinclair <dsinclair@chromium.org>
diff --git a/src/ast/type/storage_texture_type.cc b/src/ast/type/storage_texture_type.cc
index 87c4657..af6c7d5 100644
--- a/src/ast/type/storage_texture_type.cc
+++ b/src/ast/type/storage_texture_type.cc
@@ -23,19 +23,6 @@
 namespace tint {
 namespace ast {
 namespace type {
-namespace {
-
-#ifndef NDEBUG
-
-bool IsValidStorageDimension(TextureDimension dim) {
-  return dim == TextureDimension::k1d || dim == TextureDimension::k1dArray ||
-         dim == TextureDimension::k2d || dim == TextureDimension::k2dArray ||
-         dim == TextureDimension::k3d;
-}
-
-#endif  // NDEBUG
-
-}  // namespace
 
 // Note, these names match the names in the WGSL spec. This behaviour is used
 // in the WGSL writer to emit the texture format names.
@@ -156,9 +143,7 @@
 StorageTexture::StorageTexture(TextureDimension dim,
                                ast::AccessControl access,
                                ImageFormat format)
-    : Base(dim), access_(access), image_format_(format) {
-  assert(IsValidStorageDimension(dim));
-}
+    : Base(dim), access_(access), image_format_(format) {}
 
 void StorageTexture::set_type(Type* const type) {
   type_ = type;