Skip to content

Commit

Permalink
Rollup merge of #128664 - fuzzypixelz:add-codegen-ssa-debug-impls, r=…
Browse files Browse the repository at this point in the history
…lcnr

Add `Debug` impls to API types in `rustc_codegen_ssa`

Some types used in `rustc_codegen_ssa`'s interface traits are missing `Debug` impls. Though I did not smear `#[derive(Debug)]` all over the crate (some structs are quite large).
  • Loading branch information
matthiaskrgr authored Aug 5, 2024
2 parents 9d924d1 + 9411844 commit 48e47a6
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
10 changes: 5 additions & 5 deletions compiler/rustc_codegen_ssa/src/common.rs
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ use rustc_span::Span;

use crate::traits::*;

#[derive(Copy, Clone)]
#[derive(Copy, Clone, Debug)]
pub enum IntPredicate {
IntEQ,
IntNE,
Expand All @@ -22,7 +22,7 @@ pub enum IntPredicate {
IntSLE,
}

#[derive(Copy, Clone)]
#[derive(Copy, Clone, Debug)]
pub enum RealPredicate {
RealPredicateFalse,
RealOEQ,
Expand All @@ -42,7 +42,7 @@ pub enum RealPredicate {
RealPredicateTrue,
}

#[derive(Copy, Clone, PartialEq)]
#[derive(Copy, Clone, PartialEq, Debug)]
pub enum AtomicRmwBinOp {
AtomicXchg,
AtomicAdd,
Expand All @@ -57,7 +57,7 @@ pub enum AtomicRmwBinOp {
AtomicUMin,
}

#[derive(Copy, Clone)]
#[derive(Copy, Clone, Debug)]
pub enum AtomicOrdering {
Unordered,
Relaxed,
Expand All @@ -67,7 +67,7 @@ pub enum AtomicOrdering {
SequentiallyConsistent,
}

#[derive(Copy, Clone)]
#[derive(Copy, Clone, Debug)]
pub enum SynchronizationScope {
SingleThread,
CrossThread,
Expand Down
2 changes: 1 addition & 1 deletion compiler/rustc_codegen_ssa/src/traits/builder.rs
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ use crate::mir::operand::{OperandRef, OperandValue};
use crate::mir::place::{PlaceRef, PlaceValue};
use crate::MemFlags;

#[derive(Copy, Clone)]
#[derive(Copy, Clone, Debug)]
pub enum OverflowOp {
Add,
Sub,
Expand Down

0 comments on commit 48e47a6

Please sign in to comment.