Add fuzzing target to BUILD.gn

TEST=Built fuzzer in local checkout of Chromium with tint integrated.
BUG=dawn:14

Change-Id: I84aacd41f893070c3af40f5e640361e177689f9e
Reviewed-on: https://dawn-review.googlesource.com/c/tint/+/20343
Reviewed-by: dan sinclair <dsinclair@google.com>
diff --git a/BUILD.gn b/BUILD.gn
index 27adc0f..5ee239f 100644
--- a/BUILD.gn
+++ b/BUILD.gn
@@ -22,7 +22,6 @@
 
 config("tint_common_config") {
   defines = []
-
   if (tint_build_spv_reader) {
     defines += [ "TINT_BUILD_SPV_READER=1" ]
   } else {
@@ -46,6 +45,144 @@
   } else {
     defines += [ "TINT_BUILD_WGSL_WRITER=0" ]
   }
+
+  include_dirs = [
+    "${target_gen_dir}",
+    "${tint_root_dir}/",
+    "${tint_spirv_headers_dir}/include",
+    "${tint_spirv_tools_dir}/",
+    "${tint_spirv_tools_dir}/include",
+  ]
+}
+
+###############################################################################
+# Generated - Generated source files
+###############################################################################
+# These are copies of rules from SPIRV-Tools with the names tweaked to be Tint
+# specific. They are needed here because referencing generated files in sibling
+# packages is difficult/impossible in Chromium. Parts of Tint's SPIRV handling
+# code depend on internal parts of SPIRV-Tools. This causes issues because when
+# Tint references the internal headers, since it causes a dependency on these
+# generated files, but they are not visible in the context building Tint. Thus
+# Tint generates its own copy of the generated files. Since they come from the
+# same source of truth, they should not vary.
+
+template("tint_core_tables") {
+  assert(defined(invoker.version), "Need version in $target_name generation.")
+
+  action("tint_core_tables_" + target_name) {
+    script = "${tint_spirv_tools_dir}/utils/generate_grammar_tables.py"
+
+    version = invoker.version
+
+    core_json_file = "${tint_spirv_headers_dir}/include/spirv/$version/spirv.core.grammar.json"
+    core_insts_file = "${target_gen_dir}/core.insts-$version.inc"
+    operand_kinds_file = "${target_gen_dir}/operand.kinds-$version.inc"
+    debuginfo_insts_file =
+        "${tint_spirv_tools_dir}/source/extinst.debuginfo.grammar.json"
+    cldebuginfo100_insts_file = "${tint_spirv_tools_dir}/source/extinst.opencl.debuginfo.100.grammar.json"
+
+    sources = [
+      cldebuginfo100_insts_file,
+      core_json_file,
+      debuginfo_insts_file,
+    ]
+    outputs = [
+      core_insts_file,
+      operand_kinds_file,
+    ]
+    args = [
+      "--spirv-core-grammar",
+      rebase_path(core_json_file, root_build_dir),
+      "--core-insts-output",
+      rebase_path(core_insts_file, root_build_dir),
+      "--extinst-debuginfo-grammar",
+      rebase_path(debuginfo_insts_file, root_build_dir),
+      "--extinst-cldebuginfo100-grammar",
+      rebase_path(cldebuginfo100_insts_file, root_build_dir),
+      "--operand-kinds-output",
+      rebase_path(operand_kinds_file, root_build_dir),
+    ]
+  }
+}
+
+template("tint_core_enums") {
+  assert(defined(invoker.version), "Need version in $target_name generation.")
+
+  action("tint_core_enums_" + target_name) {
+    script = "${tint_spirv_tools_dir}/utils/generate_grammar_tables.py"
+
+    version = invoker.version
+
+    core_json_file = "${tint_spirv_headers_dir}/include/spirv/$version/spirv.core.grammar.json"
+    debuginfo_insts_file =
+        "${tint_spirv_tools_dir}/source/extinst.debuginfo.grammar.json"
+    cldebuginfo100_insts_file = "${tint_spirv_tools_dir}/source/extinst.opencl.debuginfo.100.grammar.json"
+
+    extension_enum_file = "${target_gen_dir}/extension_enum.inc"
+    extension_map_file = "${target_gen_dir}/enum_string_mapping.inc"
+
+    args = [
+      "--spirv-core-grammar",
+      rebase_path(core_json_file, root_build_dir),
+      "--extinst-debuginfo-grammar",
+      rebase_path(debuginfo_insts_file, root_build_dir),
+      "--extinst-cldebuginfo100-grammar",
+      rebase_path(cldebuginfo100_insts_file, root_build_dir),
+      "--extension-enum-output",
+      rebase_path(extension_enum_file, root_build_dir),
+      "--enum-string-mapping-output",
+      rebase_path(extension_map_file, root_build_dir),
+    ]
+    inputs = [
+      core_json_file,
+      debuginfo_insts_file,
+      cldebuginfo100_insts_file,
+    ]
+    outputs = [
+      extension_enum_file,
+      extension_map_file,
+    ]
+  }
+}
+
+template("tint_language_header") {
+  assert(defined(invoker.name), "Need name in $target_name generation.")
+
+  action("tint_language_header_" + target_name) {
+    script = "${tint_spirv_tools_dir}/utils/generate_language_headers.py"
+
+    name = invoker.name
+    extinst_output_path = "${target_gen_dir}/${name}.h"
+
+    args = [
+      "--extinst-grammar",
+      rebase_path(invoker.grammar_file, root_build_dir),
+      "--extinst-output-path",
+      rebase_path(extinst_output_path, root_build_dir),
+    ]
+    inputs = [ invoker.grammar_file ]
+    outputs = [ "${extinst_output_path}" ]
+  }
+}
+
+tint_core_tables("unified1") {
+  version = "unified1"
+}
+
+tint_core_enums("unified1") {
+  version = "unified1"
+}
+
+tint_language_header("debuginfo") {
+  name = "DebugInfo"
+  grammar_file = "${tint_spirv_tools_dir}/source/extinst.debuginfo.grammar.json"
+}
+
+tint_language_header("cldebuginfo100") {
+  name = "OpenCLDebugInfo100"
+  grammar_file =
+      "${tint_spirv_tools_dir}/source/extinst.opencl.debuginfo.100.grammar.json"
 }
 
 ###############################################################################
