There was a typo in the original commit where the diagnostic context was not being popped,
however popping the context still causes issues while bootstrapping.
For now, just mark -Warray-bounds as a warning to fix bootstrap on trunk and think about
a proper fix (probably adding a push and pop on every file including rust-fmt.h...) later if
the C++ warning issue is still not fixed.
gcc/rust/ChangeLog:
* ast/rust-fmt.h: Simplify diagnostic avoidance.
#include "optional.h"
// PR122498 "rust-enabled bootstrap is broken after r16-4897"
-#pragma GCC diagnostic push
#pragma GCC diagnostic warning "-Warray-bounds"
namespace Rust {
} // namespace Fmt
} // namespace Rust
-// PR122498 "rust-enabled bootstrap is broken after r16-4897"
-#pragma GCC diagnostic push
-
#endif // !RUST_FMT_H