Add (more) comprehensive goldens for enums.

This includes commented out enums whose underlying type is `bool`. Those are broken!

PiperOrigin-RevId: 506724056
diff --git a/rs_bindings_from_cc/test/golden/enums.h b/rs_bindings_from_cc/test/golden/enums.h
new file mode 100644
index 0000000..1689b8c
--- /dev/null
+++ b/rs_bindings_from_cc/test/golden/enums.h
@@ -0,0 +1,28 @@
+// Part of the Crubit project, under the Apache License v2.0 with LLVM
+// Exceptions. See /LICENSE for license information.
+// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
+
+#ifndef CRUBIT_RS_BINDINGS_FROM_CC_TEST_GOLDEN_ENUMS_H_
+#define CRUBIT_RS_BINDINGS_FROM_CC_TEST_GOLDEN_ENUMS_H_
+
+enum Empty {};
+enum EmptyBool : bool {};
+enum EmptyInt : unsigned int {};
+enum EmptyChar : char {};
+
+// TODO(b/265024558): Uncomment this:
+// enum NonEmptyBool : bool { kBool1, kBool2 = true };
+enum NonEmptyInt : unsigned int { kInt1, kInt2 = 4294967295 };
+enum NonEmptyChar : char { kChar1, kChar2 = 'a' };
+
+enum class EmptyClass {};
+enum class EmptyBoolClass : bool {};
+enum class EmptyIntClass : int {};
+enum class EmptyCharClass : char {};
+
+// TODO(b/265024558): Uncomment this:
+// enum class NonEmptyBoolClass : bool { k1, k2 = true };
+enum class NonEmptyIntClass : unsigned int { k1, k2 = 4294967295 };
+enum class NonEmptyCharClass : char { k1, k2 = 'a' };
+
+#endif  // CRUBIT_RS_BINDINGS_FROM_CC_TEST_GOLDEN_ENUMS_H_
diff --git a/rs_bindings_from_cc/test/golden/enums_rs_api.rs b/rs_bindings_from_cc/test/golden/enums_rs_api.rs
new file mode 100644
index 0000000..5e50917
--- /dev/null
+++ b/rs_bindings_from_cc/test/golden/enums_rs_api.rs
@@ -0,0 +1,214 @@
+// Part of the Crubit project, under the Apache License v2.0 with LLVM
+// Exceptions. See /LICENSE for license information.
+// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
+
+// Automatically @generated Rust bindings for the following C++ target:
+// //rs_bindings_from_cc/test/golden:enums_cc
+
+#![rustfmt::skip]
+#![feature(custom_inner_attributes)]
+#![allow(stable_features)]
+#![allow(non_camel_case_types)]
+#![allow(non_snake_case)]
+#![allow(non_upper_case_globals)]
+#![deny(warnings)]
+
+// Part of the Crubit project, under the Apache License v2.0 with LLVM
+// Exceptions. See /LICENSE for license information.
+// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
+
+#[repr(transparent)]
+#[derive(Debug, PartialEq, Eq, Copy, Clone, Hash, PartialOrd, Ord)]
+pub struct Empty(u32);
+impl Empty {}
+impl From<u32> for Empty {
+    fn from(value: u32) -> Empty {
+        Empty(value)
+    }
+}
+impl From<Empty> for u32 {
+    fn from(value: Empty) -> u32 {
+        value.0
+    }
+}
+
+#[repr(transparent)]
+#[derive(Debug, PartialEq, Eq, Copy, Clone, Hash, PartialOrd, Ord)]
+pub struct EmptyBool(bool);
+impl EmptyBool {}
+impl From<bool> for EmptyBool {
+    fn from(value: bool) -> EmptyBool {
+        EmptyBool(value)
+    }
+}
+impl From<EmptyBool> for bool {
+    fn from(value: EmptyBool) -> bool {
+        value.0
+    }
+}
+
+#[repr(transparent)]
+#[derive(Debug, PartialEq, Eq, Copy, Clone, Hash, PartialOrd, Ord)]
+pub struct EmptyInt(u32);
+impl EmptyInt {}
+impl From<u32> for EmptyInt {
+    fn from(value: u32) -> EmptyInt {
+        EmptyInt(value)
+    }
+}
+impl From<EmptyInt> for u32 {
+    fn from(value: EmptyInt) -> u32 {
+        value.0
+    }
+}
+
+#[repr(transparent)]
+#[derive(Debug, PartialEq, Eq, Copy, Clone, Hash, PartialOrd, Ord)]
+pub struct EmptyChar(u8);
+impl EmptyChar {}
+impl From<u8> for EmptyChar {
+    fn from(value: u8) -> EmptyChar {
+        EmptyChar(value)
+    }
+}
+impl From<EmptyChar> for u8 {
+    fn from(value: EmptyChar) -> u8 {
+        value.0
+    }
+}
+
+#[repr(transparent)]
+#[derive(Debug, PartialEq, Eq, Copy, Clone, Hash, PartialOrd, Ord)]
+pub struct NonEmptyInt(u32);
+impl NonEmptyInt {
+    pub const kInt1: NonEmptyInt = NonEmptyInt(0);
+    pub const kInt2: NonEmptyInt = NonEmptyInt(4294967295);
+}
+impl From<u32> for NonEmptyInt {
+    fn from(value: u32) -> NonEmptyInt {
+        NonEmptyInt(value)
+    }
+}
+impl From<NonEmptyInt> for u32 {
+    fn from(value: NonEmptyInt) -> u32 {
+        value.0
+    }
+}
+
+#[repr(transparent)]
+#[derive(Debug, PartialEq, Eq, Copy, Clone, Hash, PartialOrd, Ord)]
+pub struct NonEmptyChar(u8);
+impl NonEmptyChar {
+    pub const kChar1: NonEmptyChar = NonEmptyChar(0);
+    pub const kChar2: NonEmptyChar = NonEmptyChar(97);
+}
+impl From<u8> for NonEmptyChar {
+    fn from(value: u8) -> NonEmptyChar {
+        NonEmptyChar(value)
+    }
+}
+impl From<NonEmptyChar> for u8 {
+    fn from(value: NonEmptyChar) -> u8 {
+        value.0
+    }
+}
+
+#[repr(transparent)]
+#[derive(Debug, PartialEq, Eq, Copy, Clone, Hash, PartialOrd, Ord)]
+pub struct EmptyClass(i32);
+impl EmptyClass {}
+impl From<i32> for EmptyClass {
+    fn from(value: i32) -> EmptyClass {
+        EmptyClass(value)
+    }
+}
+impl From<EmptyClass> for i32 {
+    fn from(value: EmptyClass) -> i32 {
+        value.0
+    }
+}
+
+#[repr(transparent)]
+#[derive(Debug, PartialEq, Eq, Copy, Clone, Hash, PartialOrd, Ord)]
+pub struct EmptyBoolClass(bool);
+impl EmptyBoolClass {}
+impl From<bool> for EmptyBoolClass {
+    fn from(value: bool) -> EmptyBoolClass {
+        EmptyBoolClass(value)
+    }
+}
+impl From<EmptyBoolClass> for bool {
+    fn from(value: EmptyBoolClass) -> bool {
+        value.0
+    }
+}
+
+#[repr(transparent)]
+#[derive(Debug, PartialEq, Eq, Copy, Clone, Hash, PartialOrd, Ord)]
+pub struct EmptyIntClass(i32);
+impl EmptyIntClass {}
+impl From<i32> for EmptyIntClass {
+    fn from(value: i32) -> EmptyIntClass {
+        EmptyIntClass(value)
+    }
+}
+impl From<EmptyIntClass> for i32 {
+    fn from(value: EmptyIntClass) -> i32 {
+        value.0
+    }
+}
+
+#[repr(transparent)]
+#[derive(Debug, PartialEq, Eq, Copy, Clone, Hash, PartialOrd, Ord)]
+pub struct EmptyCharClass(u8);
+impl EmptyCharClass {}
+impl From<u8> for EmptyCharClass {
+    fn from(value: u8) -> EmptyCharClass {
+        EmptyCharClass(value)
+    }
+}
+impl From<EmptyCharClass> for u8 {
+    fn from(value: EmptyCharClass) -> u8 {
+        value.0
+    }
+}
+
+#[repr(transparent)]
+#[derive(Debug, PartialEq, Eq, Copy, Clone, Hash, PartialOrd, Ord)]
+pub struct NonEmptyIntClass(u32);
+impl NonEmptyIntClass {
+    pub const k1: NonEmptyIntClass = NonEmptyIntClass(0);
+    pub const k2: NonEmptyIntClass = NonEmptyIntClass(4294967295);
+}
+impl From<u32> for NonEmptyIntClass {
+    fn from(value: u32) -> NonEmptyIntClass {
+        NonEmptyIntClass(value)
+    }
+}
+impl From<NonEmptyIntClass> for u32 {
+    fn from(value: NonEmptyIntClass) -> u32 {
+        value.0
+    }
+}
+
+#[repr(transparent)]
+#[derive(Debug, PartialEq, Eq, Copy, Clone, Hash, PartialOrd, Ord)]
+pub struct NonEmptyCharClass(u8);
+impl NonEmptyCharClass {
+    pub const k1: NonEmptyCharClass = NonEmptyCharClass(0);
+    pub const k2: NonEmptyCharClass = NonEmptyCharClass(97);
+}
+impl From<u8> for NonEmptyCharClass {
+    fn from(value: u8) -> NonEmptyCharClass {
+        NonEmptyCharClass(value)
+    }
+}
+impl From<NonEmptyCharClass> for u8 {
+    fn from(value: NonEmptyCharClass) -> u8 {
+        value.0
+    }
+}
+
+// CRUBIT_RS_BINDINGS_FROM_CC_TEST_GOLDEN_ENUMS_H_
+
+const _: () = assert!(::std::mem::size_of::<Option<&i32>>() == ::std::mem::size_of::<&i32>());
diff --git a/rs_bindings_from_cc/test/golden/enums_rs_api_impl.cc b/rs_bindings_from_cc/test/golden/enums_rs_api_impl.cc
new file mode 100644
index 0000000..da5308c
--- /dev/null
+++ b/rs_bindings_from_cc/test/golden/enums_rs_api_impl.cc
@@ -0,0 +1,19 @@
+// Part of the Crubit project, under the Apache License v2.0 with LLVM
+// Exceptions. See /LICENSE for license information.
+// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
+
+// Automatically @generated Rust bindings for the following C++ target:
+// //rs_bindings_from_cc/test/golden:enums_cc
+
+#include <memory>
+
+#include "support/internal/cxx20_backports.h"
+#include "support/internal/offsetof.h"
+
+// Public headers of the C++ library being wrapped.
+#include "rs_bindings_from_cc/test/golden/enums.h"
+
+#pragma clang diagnostic push
+#pragma clang diagnostic ignored "-Wthread-safety-analysis"
+
+#pragma clang diagnostic pop
diff --git a/rs_bindings_from_cc/test/golden/types.h b/rs_bindings_from_cc/test/golden/types.h
index a249255..bd2e24f 100644
--- a/rs_bindings_from_cc/test/golden/types.h
+++ b/rs_bindings_from_cc/test/golden/types.h
@@ -88,8 +88,6 @@
 
 inline void VoidReturningFunction() {}
 