@@ -223,6 +360,13 @@
     "src/writer/writer.h",
   ]
 
+  deps = [
+    ":tint_core_enums_unified1",
+    ":tint_core_tables_unified1",
+    ":tint_language_header_cldebuginfo100",
+    ":tint_language_header_debuginfo",
+  ]
+
   configs += [ ":tint_common_config" ]
 
   if (build_with_chromium) {
@@ -231,14 +375,6 @@
   }
 }
 
-config("libtint_spv_config") {
-  include_dirs = [
-    "${tint_spirv_tools_dir}/",
-    "${tint_spirv_tools_dir}/include",
-    "${target_gen_dir}/${tint_spirv_tools_gen}",
-  ]
-}
-
 source_set("libtint_spv_reader_src") {
   sources = [
     "src/reader/spirv/enum_converter.cc",
@@ -255,15 +391,15 @@
   ]
 
   deps = [
-    "${tint_spirv_headers_dir}/:spv_headers",
+    ":tint_core_enums_unified1",
+    ":tint_core_tables_unified1",
+    ":tint_language_header_cldebuginfo100",
+    ":tint_language_header_debuginfo",
     "${tint_spirv_tools_dir}/:spvtools_opt",
     "${tint_spirv_tools_dir}/:spvtools_val",
   ]
 
-  configs += [
-    ":tint_common_config",
-    ":libtint_spv_config",
-  ]
+  configs += [ ":tint_common_config" ]
 
   if (build_with_chromium) {
     configs -= [ "//build/config/compiler:chromium_code" ]
@@ -287,12 +423,7 @@
     "src/writer/spirv/operand.h",
   ]
 
-  deps = [ "${tint_spirv_headers_dir}/:spv_headers" ]
-
-  configs += [
-    ":tint_common_config",
-    ":libtint_spv_config",
-  ]
+  configs += [ ":tint_common_config" ]
 
   if (build_with_chromium) {
     configs -= [ "//build/config/compiler:chromium_code" ]
@@ -535,10 +666,7 @@
     "src/reader/spirv/spirv_tools_helpers_test.h",
   ]
 
-  deps = [ "${tint_spirv_headers_dir}/:spv_headers" ]
-
   configs += [
-    ":libtint_spv_config",
     ":tint_common_config",
     ":tint_unittests_config",
   ]
@@ -574,10 +702,8 @@
     "src/writer/spirv/spv_dump.cc",
     "src/writer/spirv/spv_dump.h",
   ]
