Skip to main content

## structurally_same_type

# Function structurally_same_type

Source

    fn structurally_same_type<'tcx>(
        tcx: TyCtxt<'tcx>,
        typing_env: TypingEnv<'tcx>,
        a: Ty<'tcx>,
        b: Ty<'tcx>,
    ) -> bool

Expand description

Checks whether two types are structurally the same enough that the declarations shouldn’t clash. We need this so we don’t emit a lint when two modules both declare an extern struct, with the same members (as the declarations shouldn’t clash).