-enum Color : unsigned int { kRed, kBlue, kLimeGreen = 4294967295 };
-
 // Note especially the use of references. If we convert those to pointers,
 // this becomes un-compilable. The syntax here is awful, but this is a function
 // returning a function. In ML-like syntax:
diff --git a/rs_bindings_from_cc/test/golden/types_rs_api.rs b/rs_bindings_from_cc/test/golden/types_rs_api.rs
index 8f65c42..c7d3851 100644
--- a/rs_bindings_from_cc/test/golden/types_rs_api.rs
+++ b/rs_bindings_from_cc/test/golden/types_rs_api.rs
@@ -157,38 +157,19 @@
     unsafe { crate::detail::__rust_thunk___Z21VoidReturningFunctionv() }
 }
 
-#[repr(transparent)]
-#[derive(Debug, PartialEq, Eq, Copy, Clone, Hash, PartialOrd, Ord)]
-pub struct Color(u32);
-impl Color {
-    pub const kRed: Color = Color(0);
-    pub const kBlue: Color = Color(1);
-    pub const kLimeGreen: Color = Color(4294967295);
-}
-impl From<u32> for Color {
-    fn from(value: u32) -> Color {
-        Color(value)
-    }
-}
-impl From<Color> for u32 {
-    fn from(value: Color) -> u32 {
-        value.0
-    }
-}
-
 /// Note especially the use of references. If we convert those to pointers,
 /// this becomes un-compilable. The syntax here is awful, but this is a function
 /// returning a function. In ML-like syntax:
 /// FunctionPointerReturningFunction : () -> (const int&, int*) -> int&
 ///
-/// Generated from: rs_bindings_from_cc/test/golden/types.h;l=97
+/// Generated from: rs_bindings_from_cc/test/golden/types.h;l=95
 #[inline(always)]
 pub fn FunctionPointerReturningFunction() -> Option<extern "C" fn(*const i32, *mut i32) -> *mut i32>
 {
     unsafe { crate::detail::__rust_thunk___Z32FunctionPointerReturningFunctionv() }
 }
 
-/// Generated from: rs_bindings_from_cc/test/golden/types.h;l=101
+/// Generated from: rs_bindings_from_cc/test/golden/types.h;l=99
 #[inline(always)]
 pub unsafe fn FunctionWithVoidPointers(
     __param_0: *mut ::std::os::raw::c_void,