-  deps = [ "${tint_spirv_headers_dir}/:spv_headers" ]
 
   configs += [
-    ":libtint_spv_config",
     ":tint_common_config",
     ":tint_unittests_config",
   ]
@@ -770,13 +896,35 @@
 }
 
 ###############################################################################
+# Fuzzers - Libfuzzer based fuzzing targets for Chromium
+###############################################################################
+# To run the fuzzers outside of Chromium, use the CMake based builds.
+
+if (build_with_chromium) {
+  import("//testing/libfuzzer/fuzzer_test.gni")
+
+  source_set("tint_wgsl_reader_fuzzer_src") {
+    sources = [ "fuzzers/tint_wgsl_reader_fuzzer.cc" ]
+    configs += [ ":tint_common_config" ]
+  }
+
+  fuzzer_test("tint_wgsl_reader_fuzzer") {
+    sources = []
+    deps = [
+      ":libtint",
+      ":tint_wgsl_reader_fuzzer_src",
+    ]
+  }
+}
+
+###############################################################################
 # Samples - Executables exposing command line functionality
 ###############################################################################
 
 config("tint_exe_config") {
   include_dirs = []
   if (tint_build_spv_reader || tint_build_spv_writer) {
-    include_dirs = [ "${tint_spirv_tools_dir}/include/" ]
+    include_dirs += [ "${tint_spirv_tools_dir}/include/" ]
   }
 }
 
@@ -788,8 +936,10 @@
     deps += [ "${tint_spirv_headers_dir}/:spv_headers" ]
   }
 
-  configs += [ ":tint_common_config" ]
-  configs += [ ":tint_exe_config" ]
+  configs += [
+    ":tint_common_config",
+    ":tint_exe_config",
+  ]
 
   if (build_with_chromium) {
     configs -= [ "//build/config/compiler:chromium_code" ]
diff --git a/src/ast/import.cc b/src/ast/import.cc
index 536a90a..b86c6b1 100644
--- a/src/ast/import.cc
+++ b/src/ast/import.cc
@@ -19,6 +19,8 @@
 namespace tint {
 namespace ast {
 
+Import::Import() = default;
+
 Import::Import(const std::string& path, const std::string& name)
     : Node(), path_(path), name_(name) {}
 
@@ -27,6 +29,8 @@
                const std::string& name)
     : Node(source), path_(path), name_(name) {}
 
+Import::Import(Import&&) = default;
+
 Import::~Import() = default;
 
 bool Import::IsValid() const {
diff --git a/src/ast/import.h b/src/ast/import.h
index 9c73f3e..5f40188 100644
--- a/src/ast/import.h
+++ b/src/ast/import.h
@@ -30,7 +30,7 @@
 class Import : public Node {
  public:
   /// Create a new empty import statement
-  Import() = default;
+  Import();
   /// Create a new import statement
   /// @param path The import path e.g. GLSL.std.450
   /// @param name The import reference name e.g. std
@@ -43,7 +43,7 @@
          const std::string& path,
          const std::string& name);
   /// Move constructor
-  Import(Import&&) = default;
+  Import(Import&&);
 
   ~Import() override;
 
diff --git a/src/reader/spirv/function.cc b/src/reader/spirv/function.cc
index 4883ebb..426a4b1 100644
--- a/src/reader/spirv/function.cc
+++ b/src/reader/spirv/function.cc
@@ -697,7 +697,7 @@
   }
 
   if (inst.opcode() == SpvOpBitcast) {
-    auto target_ty = parser_impl_.ConvertType(inst.type_id());
+    auto* target_ty = parser_impl_.ConvertType(inst.type_id());
     return {target_ty,
             std::make_unique<ast::AsExpression>(target_ty, operand(0).expr)};
   }
diff --git a/src/reader/spirv/function_arithmetic_test.cc b/src/reader/spirv/function_arithmetic_test.cc
index f194de7..c92a84c 100644
--- a/src/reader/spirv/function_arithmetic_test.cc
+++ b/src/reader/spirv/function_arithmetic_test.cc
@@ -127,7 +127,7 @@
      OpReturn
      OpFunctionEnd
   )";
-  auto p = parser(test::Assemble(assembly));
+  auto* p = parser(test::Assemble(assembly));
   ASSERT_TRUE(p->BuildAndParseInternalModuleExceptFunctions());
   FunctionEmitter fe(p, *spirv_function(100));
   EXPECT_TRUE(fe.EmitBody()) << p->error();
@@ -154,7 +154,7 @@
      OpReturn
      OpFunctionEnd
   )";
-  auto p = parser(test::Assemble(assembly));
+  auto* p = parser(test::Assemble(assembly));
   ASSERT_TRUE(p->BuildAndParseInternalModuleExceptFunctions());
   FunctionEmitter fe(p, *spirv_function(100));
   EXPECT_TRUE(fe.EmitBody()) << p->error();
@@ -183,7 +183,7 @@
      OpReturn
      OpFunctionEnd
   )";
-  auto p = parser(test::Assemble(assembly));
+  auto* p = parser(test::Assemble(assembly));
   ASSERT_TRUE(p->BuildAndParseInternalModuleExceptFunctions());
   FunctionEmitter fe(p, *spirv_function(100));
   EXPECT_TRUE(fe.EmitBody()) << p->error();
@@ -212,7 +212,7 @@
      OpReturn
      OpFunctionEnd
   )";
-  auto p = parser(test::Assemble(assembly));
+  auto* p = parser(test::Assemble(assembly));
   ASSERT_TRUE(p->BuildAndParseInternalModuleExceptFunctions());
   FunctionEmitter fe(p, *spirv_function(100));
   EXPECT_TRUE(fe.EmitBody()) << p->error();
@@ -243,7 +243,7 @@
      OpReturn
      OpFunctionEnd
   )";
-  auto p = parser(test::Assemble(assembly));
+  auto* p = parser(test::Assemble(assembly));
   ASSERT_TRUE(p->BuildAndParseInternalModuleExceptFunctions());
   FunctionEmitter fe(p, *spirv_function(100));
   EXPECT_TRUE(fe.EmitBody()) << p->error();
@@ -274,7 +274,7 @@
      OpReturn
      OpFunctionEnd
   )";
-  auto p = parser(test::Assemble(assembly));
+  auto* p = parser(test::Assemble(assembly));
   ASSERT_TRUE(p->BuildAndParseInternalModuleExceptFunctions());
   FunctionEmitter fe(p, *spirv_function(100));
   EXPECT_TRUE(fe.EmitBody()) << p->error();
@@ -307,7 +307,7 @@
      OpReturn
      OpFunctionEnd
   )";
-  auto p = parser(test::Assemble(assembly));
+  auto* p = parser(test::Assemble(assembly));
   ASSERT_TRUE(p->BuildAndParseInternalModuleExceptFunctions());
   FunctionEmitter fe(p, *spirv_function(100));
   EXPECT_TRUE(fe.EmitBody()) << p->error();
@@ -340,7 +340,7 @@
      OpReturn
      OpFunctionEnd
   )";
-  auto p = parser(test::Assemble(assembly));
+  auto* p = parser(test::Assemble(assembly));
   ASSERT_TRUE(p->BuildAndParseInternalModuleExceptFunctions());
   FunctionEmitter fe(p, *spirv_function(100));
   EXPECT_TRUE(fe.EmitBody()) << p->error();
@@ -375,7 +375,7 @@
      OpReturn
      OpFunctionEnd
   )";
-  auto p = parser(test::Assemble(assembly));
+  auto* p = parser(test::Assemble(assembly));
   ASSERT_TRUE(p->BuildAndParseInternalModuleExceptFunctions());
   FunctionEmitter fe(p, *spirv_function(100));
   EXPECT_TRUE(fe.EmitBody()) << p->error();
@@ -402,7 +402,7 @@
      OpReturn
      OpFunctionEnd
   )";
-  auto p = parser(test::Assemble(assembly));
+  auto* p = parser(test::Assemble(assembly));
   ASSERT_TRUE(p->BuildAndParseInternalModuleExceptFunctions());
   FunctionEmitter fe(p, *spirv_function(100));
   EXPECT_TRUE(fe.EmitBody()) << p->error();
@@ -680,7 +680,7 @@
      OpReturn
      OpFunctionEnd
   )";
-  auto p = parser(test::Assemble(assembly));
+  auto* p = parser(test::Assemble(assembly));
   ASSERT_TRUE(p->BuildAndParseInternalModuleExceptFunctions())
       << p->error() << "\n"
       << assembly;
@@ -715,7 +715,7 @@
      OpReturn
      OpFunctionEnd
   )";
-  auto p = parser(test::Assemble(assembly));
+  auto* p = parser(test::Assemble(assembly));
   ASSERT_TRUE(p->BuildAndParseInternalModuleExceptFunctions())
       << p->error() << "\n"
       << assembly;
@@ -824,7 +824,7 @@
      OpReturn
      OpFunctionEnd
   )";
-  auto p = parser(test::Assemble(assembly));
+  auto* p = parser(test::Assemble(assembly));
   ASSERT_TRUE(p->BuildAndParseInternalModuleExceptFunctions())
       << p->error() << "\n"
       << assembly;
@@ -859,7 +859,7 @@
      OpReturn
      OpFunctionEnd
   )";
-  auto p = parser(test::Assemble(assembly));
+  auto* p = parser(test::Assemble(assembly));
   ASSERT_TRUE(p->BuildAndParseInternalModuleExceptFunctions())
       << p->error() << "\n"
       << assembly;
diff --git a/src/reader/spirv/function_bit_test.cc b/src/reader/spirv/function_bit_test.cc
index c2b133c..e32421e 100644
--- a/src/reader/spirv/function_bit_test.cc
+++ b/src/reader/spirv/function_bit_test.cc
@@ -384,7 +384,7 @@
      OpReturn
      OpFunctionEnd
   )";
-  auto p = parser(test::Assemble(assembly));
+  auto* p = parser(test::Assemble(assembly));
   ASSERT_TRUE(p->BuildAndParseInternalModuleExceptFunctions());
   FunctionEmitter fe(p, *spirv_function(100));
   EXPECT_TRUE(fe.EmitBody()) << p->error();
@@ -411,7 +411,7 @@
      OpReturn
      OpFunctionEnd
   )";
-  auto p = parser(test::Assemble(assembly));
+  auto* p = parser(test::Assemble(assembly));
   ASSERT_TRUE(p->BuildAndParseInternalModuleExceptFunctions());
   FunctionEmitter fe(p, *spirv_function(100));
   EXPECT_TRUE(fe.EmitBody()) << p->error();
@@ -440,7 +440,7 @@
      OpReturn
      OpFunctionEnd
   )";
-  auto p = parser(test::Assemble(assembly));
+  auto* p = parser(test::Assemble(assembly));
   ASSERT_TRUE(p->BuildAndParseInternalModuleExceptFunctions());
   FunctionEmitter fe(p, *spirv_function(100));
   EXPECT_TRUE(fe.EmitBody()) << p->error();
@@ -469,7 +469,7 @@
      OpReturn
      OpFunctionEnd
   )";
-  auto p = parser(test::Assemble(assembly));
+  auto* p = parser(test::Assemble(assembly));
   ASSERT_TRUE(p->BuildAndParseInternalModuleExceptFunctions());
   FunctionEmitter fe(p, *spirv_function(100));
   EXPECT_TRUE(fe.EmitBody()) << p->error();
@@ -496,7 +496,7 @@
      OpReturn
      OpFunctionEnd
   )";
-  auto p = parser(test::Assemble(assembly));
+  auto* p = parser(test::Assemble(assembly));
   ASSERT_TRUE(p->BuildAndParseInternalModuleExceptFunctions());
   FunctionEmitter fe(p, *spirv_function(100));
   EXPECT_TRUE(fe.EmitBody()) << p->error();
@@ -527,7 +527,7 @@
      OpReturn
      OpFunctionEnd
   )";
-  auto p = parser(test::Assemble(assembly));
+  auto* p = parser(test::Assemble(assembly));
   ASSERT_TRUE(p->BuildAndParseInternalModuleExceptFunctions());
   FunctionEmitter fe(p, *spirv_function(100));
   EXPECT_TRUE(fe.EmitBody()) << p->error();
@@ -560,7 +560,7 @@
      OpReturn
      OpFunctionEnd
   )";
-  auto p = parser(test::Assemble(assembly));
+  auto* p = parser(test::Assemble(assembly));
   ASSERT_TRUE(p->BuildAndParseInternalModuleExceptFunctions());
   FunctionEmitter fe(p, *spirv_function(100));
   EXPECT_TRUE(fe.EmitBody()) << p->error();
@@ -592,7 +592,7 @@
      OpReturn
      OpFunctionEnd
   )";
-  auto p = parser(test::Assemble(assembly));
+  auto* p = parser(test::Assemble(assembly));
   ASSERT_TRUE(p->BuildAndParseInternalModuleExceptFunctions());
   FunctionEmitter fe(p, *spirv_function(100));
   EXPECT_TRUE(fe.EmitBody()) << p->error();
diff --git a/src/reader/spirv/function_conversion_test.cc b/src/reader/spirv/function_conversion_test.cc
index bdb3f90..49aa594 100644
--- a/src/reader/spirv/function_conversion_test.cc
+++ b/src/reader/spirv/function_conversion_test.cc
@@ -71,7 +71,7 @@
      OpReturn
      OpFunctionEnd
   )";
-  auto p = parser(test::Assemble(assembly));
+  auto* p = parser(test::Assemble(assembly));
   ASSERT_TRUE(p->BuildAndParseInternalModuleExceptFunctions());
   FunctionEmitter fe(p, *spirv_function(100));
   EXPECT_TRUE(fe.EmitBody()) << p->error();
@@ -97,7 +97,7 @@
      OpReturn
      OpFunctionEnd
   )";
-  auto p = parser(test::Assemble(assembly));
+  auto* p = parser(test::Assemble(assembly));
   ASSERT_TRUE(p->BuildAndParseInternalModuleExceptFunctions());
   FunctionEmitter fe(p, *spirv_function(100));
   EXPECT_TRUE(fe.EmitBody()) << p->error();
diff --git a/src/reader/spirv/function_logical_test.cc b/src/reader/spirv/function_logical_test.cc
index fe46afe..bf480b0 100644
--- a/src/reader/spirv/function_logical_test.cc
+++ b/src/reader/spirv/function_logical_test.cc
@@ -202,7 +202,7 @@
      OpReturn
      OpFunctionEnd
   )";
-  auto p = parser(test::Assemble(assembly));
+  auto* p = parser(test::Assemble(assembly));
   ASSERT_TRUE(p->BuildAndParseInternalModuleExceptFunctions());
   FunctionEmitter fe(p, *spirv_function(100));
   EXPECT_TRUE(fe.EmitBody()) << p->error();
diff --git a/src/reader/spirv/parser_impl.cc b/src/reader/spirv/parser_impl.cc
index e057bf8..7016e5e 100644
--- a/src/reader/spirv/parser_impl.cc
+++ b/src/reader/spirv/parser_impl.cc
@@ -172,6 +172,17 @@
 
 }  // namespace
 
+TypedExpression::TypedExpression() : type(nullptr), expr(nullptr) {}
+
+TypedExpression::TypedExpression(ast::type::Type* t,
+                                 std::unique_ptr<ast::Expression> e)
+    : type(t), expr(std::move(e)) {}
+
+TypedExpression::TypedExpression(TypedExpression&& other)
+    : type(other.type), expr(std::move(other.expr)) {}
+
+TypedExpression::~TypedExpression() {}
+
 ParserImpl::ParserImpl(Context* ctx, const std::vector<uint32_t>& spv_binary)
     : Reader(ctx),
       spv_binary_(spv_binary),
@@ -509,9 +520,9 @@
 ast::type::Type* ParserImpl::ConvertType(
     const spvtools::opt::analysis::Integer* int_ty) {
   if (int_ty->width() == 32) {
-    auto signed_ty =
+    auto* signed_ty =
         ctx_.type_mgr().Get(std::make_unique<ast::type::I32Type>());
-    auto unsigned_ty =
+    auto* unsigned_ty =
         ctx_.type_mgr().Get(std::make_unique<ast::type::U32Type>());
     signed_type_for_[unsigned_ty] = signed_ty;
     unsigned_type_for_[signed_ty] = unsigned_ty;
diff --git a/src/reader/spirv/parser_impl.h b/src/reader/spirv/parser_impl.h
index 4811e78..743a5b2 100644
--- a/src/reader/spirv/parser_impl.h
+++ b/src/reader/spirv/parser_impl.h
@@ -55,16 +55,16 @@
 // An AST expression with its type.
 struct TypedExpression {
   /// Dummy constructor
-  TypedExpression() : type(nullptr), expr(nullptr) {}
+  TypedExpression();
   /// Constructor
   /// @param t the type
   /// @param e the expression
-  TypedExpression(ast::type::Type* t, std::unique_ptr<ast::Expression> e)
-      : type(t), expr(std::move(e)) {}
+  TypedExpression(ast::type::Type* t, std::unique_ptr<ast::Expression> e);
   /// Move constructor
   /// @param other the other typed expression
-  TypedExpression(TypedExpression&& other)
-      : type(other.type), expr(std::move(other.expr)) {}
+  TypedExpression(TypedExpression&& other);
+  /// Destructor
+  ~TypedExpression();
   /// The type
   ast::type::Type* type;
   /// The expression
diff --git a/src/type_determiner_test.cc b/src/type_determiner_test.cc
index 0f4da0d..fe22fde 100644
--- a/src/type_determiner_test.cc
+++ b/src/type_determiner_test.cc
@@ -1685,7 +1685,7 @@
       td()->GetImportData({0, 0}, "GLSL.std.450", param.name, params, &id);
   ASSERT_NE(type, nullptr);
   EXPECT_TRUE(type->is_float_vector());
-  EXPECT_EQ(type->AsVector()->size(), 3);
+  EXPECT_EQ(type->AsVector()->size(), 3u);
   EXPECT_EQ(id, param.value);
 }
 
@@ -1924,7 +1924,7 @@
       td()->GetImportData({0, 0}, "GLSL.std.450", param.name, params, &id);
   ASSERT_NE(type, nullptr);
   EXPECT_TRUE(type->is_float_vector());
-  EXPECT_EQ(type->AsVector()->size(), 3);
+  EXPECT_EQ(type->AsVector()->size(), 3u);
   EXPECT_EQ(id, param.value);
 }
 
@@ -2332,7 +2332,7 @@
       td()->GetImportData({0, 0}, "GLSL.std.450", param.name, params, &id);
   ASSERT_NE(type, nullptr);
   EXPECT_TRUE(type->is_float_vector());
-  EXPECT_EQ(type->AsVector()->size(), 3);
+  EXPECT_EQ(type->AsVector()->size(), 3u);
   EXPECT_EQ(id, param.value);
 }
 
diff --git a/tint_overrides_with_defaults.gni b/tint_overrides_with_defaults.gni
index a8861ea..67f683c 100644
--- a/tint_overrides_with_defaults.gni
+++ b/tint_overrides_with_defaults.gni
@@ -17,6 +17,11 @@
 # This file contains Tint-related build flags.
 
 declare_args() {
+  # Path to tint checkout
+  if (!defined(tint_root_dir)) {
+    tint_root_dir = "//"
+  }
+
   # Path to spirv-tools checkout
   if (!defined(tint_spirv_tools_dir)) {
     tint_spirv_tools_dir = "//third_party/spirv-tools"
@@ -37,10 +42,6 @@
     tint_spirv_headers_dir = "//third_party/spirv-headers"
   }
 
-  # Generate documentation
-  # TODO(rharrison): Implement documentation support
-  tint_build_doc = false
-
   # Build the SPIR-V input reader
   if (!defined(tint_build_spv_reader)) {
     tint_build_spv_reader = false
@@ -61,10 +62,6 @@
     tint_build_wgsl_writer = false
   }
 
-  # Generate fuzzers
-  # TODO(rharrison): Implement fuzzer support
-  tint_build_fuzzers = false
-
   # Enable memory sanitizer
   # TODO(rharrison): Implement sanitizer support
   tint_enable_msan = false