mirror of
https://github.com/carbon-language/carbon-lang.git
synced 2026-09-24 15:10:12 +01:00
Support LP64 platforms such as Darwin where int64_t is long long. (#7596)
Add `Core.CppCompat.[U]Long64` to represent a 64-bit long that is not `i64`. Treat it as being "just slightly smaller than" `i64`, like we treat `Core.CppCompat.LongLong64` as being "just slightly larger than" `i64`, so that we get implicit conversions `Cpp.long` -> `i64` -> `Cpp.long_long` on all targets. This follows the direction of proposal #5448, and seems like the obvious extension of the `[U]Long32` and `[U]LongLong64` types added in #6275 for targets of this "shape". Assisted-by: Gemini via Antigravity
This commit is contained in:
@@ -21,6 +21,14 @@ class CppCompat.ULong32 {
|
||||
adapt u32;
|
||||
}
|
||||
|
||||
class CppCompat.Long64 {
|
||||
adapt i64;
|
||||
}
|
||||
|
||||
class CppCompat.ULong64 {
|
||||
adapt u64;
|
||||
}
|
||||
|
||||
class CppCompat.LongLong64 {
|
||||
adapt i64;
|
||||
}
|
||||
@@ -31,6 +39,8 @@ class CppCompat.ULongLong64 {
|
||||
|
||||
impl CppCompat.Long32 as UnformedInit {}
|
||||
impl CppCompat.ULong32 as UnformedInit {}
|
||||
impl CppCompat.Long64 as UnformedInit {}
|
||||
impl CppCompat.ULong64 as UnformedInit {}
|
||||
impl CppCompat.LongLong64 as UnformedInit {}
|
||||
impl CppCompat.ULongLong64 as UnformedInit {}
|
||||
|
||||
@@ -44,6 +54,14 @@ impl CppCompat.ULong32 as Copy {
|
||||
fn Op(self) -> Self = "primitive_copy";
|
||||
}
|
||||
|
||||
impl CppCompat.Long64 as Copy {
|
||||
fn Op(self) -> Self = "primitive_copy";
|
||||
}
|
||||
|
||||
impl CppCompat.ULong64 as Copy {
|
||||
fn Op(self) -> Self = "primitive_copy";
|
||||
}
|
||||
|
||||
impl CppCompat.LongLong64 as Copy {
|
||||
fn Op(self) -> Self = "primitive_copy";
|
||||
}
|
||||
@@ -67,7 +85,7 @@ final impl CppCompat.Long32 as ImplicitAs(IntLiteral) {
|
||||
fn Convert(self) -> IntLiteral = "int.convert_checked";
|
||||
}
|
||||
|
||||
// TODO: ImplicitAs from Int(N) to Long32 if N < 32.
|
||||
// TODO: ImplicitAs from Int(N) to Long32 if N <= 32.
|
||||
impl i32 as ImplicitAs(CppCompat.Long32) {
|
||||
fn Convert(self) -> CppCompat.Long32 = "int.convert";
|
||||
}
|
||||
@@ -97,7 +115,7 @@ final impl CppCompat.ULong32 as ImplicitAs(IntLiteral) {
|
||||
fn Convert(self) -> IntLiteral = "int.convert_checked";
|
||||
}
|
||||
|
||||
// TODO: ImplicitAs from UInt(N) to ULong32 if N < 32.
|
||||
// TODO: ImplicitAs from UInt(N) to ULong32 if N <= 32.
|
||||
impl u32 as ImplicitAs(CppCompat.ULong32) {
|
||||
fn Convert(self) -> CppCompat.ULong32 = "int.convert";
|
||||
}
|
||||
@@ -107,6 +125,55 @@ final impl CppCompat.ULong32 as ImplicitAs(u64) {
|
||||
fn Convert(self) -> u64 = "int.convert";
|
||||
}
|
||||
|
||||
impl IntLiteral as ImplicitAs(CppCompat.Long64) {
|
||||
fn Convert(self) -> CppCompat.Long64 = "int.convert_checked";
|
||||
}
|
||||
|
||||
// TODO: Remove this once `ImplicitAs` extends `As`.
|
||||
impl IntLiteral as As(CppCompat.Long64) {
|
||||
fn Convert(self) -> CppCompat.Long64 = "int.convert_checked";
|
||||
}
|
||||
|
||||
final impl CppCompat.Long64 as ImplicitAs(IntLiteral) {
|
||||
fn Convert(self) -> IntLiteral = "int.convert_checked";
|
||||
}
|
||||
|
||||
// TODO: ImplicitAs from Int(N) to Long64 if N < 64.
|
||||
// N == 64 is explicitly skipped, as Long64 is considered to
|
||||
// be between i63 and i64.
|
||||
// TODO: Ratify this in a proposal.
|
||||
impl i32 as ImplicitAs(CppCompat.Long64) {
|
||||
fn Convert(self) -> CppCompat.Long64 = "int.convert";
|
||||
}
|
||||
|
||||
// TODO: ImplicitAs from Long64 to Int(N) if N >= 64.
|
||||
final impl CppCompat.Long64 as ImplicitAs(i64) {
|
||||
fn Convert(self) -> i64 = "int.convert";
|
||||
}
|
||||
|
||||
impl IntLiteral as ImplicitAs(CppCompat.ULong64) {
|
||||
fn Convert(self) -> CppCompat.ULong64 = "int.convert_checked";
|
||||
}
|
||||
|
||||
// TODO: Remove this once `ImplicitAs` extends `As`.
|
||||
impl IntLiteral as As(CppCompat.ULong64) {
|
||||
fn Convert(self) -> CppCompat.ULong64 = "int.convert_checked";
|
||||
}
|
||||
|
||||
final impl CppCompat.ULong64 as ImplicitAs(IntLiteral) {
|
||||
fn Convert(self) -> IntLiteral = "int.convert_checked";
|
||||
}
|
||||
|
||||
// TODO: ImplicitAs from UInt(N) to ULong64 if N < 64.
|
||||
impl u32 as ImplicitAs(CppCompat.ULong64) {
|
||||
fn Convert(self) -> CppCompat.ULong64 = "int.convert";
|
||||
}
|
||||
|
||||
// TODO: ImplicitAs from ULong64 to UInt(N) if N >= 64.
|
||||
final impl CppCompat.ULong64 as ImplicitAs(u64) {
|
||||
fn Convert(self) -> u64 = "int.convert";
|
||||
}
|
||||
|
||||
impl IntLiteral as ImplicitAs(CppCompat.LongLong64) {
|
||||
fn Convert(self) -> CppCompat.LongLong64 = "int.convert_checked";
|
||||
}
|
||||
@@ -120,7 +187,7 @@ final impl CppCompat.LongLong64 as ImplicitAs(IntLiteral) {
|
||||
fn Convert(self) -> IntLiteral = "int.convert_checked";
|
||||
}
|
||||
|
||||
// TODO: ImplicitAs from Int(N) to LongLong64 if N < 64.
|
||||
// TODO: ImplicitAs from Int(N) to LongLong64 if N <= 64.
|
||||
impl i64 as ImplicitAs(CppCompat.LongLong64) {
|
||||
fn Convert(self) -> CppCompat.LongLong64 = "int.convert";
|
||||
}
|
||||
@@ -146,7 +213,7 @@ final impl CppCompat.ULongLong64 as ImplicitAs(IntLiteral) {
|
||||
fn Convert(self) -> IntLiteral = "int.convert_checked";
|
||||
}
|
||||
|
||||
// TODO: ImplicitAs from UInt(N) to ULongLong64 if N < 64.
|
||||
// TODO: ImplicitAs from UInt(N) to ULongLong64 if N <= 64.
|
||||
impl u64 as ImplicitAs(CppCompat.ULongLong64) {
|
||||
fn Convert(self) -> CppCompat.ULongLong64 = "int.convert";
|
||||
}
|
||||
@@ -156,15 +223,115 @@ final impl CppCompat.ULongLong64 as ImplicitAs(u128) {
|
||||
fn Convert(self) -> u128 = "int.convert";
|
||||
}
|
||||
|
||||
// TODO: As from Long32 to Int(N) if N < 32.
|
||||
// TODO: As from ULong32 to UInt(N) if N < 32.
|
||||
// TODO: As from LongLong64 to Int(N) if N < 64.
|
||||
// TODO: As from ULongLong64 to UInt(N) if N < 64.
|
||||
// TODO: As from Long32 to Int(N) if N <= 32.
|
||||
// TODO: As from ULong32 to UInt(N) if N <= 32.
|
||||
// TODO: As from Long64 to Int(N) if N < 64.
|
||||
// TODO: As from ULong64 to UInt(N) if N < 64.
|
||||
// TODO: As from LongLong64 to Int(N) if N <= 64.
|
||||
// TODO: As from ULongLong64 to UInt(N) if N <= 64.
|
||||
// TODO: As from Int(N) to Long32 if N > 32.
|
||||
// TODO: As from UInt(N) to ULong32 if N > 32.
|
||||
// TODO: As from Int(N) to Long64 if N >= 64.
|
||||
// TODO: As from UInt(N) to ULong64 if N >= 64.
|
||||
// TODO: As from Int(N) to LongLong64 if N > 64.
|
||||
// TODO: As from UInt(N) to ULongLong64 if N > 64.
|
||||
|
||||
impl forall [From: IntLiteral] Int(From) as As(CppCompat.Long32) {
|
||||
fn Convert(self) -> CppCompat.Long32 = "int.convert";
|
||||
}
|
||||
impl forall [From: IntLiteral] UInt(From) as As(CppCompat.Long32) {
|
||||
fn Convert(self) -> CppCompat.Long32 = "int.convert";
|
||||
}
|
||||
impl forall [From: IntLiteral] Int(From) as As(CppCompat.Long64) {
|
||||
fn Convert(self) -> CppCompat.Long64 = "int.convert";
|
||||
}
|
||||
impl forall [From: IntLiteral] UInt(From) as As(CppCompat.Long64) {
|
||||
fn Convert(self) -> CppCompat.Long64 = "int.convert";
|
||||
}
|
||||
impl forall [From: IntLiteral] Int(From) as As(CppCompat.LongLong64) {
|
||||
fn Convert(self) -> CppCompat.LongLong64 = "int.convert";
|
||||
}
|
||||
impl forall [From: IntLiteral] UInt(From) as As(CppCompat.LongLong64) {
|
||||
fn Convert(self) -> CppCompat.LongLong64 = "int.convert";
|
||||
}
|
||||
impl forall [From: IntLiteral] Int(From) as As(CppCompat.ULong32) {
|
||||
fn Convert(self) -> CppCompat.ULong32 = "int.convert";
|
||||
}
|
||||
impl forall [From: IntLiteral] UInt(From) as As(CppCompat.ULong32) {
|
||||
fn Convert(self) -> CppCompat.ULong32 = "int.convert";
|
||||
}
|
||||
impl forall [From: IntLiteral] Int(From) as As(CppCompat.ULong64) {
|
||||
fn Convert(self) -> CppCompat.ULong64 = "int.convert";
|
||||
}
|
||||
impl forall [From: IntLiteral] UInt(From) as As(CppCompat.ULong64) {
|
||||
fn Convert(self) -> CppCompat.ULong64 = "int.convert";
|
||||
}
|
||||
impl forall [From: IntLiteral] Int(From) as As(CppCompat.ULongLong64) {
|
||||
fn Convert(self) -> CppCompat.ULongLong64 = "int.convert";
|
||||
}
|
||||
impl forall [From: IntLiteral] UInt(From) as As(CppCompat.ULongLong64) {
|
||||
fn Convert(self) -> CppCompat.ULongLong64 = "int.convert";
|
||||
}
|
||||
final impl forall [To: IntLiteral] CppCompat.Long32 as As(Int(To)) {
|
||||
fn Convert(self) -> Int(To) = "int.convert";
|
||||
}
|
||||
final impl forall [To: IntLiteral] CppCompat.Long32 as As(UInt(To)) {
|
||||
fn Convert(self) -> UInt(To) = "int.convert";
|
||||
}
|
||||
final impl forall [To: IntLiteral] CppCompat.Long64 as As(Int(To)) {
|
||||
fn Convert(self) -> Int(To) = "int.convert";
|
||||
}
|
||||
final impl forall [To: IntLiteral] CppCompat.Long64 as As(UInt(To)) {
|
||||
fn Convert(self) -> UInt(To) = "int.convert";
|
||||
}
|
||||
final impl forall [To: IntLiteral] CppCompat.LongLong64 as As(Int(To)) {
|
||||
fn Convert(self) -> Int(To) = "int.convert";
|
||||
}
|
||||
final impl forall [To: IntLiteral] CppCompat.LongLong64 as As(UInt(To)) {
|
||||
fn Convert(self) -> UInt(To) = "int.convert";
|
||||
}
|
||||
final impl forall [To: IntLiteral] CppCompat.ULong32 as As(Int(To)) {
|
||||
fn Convert(self) -> Int(To) = "int.convert";
|
||||
}
|
||||
final impl forall [To: IntLiteral] CppCompat.ULong32 as As(UInt(To)) {
|
||||
fn Convert(self) -> UInt(To) = "int.convert";
|
||||
}
|
||||
final impl forall [To: IntLiteral] CppCompat.ULong64 as As(Int(To)) {
|
||||
fn Convert(self) -> Int(To) = "int.convert";
|
||||
}
|
||||
final impl forall [To: IntLiteral] CppCompat.ULong64 as As(UInt(To)) {
|
||||
fn Convert(self) -> UInt(To) = "int.convert";
|
||||
}
|
||||
final impl forall [To: IntLiteral] CppCompat.ULongLong64 as As(Int(To)) {
|
||||
fn Convert(self) -> Int(To) = "int.convert";
|
||||
}
|
||||
final impl forall [To: IntLiteral] CppCompat.ULongLong64 as As(UInt(To)) {
|
||||
fn Convert(self) -> UInt(To) = "int.convert";
|
||||
}
|
||||
|
||||
// We only expect to have at most one of CppCompat.{Long32,Long64,LongLong64}
|
||||
// reachable in any given target, so we don't provide conversions between them.
|
||||
// But we do need to provide conversions between corresponding signed and
|
||||
// unsigned types.
|
||||
final impl CppCompat.Long32 as As(CppCompat.ULong32) {
|
||||
fn Convert(self) -> CppCompat.ULong32 = "int.convert";
|
||||
}
|
||||
final impl CppCompat.Long64 as As(CppCompat.ULong64) {
|
||||
fn Convert(self) -> CppCompat.ULong64 = "int.convert";
|
||||
}
|
||||
final impl CppCompat.LongLong64 as As(CppCompat.ULongLong64) {
|
||||
fn Convert(self) -> CppCompat.ULongLong64 = "int.convert";
|
||||
}
|
||||
final impl CppCompat.ULong32 as As(CppCompat.Long32) {
|
||||
fn Convert(self) -> CppCompat.Long32 = "int.convert";
|
||||
}
|
||||
final impl CppCompat.ULong64 as As(CppCompat.Long64) {
|
||||
fn Convert(self) -> CppCompat.Long64 = "int.convert";
|
||||
}
|
||||
final impl CppCompat.ULongLong64 as As(CppCompat.LongLong64) {
|
||||
fn Convert(self) -> CppCompat.LongLong64 = "int.convert";
|
||||
}
|
||||
|
||||
// Comparisons.
|
||||
|
||||
// - Homogeneous.
|
||||
@@ -183,6 +350,18 @@ final impl CppCompat.Long32 as OrderedWith(CppCompat.Long32) {
|
||||
fn GreaterOrEquivalent(self, other: Self) -> bool = "int.greater_eq";
|
||||
}
|
||||
|
||||
final impl CppCompat.Long64 as EqWith(CppCompat.Long64) {
|
||||
fn Equal(self, other: Self) -> bool = "int.eq";
|
||||
fn NotEqual(self, other: Self) -> bool = "int.neq";
|
||||
}
|
||||
|
||||
final impl CppCompat.Long64 as OrderedWith(CppCompat.Long64) {
|
||||
fn Less(self, other: Self) -> bool = "int.less";
|
||||
fn LessOrEquivalent(self, other: Self) -> bool = "int.less_eq";
|
||||
fn Greater(self, other: Self) -> bool = "int.greater";
|
||||
fn GreaterOrEquivalent(self, other: Self) -> bool = "int.greater_eq";
|
||||
}
|
||||
|
||||
final impl CppCompat.LongLong64 as EqWith(CppCompat.LongLong64) {
|
||||
fn Equal(self, other: Self) -> bool = "int.eq";
|
||||
fn NotEqual(self, other: Self) -> bool = "int.neq";
|
||||
@@ -211,6 +390,18 @@ impl forall [T: ImplicitAs(CppCompat.Long32)] CppCompat.Long32 as OrderedWith(T)
|
||||
fn GreaterOrEquivalent(self, other: Self) -> bool = "int.greater_eq";
|
||||
}
|
||||
|
||||
impl forall [T: ImplicitAs(CppCompat.Long64)] CppCompat.Long64 as EqWith(T) {
|
||||
fn Equal(self, other: Self) -> bool = "int.eq";
|
||||
fn NotEqual(self, other: Self) -> bool = "int.neq";
|
||||
}
|
||||
|
||||
impl forall [T: ImplicitAs(CppCompat.Long64)] CppCompat.Long64 as OrderedWith(T) {
|
||||
fn Less(self, other: Self) -> bool = "int.less";
|
||||
fn LessOrEquivalent(self, other: Self) -> bool = "int.less_eq";
|
||||
fn Greater(self, other: Self) -> bool = "int.greater";
|
||||
fn GreaterOrEquivalent(self, other: Self) -> bool = "int.greater_eq";
|
||||
}
|
||||
|
||||
impl forall [T: ImplicitAs(CppCompat.LongLong64)]
|
||||
CppCompat.LongLong64 as EqWith(T) {
|
||||
fn Equal(self, other: Self) -> bool = "int.eq";
|
||||
@@ -239,6 +430,18 @@ impl forall [T: ImplicitAs(CppCompat.Long32)] T as OrderedWith(CppCompat.Long32)
|
||||
fn GreaterOrEquivalent(self: CppCompat.Long32, other: CppCompat.Long32) -> bool = "int.greater_eq";
|
||||
}
|
||||
|
||||
impl forall [T: ImplicitAs(CppCompat.Long64)] T as EqWith(CppCompat.Long64) {
|
||||
fn Equal(self: CppCompat.Long64, other: CppCompat.Long64) -> bool = "int.eq";
|
||||
fn NotEqual(self: CppCompat.Long64, other: CppCompat.Long64) -> bool = "int.neq";
|
||||
}
|
||||
|
||||
impl forall [T: ImplicitAs(CppCompat.Long64)] T as OrderedWith(CppCompat.Long64) {
|
||||
fn Less(self: CppCompat.Long64, other: CppCompat.Long64) -> bool = "int.less";
|
||||
fn LessOrEquivalent(self: CppCompat.Long64, other: CppCompat.Long64) -> bool = "int.less_eq";
|
||||
fn Greater(self: CppCompat.Long64, other: CppCompat.Long64) -> bool = "int.greater";
|
||||
fn GreaterOrEquivalent(self: CppCompat.Long64, other: CppCompat.Long64) -> bool = "int.greater_eq";
|
||||
}
|
||||
|
||||
impl forall [T: ImplicitAs(CppCompat.LongLong64)]
|
||||
T as EqWith(CppCompat.LongLong64) {
|
||||
fn Equal(self: CppCompat.LongLong64,
|
||||
@@ -259,7 +462,7 @@ impl forall [T: ImplicitAs(CppCompat.LongLong64)]
|
||||
other: CppCompat.LongLong64) -> bool = "int.greater_eq";
|
||||
}
|
||||
|
||||
// TODO: Comparisons for ULong32, ULongLong64.
|
||||
// TODO: Comparisons for ULong32, ULong64, ULongLong64.
|
||||
|
||||
// Arithmetic.
|
||||
|
||||
@@ -291,6 +494,32 @@ final impl CppCompat.Long32 as ModWith(Self) where .Result = Self {
|
||||
fn Op(self, other: Self) -> Self = "int.smod";
|
||||
}
|
||||
|
||||
// - CppCompat.Long64
|
||||
|
||||
final impl CppCompat.Long64 as Negate where .Result = Self {
|
||||
fn Op(self) -> Self = "int.snegate";
|
||||
}
|
||||
|
||||
final impl CppCompat.Long64 as AddWith(Self) where .Result = Self {
|
||||
fn Op(self, other: Self) -> Self = "int.sadd";
|
||||
}
|
||||
|
||||
final impl CppCompat.Long64 as SubWith(Self) where .Result = Self {
|
||||
fn Op(self, other: Self) -> Self = "int.ssub";
|
||||
}
|
||||
|
||||
final impl CppCompat.Long64 as MulWith(Self) where .Result = Self {
|
||||
fn Op(self, other: Self) -> Self = "int.smul";
|
||||
}
|
||||
|
||||
final impl CppCompat.Long64 as DivWith(Self) where .Result = Self {
|
||||
fn Op(self, other: Self) -> Self = "int.sdiv";
|
||||
}
|
||||
|
||||
final impl CppCompat.Long64 as ModWith(Self) where .Result = Self {
|
||||
fn Op(self, other: Self) -> Self = "int.smod";
|
||||
}
|
||||
|
||||
// - CppCompat.LongLong64
|
||||
|
||||
final impl CppCompat.LongLong64 as Negate where .Result = Self {
|
||||
@@ -346,6 +575,33 @@ impl forall [T: ImplicitAs(CppCompat.Long32)]
|
||||
fn Op(self: CppCompat.Long32, other: CppCompat.Long32) -> CppCompat.Long32 = "int.smod";
|
||||
}
|
||||
|
||||
// - CppCompat.Long64 on left-hand side.
|
||||
|
||||
impl forall [T: ImplicitAs(CppCompat.Long64)]
|
||||
CppCompat.Long64 as AddWith(T) where .Result = CppCompat.Long64 {
|
||||
fn Op(self: CppCompat.Long64, other: CppCompat.Long64) -> CppCompat.Long64 = "int.sadd";
|
||||
}
|
||||
|
||||
impl forall [T: ImplicitAs(CppCompat.Long64)]
|
||||
CppCompat.Long64 as SubWith(T) where .Result = CppCompat.Long64 {
|
||||
fn Op(self: CppCompat.Long64, other: CppCompat.Long64) -> CppCompat.Long64 = "int.ssub";
|
||||
}
|
||||
|
||||
impl forall [T: ImplicitAs(CppCompat.Long64)]
|
||||
CppCompat.Long64 as MulWith(T) where .Result = CppCompat.Long64 {
|
||||
fn Op(self: CppCompat.Long64, other: CppCompat.Long64) -> CppCompat.Long64 = "int.smul";
|
||||
}
|
||||
|
||||
impl forall [T: ImplicitAs(CppCompat.Long64)]
|
||||
CppCompat.Long64 as DivWith(T) where .Result = CppCompat.Long64 {
|
||||
fn Op(self: CppCompat.Long64, other: CppCompat.Long64) -> CppCompat.Long64 = "int.sdiv";
|
||||
}
|
||||
|
||||
impl forall [T: ImplicitAs(CppCompat.Long64)]
|
||||
CppCompat.Long64 as ModWith(T) where .Result = CppCompat.Long64 {
|
||||
fn Op(self: CppCompat.Long64, other: CppCompat.Long64) -> CppCompat.Long64 = "int.smod";
|
||||
}
|
||||
|
||||
// - CppCompat.LongLong64 on left-hand side.
|
||||
|
||||
impl forall [T: ImplicitAs(CppCompat.LongLong64)]
|
||||
@@ -405,6 +661,33 @@ impl forall [T: ImplicitAs(CppCompat.Long32)]
|
||||
fn Op(self: CppCompat.Long32, other: CppCompat.Long32) -> CppCompat.Long32 = "int.smod";
|
||||
}
|
||||
|
||||
// - CppCompat.Long64 on right-hand side.
|
||||
|
||||
impl forall [T: ImplicitAs(CppCompat.Long64)]
|
||||
T as AddWith(CppCompat.Long64) where .Result = CppCompat.Long64 {
|
||||
fn Op(self: CppCompat.Long64, other: CppCompat.Long64) -> CppCompat.Long64 = "int.sadd";
|
||||
}
|
||||
|
||||
impl forall [T: ImplicitAs(CppCompat.Long64)]
|
||||
T as SubWith(CppCompat.Long64) where .Result = CppCompat.Long64 {
|
||||
fn Op(self: CppCompat.Long64, other: CppCompat.Long64) -> CppCompat.Long64 = "int.ssub";
|
||||
}
|
||||
|
||||
impl forall [T: ImplicitAs(CppCompat.Long64)]
|
||||
T as MulWith(CppCompat.Long64) where .Result = CppCompat.Long64 {
|
||||
fn Op(self: CppCompat.Long64, other: CppCompat.Long64) -> CppCompat.Long64 = "int.smul";
|
||||
}
|
||||
|
||||
impl forall [T: ImplicitAs(CppCompat.Long64)]
|
||||
T as DivWith(CppCompat.Long64) where .Result = CppCompat.Long64 {
|
||||
fn Op(self: CppCompat.Long64, other: CppCompat.Long64) -> CppCompat.Long64 = "int.sdiv";
|
||||
}
|
||||
|
||||
impl forall [T: ImplicitAs(CppCompat.Long64)]
|
||||
T as ModWith(CppCompat.Long64) where .Result = CppCompat.Long64 {
|
||||
fn Op(self: CppCompat.Long64, other: CppCompat.Long64) -> CppCompat.Long64 = "int.smod";
|
||||
}
|
||||
|
||||
// - CppCompat.LongLong64 on right-hand side.
|
||||
|
||||
impl forall [T: ImplicitAs(CppCompat.LongLong64)]
|
||||
@@ -437,7 +720,7 @@ impl forall [T: ImplicitAs(CppCompat.LongLong64)]
|
||||
other: CppCompat.LongLong64) -> CppCompat.LongLong64 = "int.smod";
|
||||
}
|
||||
|
||||
// TODO: ULong32, ULongLong64: arithmetic operators.
|
||||
// TODO: ULong32, ULong64, ULongLong64: arithmetic operators.
|
||||
|
||||
// Bitwise operators.
|
||||
|
||||
@@ -469,6 +752,32 @@ final impl CppCompat.Long32 as RightShiftWith(Self) where .Result = Self {
|
||||
fn Op(self, other: Self) -> Self = "int.right_shift";
|
||||
}
|
||||
|
||||
// - CppCompat.Long64
|
||||
|
||||
final impl CppCompat.Long64 as BitComplement where .Result = Self {
|
||||
fn Op(self) -> Self = "int.complement";
|
||||
}
|
||||
|
||||
final impl CppCompat.Long64 as BitAndWith(Self) where .Result = Self {
|
||||
fn Op(self, other: Self) -> Self = "int.and";
|
||||
}
|
||||
|
||||
final impl CppCompat.Long64 as BitOrWith(Self) where .Result = Self {
|
||||
fn Op(self, other: Self) -> Self = "int.or";
|
||||
}
|
||||
|
||||
final impl CppCompat.Long64 as BitXorWith(Self) where .Result = Self {
|
||||
fn Op(self, other: Self) -> Self = "int.xor";
|
||||
}
|
||||
|
||||
final impl CppCompat.Long64 as LeftShiftWith(Self) where .Result = Self {
|
||||
fn Op(self, other: Self) -> Self = "int.left_shift";
|
||||
}
|
||||
|
||||
final impl CppCompat.Long64 as RightShiftWith(Self) where .Result = Self {
|
||||
fn Op(self, other: Self) -> Self = "int.right_shift";
|
||||
}
|
||||
|
||||
// - CppCompat.LongLong64
|
||||
|
||||
final impl CppCompat.LongLong64 as BitComplement where .Result = Self {
|
||||
@@ -529,6 +838,38 @@ impl forall [T: ImplicitAs(CppCompat.Long32)]
|
||||
other: CppCompat.Long32) -> CppCompat.Long32 = "int.right_shift";
|
||||
}
|
||||
|
||||
// - CppCompat.Long64 on left-hand side.
|
||||
|
||||
impl forall [T: ImplicitAs(CppCompat.Long64)]
|
||||
CppCompat.Long64 as BitAndWith(T) where .Result = CppCompat.Long64 {
|
||||
fn Op(self: CppCompat.Long64,
|
||||
other:CppCompat.Long64) -> CppCompat.Long64 = "int.and";
|
||||
}
|
||||
|
||||
impl forall [T: ImplicitAs(CppCompat.Long64)]
|
||||
CppCompat.Long64 as BitOrWith(T) where .Result = CppCompat.Long64 {
|
||||
fn Op(self: CppCompat.Long64,
|
||||
other: CppCompat.Long64) -> CppCompat.Long64 = "int.or";
|
||||
}
|
||||
|
||||
impl forall [T: ImplicitAs(CppCompat.Long64)]
|
||||
CppCompat.Long64 as BitXorWith(T) where .Result = CppCompat.Long64 {
|
||||
fn Op(self: CppCompat.Long64,
|
||||
other: CppCompat.Long64) -> CppCompat.Long64 = "int.xor";
|
||||
}
|
||||
|
||||
impl forall [T: ImplicitAs(CppCompat.Long64)]
|
||||
CppCompat.Long64 as LeftShiftWith(T) where .Result = CppCompat.Long64 {
|
||||
fn Op(self: CppCompat.Long64,
|
||||
other: CppCompat.Long64) -> CppCompat.Long64 = "int.left_shift";
|
||||
}
|
||||
|
||||
impl forall [T: ImplicitAs(CppCompat.Long64)]
|
||||
CppCompat.Long64 as RightShiftWith(T) where .Result = CppCompat.Long64 {
|
||||
fn Op(self: CppCompat.Long64,
|
||||
other: CppCompat.Long64) -> CppCompat.Long64 = "int.right_shift";
|
||||
}
|
||||
|
||||
// - CppCompat.LongLong64 on left-hand side.
|
||||
|
||||
impl forall [T: ImplicitAs(CppCompat.LongLong64)]
|
||||
@@ -593,6 +934,38 @@ impl forall [T: ImplicitAs(CppCompat.Long32)]
|
||||
other: CppCompat.Long32) -> CppCompat.Long32 = "int.right_shift";
|
||||
}
|
||||
|
||||
// - CppCompat.Long64 on right-hand side.
|
||||
|
||||
impl forall [T: ImplicitAs(CppCompat.Long64)]
|
||||
T as BitAndWith(CppCompat.Long64) where .Result = CppCompat.Long64 {
|
||||
fn Op(self: CppCompat.Long64,
|
||||
other: CppCompat.Long64) -> CppCompat.Long64 = "int.and";
|
||||
}
|
||||
|
||||
impl forall [T: ImplicitAs(CppCompat.Long64)]
|
||||
T as BitOrWith(CppCompat.Long64) where .Result = CppCompat.Long64 {
|
||||
fn Op(self: CppCompat.Long64,
|
||||
other: CppCompat.Long64) -> CppCompat.Long64 = "int.or";
|
||||
}
|
||||
|
||||
impl forall [T: ImplicitAs(CppCompat.Long64)]
|
||||
T as BitXorWith(CppCompat.Long64) where .Result = CppCompat.Long64 {
|
||||
fn Op(self: CppCompat.Long64,
|
||||
other: CppCompat.Long64) -> CppCompat.Long64 = "int.xor";
|
||||
}
|
||||
|
||||
impl forall [T: ImplicitAs(CppCompat.Long64)]
|
||||
T as LeftShiftWith(CppCompat.Long64) where .Result = CppCompat.Long64 {
|
||||
fn Op(self: CppCompat.Long64,
|
||||
other: CppCompat.Long64) -> CppCompat.Long64 = "int.left_shift";
|
||||
}
|
||||
|
||||
impl forall [T: ImplicitAs(CppCompat.Long64)]
|
||||
T as RightShiftWith(CppCompat.Long64) where .Result = CppCompat.Long64 {
|
||||
fn Op(self: CppCompat.Long64,
|
||||
other: CppCompat.Long64) -> CppCompat.Long64 = "int.right_shift";
|
||||
}
|
||||
|
||||
// - CppCompat.LongLong64 on right-hand side.
|
||||
|
||||
impl forall [T: ImplicitAs(CppCompat.LongLong64)]
|
||||
@@ -625,7 +998,7 @@ impl forall [T: ImplicitAs(CppCompat.LongLong64)]
|
||||
other: CppCompat.LongLong64) -> CppCompat.LongLong64 = "int.right_shift";
|
||||
}
|
||||
|
||||
// TODO: ULong32, ULongLong64: bitwise operators.
|
||||
// TODO: ULong32, ULong64, ULongLong64: bitwise operators.
|
||||
|
||||
// Compound assignments.
|
||||
|
||||
@@ -658,6 +1031,33 @@ impl forall [U: ImplicitAs(CppCompat.Long32)]
|
||||
fn Op(ref self, other: Self) = "int.smod_assign";
|
||||
}
|
||||
|
||||
// - CppCompat.Long64
|
||||
|
||||
impl forall [U: ImplicitAs(CppCompat.Long64)]
|
||||
CppCompat.Long64 as AddAssignWith(U) {
|
||||
fn Op(ref self, other: Self) = "int.sadd_assign";
|
||||
}
|
||||
|
||||
impl forall [U: ImplicitAs(CppCompat.Long64)]
|
||||
CppCompat.Long64 as SubAssignWith(U) {
|
||||
fn Op(ref self, other: Self) = "int.ssub_assign";
|
||||
}
|
||||
|
||||
impl forall [U: ImplicitAs(CppCompat.Long64)]
|
||||
CppCompat.Long64 as MulAssignWith(U) {
|
||||
fn Op(ref self, other: Self) = "int.smul_assign";
|
||||
}
|
||||
|
||||
impl forall [U: ImplicitAs(CppCompat.Long64)]
|
||||
CppCompat.Long64 as DivAssignWith(U) {
|
||||
fn Op(ref self, other: Self) = "int.sdiv_assign";
|
||||
}
|
||||
|
||||
impl forall [U: ImplicitAs(CppCompat.Long64)]
|
||||
CppCompat.Long64 as ModAssignWith(U) {
|
||||
fn Op(ref self, other: Self) = "int.smod_assign";
|
||||
}
|
||||
|
||||
// - CppCompat.LongLong64
|
||||
|
||||
impl forall [U: ImplicitAs(CppCompat.LongLong64)]
|
||||
@@ -714,6 +1114,33 @@ impl forall [U: ImplicitAs(CppCompat.Long32)]
|
||||
fn Op(ref self, other: Self) = "int.right_shift_assign";
|
||||
}
|
||||
|
||||
// - CppCompat.Long64
|
||||
|
||||
impl forall [U: ImplicitAs(CppCompat.Long64)]
|
||||
CppCompat.Long64 as BitAndAssignWith(U) {
|
||||
fn Op(ref self, other: Self) = "int.and_assign";
|
||||
}
|
||||
|
||||
impl forall [U: ImplicitAs(CppCompat.Long64)]
|
||||
CppCompat.Long64 as BitOrAssignWith(U) {
|
||||
fn Op(ref self, other: Self) = "int.or_assign";
|
||||
}
|
||||
|
||||
impl forall [U: ImplicitAs(CppCompat.Long64)]
|
||||
CppCompat.Long64 as BitXorAssignWith(U) {
|
||||
fn Op(ref self, other: Self) = "int.xor_assign";
|
||||
}
|
||||
|
||||
impl forall [U: ImplicitAs(CppCompat.Long64)]
|
||||
CppCompat.Long64 as LeftShiftAssignWith(U) {
|
||||
fn Op(ref self, other: Self) = "int.left_shift_assign";
|
||||
}
|
||||
|
||||
impl forall [U: ImplicitAs(CppCompat.Long64)]
|
||||
CppCompat.Long64 as RightShiftAssignWith(U) {
|
||||
fn Op(ref self, other: Self) = "int.right_shift_assign";
|
||||
}
|
||||
|
||||
// - CppCompat.LongLong64
|
||||
|
||||
impl forall [U: ImplicitAs(CppCompat.LongLong64)]
|
||||
@@ -741,7 +1168,7 @@ impl forall [U: ImplicitAs(CppCompat.LongLong64)]
|
||||
fn Op(ref self, other: Self) = "int.right_shift_assign";
|
||||
}
|
||||
|
||||
// TODO: ULong32, ULongLong64: compound assignments.
|
||||
// TODO: ULong32, ULong64, ULongLong64: compound assignments.
|
||||
|
||||
// Increment and decrement.
|
||||
|
||||
@@ -759,6 +1186,20 @@ impl CppCompat.Long32 as Inc {
|
||||
}
|
||||
}
|
||||
|
||||
// - CppCompat.Long64
|
||||
|
||||
impl CppCompat.Long64 as Dec {
|
||||
fn Op(ref self) {
|
||||
self -= (1 as CppCompat.Long64);
|
||||
}
|
||||
}
|
||||
|
||||
impl CppCompat.Long64 as Inc {
|
||||
fn Op(ref self) {
|
||||
self += (1 as CppCompat.Long64);
|
||||
}
|
||||
}
|
||||
|
||||
// - CppCompat.LongLong64
|
||||
|
||||
impl CppCompat.LongLong64 as Dec {
|
||||
@@ -773,4 +1214,4 @@ impl CppCompat.LongLong64 as Inc {
|
||||
}
|
||||
}
|
||||
|
||||
// TODO: Increment/decrement operations for ULong32, ULongLong64.
|
||||
// TODO: Increment/decrement operations for ULong32, ULong64, ULongLong64.
|
||||
|
||||
@@ -60,6 +60,7 @@ CARBON_CORE_IDENTIFIER(LeftShiftWith)
|
||||
CARBON_CORE_IDENTIFIER(Less)
|
||||
CARBON_CORE_IDENTIFIER(LessOrEquivalent)
|
||||
CARBON_CORE_IDENTIFIER(Long32)
|
||||
CARBON_CORE_IDENTIFIER(Long64)
|
||||
CARBON_CORE_IDENTIFIER(LongLong64)
|
||||
CARBON_CORE_IDENTIFIER(ModAssignWith)
|
||||
CARBON_CORE_IDENTIFIER(ModWith)
|
||||
@@ -80,6 +81,7 @@ CARBON_CORE_IDENTIFIER(SubAssignWith)
|
||||
CARBON_CORE_IDENTIFIER(SubWith)
|
||||
CARBON_CORE_IDENTIFIER(UInt)
|
||||
CARBON_CORE_IDENTIFIER(ULong32)
|
||||
CARBON_CORE_IDENTIFIER(ULong64)
|
||||
CARBON_CORE_IDENTIFIER(ULongLong64)
|
||||
CARBON_CORE_IDENTIFIER(UnsafeAs)
|
||||
CARBON_CORE_IDENTIFIER(VoidBase)
|
||||
|
||||
@@ -15,6 +15,7 @@
|
||||
#include "clang/AST/RecordLayout.h"
|
||||
#include "clang/AST/UnresolvedSet.h"
|
||||
#include "clang/AST/VTableBuilder.h"
|
||||
#include "clang/Basic/TargetInfo.h"
|
||||
#include "clang/Frontend/CompilerInvocation.h"
|
||||
#include "clang/Lex/MacroInfo.h"
|
||||
#include "clang/Lex/Preprocessor.h"
|
||||
@@ -1109,17 +1110,48 @@ static auto MakeCppCompatType(Context& context, SemIR::LocId loc_id,
|
||||
LookupNameInCore(context, loc_id, {CoreIdentifier::CppCompat, name}));
|
||||
}
|
||||
|
||||
// Maps a C++ builtin integer type to a Carbon `Core.CppCompat` type.
|
||||
static auto MapBuiltinCppCompatIntegerType(Context& context,
|
||||
unsigned int cpp_width,
|
||||
unsigned int carbon_width,
|
||||
CoreIdentifier cpp_compat_name)
|
||||
-> TypeExpr {
|
||||
if (cpp_width != carbon_width) {
|
||||
return TypeExpr::None;
|
||||
auto GetIntNType(const clang::ASTContext& ast_context, unsigned width,
|
||||
bool is_signed) -> clang::QualType {
|
||||
const auto& target_info = ast_context.getTargetInfo();
|
||||
|
||||
// Work around Clang's getIntTypeForBitwidth being broken in various targets.
|
||||
auto target_type = clang::TargetInfo::IntType::NoInt;
|
||||
if (width == 64) {
|
||||
target_type =
|
||||
is_signed ? target_info.getInt64Type() : target_info.getUInt64Type();
|
||||
} else if (width == 16) {
|
||||
target_type =
|
||||
is_signed ? target_info.getInt16Type() : target_info.getUInt16Type();
|
||||
} else {
|
||||
target_type = target_info.getIntTypeByWidth(width, is_signed);
|
||||
}
|
||||
|
||||
return MakeCppCompatType(context, Parse::NodeId::None, cpp_compat_name);
|
||||
switch (target_type) {
|
||||
case clang::TargetInfo::NoInt:
|
||||
// Call getIntTypeForBitwidth to pick up its i128 handling.
|
||||
return ast_context.getIntTypeForBitwidth(width, is_signed);
|
||||
|
||||
case clang::TargetInfo::SignedChar:
|
||||
return ast_context.SignedCharTy;
|
||||
case clang::TargetInfo::UnsignedChar:
|
||||
return ast_context.UnsignedCharTy;
|
||||
case clang::TargetInfo::SignedShort:
|
||||
return ast_context.ShortTy;
|
||||
case clang::TargetInfo::UnsignedShort:
|
||||
return ast_context.UnsignedShortTy;
|
||||
case clang::TargetInfo::SignedInt:
|
||||
return ast_context.IntTy;
|
||||
case clang::TargetInfo::UnsignedInt:
|
||||
return ast_context.UnsignedIntTy;
|
||||
case clang::TargetInfo::SignedLong:
|
||||
return ast_context.LongTy;
|
||||
case clang::TargetInfo::UnsignedLong:
|
||||
return ast_context.UnsignedLongTy;
|
||||
case clang::TargetInfo::SignedLongLong:
|
||||
return ast_context.LongLongTy;
|
||||
case clang::TargetInfo::UnsignedLongLong:
|
||||
return ast_context.UnsignedLongLongTy;
|
||||
}
|
||||
}
|
||||
|
||||
// Maps a C++ builtin integer type to a Carbon type.
|
||||
@@ -1130,7 +1162,10 @@ static auto MapBuiltinIntegerType(Context& context, SemIR::LocId loc_id,
|
||||
clang::ASTContext& ast_context = context.ast_context();
|
||||
unsigned width = ast_context.getIntWidth(qual_type);
|
||||
bool is_signed = type.isSignedInteger();
|
||||
auto int_n_type = ast_context.getIntTypeForBitwidth(width, is_signed);
|
||||
|
||||
// Check whether the type is `intN_t` or `uintN_t`, and if so, map it to `iN`
|
||||
// or `uN` respectively.
|
||||
auto int_n_type = GetIntNType(ast_context, width, is_signed);
|
||||
if (clang::ASTContext::hasSameType(qual_type, int_n_type)) {
|
||||
TypeExpr type_expr =
|
||||
MakeIntType(context, context.ints().Add(width), is_signed);
|
||||
@@ -1144,26 +1179,41 @@ static auto MapBuiltinIntegerType(Context& context, SemIR::LocId loc_id,
|
||||
}
|
||||
return type_expr;
|
||||
}
|
||||
if (clang::ASTContext::hasSameType(qual_type, ast_context.CharTy)) {
|
||||
return ExprAsType(context, Parse::NodeId::None,
|
||||
MakeCharTypeLiteral(context, Parse::NodeId::None));
|
||||
}
|
||||
if (clang::ASTContext::hasSameType(qual_type, ast_context.LongTy)) {
|
||||
return MapBuiltinCppCompatIntegerType(context, width, 32,
|
||||
CoreIdentifier::Long32);
|
||||
}
|
||||
if (clang::ASTContext::hasSameType(qual_type, ast_context.UnsignedLongTy)) {
|
||||
return MapBuiltinCppCompatIntegerType(context, width, 32,
|
||||
CoreIdentifier::ULong32);
|
||||
}
|
||||
if (clang::ASTContext::hasSameType(qual_type, ast_context.LongLongTy)) {
|
||||
return MapBuiltinCppCompatIntegerType(context, width, 64,
|
||||
CoreIdentifier::LongLong64);
|
||||
}
|
||||
if (clang::ASTContext::hasSameType(qual_type,
|
||||
ast_context.UnsignedLongLongTy)) {
|
||||
return MapBuiltinCppCompatIntegerType(context, width, 64,
|
||||
CoreIdentifier::ULongLong64);
|
||||
|
||||
// Handle special cases for types that don't map to `iN` or `uN`.
|
||||
switch (type.getKind()) {
|
||||
case clang::BuiltinType::Char_S:
|
||||
case clang::BuiltinType::Char_U:
|
||||
return ExprAsType(context, Parse::NodeId::None,
|
||||
MakeCharTypeLiteral(context, Parse::NodeId::None));
|
||||
case clang::BuiltinType::Long:
|
||||
if (width == 32) {
|
||||
return MakeCppCompatType(context, loc_id, CoreIdentifier::Long32);
|
||||
}
|
||||
if (width == 64) {
|
||||
return MakeCppCompatType(context, loc_id, CoreIdentifier::Long64);
|
||||
}
|
||||
break;
|
||||
case clang::BuiltinType::ULong:
|
||||
if (width == 32) {
|
||||
return MakeCppCompatType(context, loc_id, CoreIdentifier::ULong32);
|
||||
}
|
||||
if (width == 64) {
|
||||
return MakeCppCompatType(context, loc_id, CoreIdentifier::ULong64);
|
||||
}
|
||||
break;
|
||||
case clang::BuiltinType::LongLong:
|
||||
if (width == 64) {
|
||||
return MakeCppCompatType(context, loc_id, CoreIdentifier::LongLong64);
|
||||
}
|
||||
break;
|
||||
case clang::BuiltinType::ULongLong:
|
||||
if (width == 64) {
|
||||
return MakeCppCompatType(context, loc_id, CoreIdentifier::ULongLong64);
|
||||
}
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
return TypeExpr::None;
|
||||
}
|
||||
|
||||
@@ -18,6 +18,7 @@
|
||||
#include "toolchain/sem_ir/ids.h"
|
||||
|
||||
namespace clang {
|
||||
class ASTContext;
|
||||
class CompilerInvocation;
|
||||
class IdentifierInfo;
|
||||
class VarDecl;
|
||||
@@ -82,6 +83,10 @@ inline auto ImportCppFunctionDecl(Context& context, SemIR::LocId loc_id,
|
||||
SemIR::ClangDeclKey::ForFunctionDecl(clang_decl, signature_id));
|
||||
}
|
||||
|
||||
// Returns the type that intN_t or uintN_t is an alias for.
|
||||
auto GetIntNType(const clang::ASTContext& ast_context, unsigned width,
|
||||
bool is_signed) -> clang::QualType;
|
||||
|
||||
// Imports a type from Clang to Carbon. Returns a `TypeExpr` which contains
|
||||
// both a `TypeId` and `TypeInstId`. All unimported dependencies are imported
|
||||
// first.
|
||||
|
||||
@@ -169,10 +169,10 @@ static auto TryMapClassType(Context& context, SemIR::ClassType class_type)
|
||||
bit_width, clang::FloatModeKind::NoFloat);
|
||||
}
|
||||
case SemIR::NumericTypeLiteralInfo::Int: {
|
||||
return ast_context.getIntTypeForBitwidth(bit_width, true);
|
||||
return GetIntNType(ast_context, bit_width, true);
|
||||
}
|
||||
case SemIR::NumericTypeLiteralInfo::UInt: {
|
||||
return ast_context.getIntTypeForBitwidth(bit_width, false);
|
||||
return GetIntNType(ast_context, bit_width, false);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -182,9 +182,15 @@ static auto TryMapClassType(Context& context, SemIR::ClassType class_type)
|
||||
case SemIR::RecognizedTypeInfo::CppLong32: {
|
||||
return VerifyIntegerTypeWidth(context, ast_context.LongTy, 32);
|
||||
}
|
||||
case SemIR::RecognizedTypeInfo::CppLong64: {
|
||||
return VerifyIntegerTypeWidth(context, ast_context.LongTy, 64);
|
||||
}
|
||||
case SemIR::RecognizedTypeInfo::CppULong32: {
|
||||
return VerifyIntegerTypeWidth(context, ast_context.UnsignedLongTy, 32);
|
||||
}
|
||||
case SemIR::RecognizedTypeInfo::CppULong64: {
|
||||
return VerifyIntegerTypeWidth(context, ast_context.UnsignedLongTy, 64);
|
||||
}
|
||||
case SemIR::RecognizedTypeInfo::CppLongLong64: {
|
||||
return VerifyIntegerTypeWidth(context, ast_context.LongLongTy, 64);
|
||||
}
|
||||
|
||||
@@ -19,8 +19,8 @@ template<typename T> struct A : Base {
|
||||
T n;
|
||||
};
|
||||
|
||||
using Aint = A<int>;
|
||||
using Along = A<long>;
|
||||
using Ai32 = A<int>;
|
||||
using Ai16 = A<short>;
|
||||
|
||||
// --- use_class_template.carbon
|
||||
|
||||
@@ -28,7 +28,7 @@ library "[[@TEST_NAME]]";
|
||||
|
||||
import Cpp library "class_template.h";
|
||||
|
||||
fn F(x: Cpp.Aint) -> i32 {
|
||||
fn F(x: Cpp.Ai32) -> i32 {
|
||||
// Trigger instantiation through name lookup.
|
||||
//@dump-sem-ir-begin
|
||||
x.f();
|
||||
@@ -36,7 +36,7 @@ fn F(x: Cpp.Aint) -> i32 {
|
||||
//@dump-sem-ir-end
|
||||
}
|
||||
|
||||
fn G(p: Cpp.Along*) -> Cpp.Base* {
|
||||
fn G(p: Cpp.Ai16*) -> Cpp.Base* {
|
||||
// Trigger instantiation through type completion.
|
||||
//@dump-sem-ir-begin
|
||||
return p;
|
||||
@@ -125,8 +125,8 @@ fn F() {
|
||||
// CHECK:STDOUT: %Copy.WithSelf.Op.type.d09: type = fn_type @Copy.WithSelf.Op, @Copy.WithSelf(%Copy.facet.987) [concrete]
|
||||
// CHECK:STDOUT: %.7a6: type = fn_type_with_self_type %Copy.WithSelf.Op.type.d09, %Copy.facet.987 [concrete]
|
||||
// CHECK:STDOUT: %Int.as.Copy.impl.Op.specific_fn: <specific function> = specific_function %Int.as.Copy.impl.Op.4f6, @Int.as.Copy.impl.Op(%int_32) [concrete]
|
||||
// CHECK:STDOUT: %A.26b: type = class_type @A.2 [concrete]
|
||||
// CHECK:STDOUT: %ptr.f2d: type = ptr_type %A.26b [concrete]
|
||||
// CHECK:STDOUT: %A.e3f: type = class_type @A.2 [concrete]
|
||||
// CHECK:STDOUT: %ptr.bc0: type = ptr_type %A.e3f [concrete]
|
||||
// CHECK:STDOUT: %ptr.0e0: type = ptr_type %Base [concrete]
|
||||
// CHECK:STDOUT: %Copy.impl_witness.428: <witness> = impl_witness imports.%Copy.impl_witness_table.4f1, @ptr.as.Copy.impl(%Base) [concrete]
|
||||
// CHECK:STDOUT: %ptr.as.Copy.impl.Op.type.136: type = fn_type @ptr.as.Copy.impl.Op, @ptr.as.Copy.impl(%Base) [concrete]
|
||||
@@ -168,10 +168,10 @@ fn F() {
|
||||
// CHECK:STDOUT: return %Int.as.Copy.impl.Op.call
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @G(%p.param: %ptr.f2d) -> out %return.param: %ptr.0e0 {
|
||||
// CHECK:STDOUT: fn @G(%p.param: %ptr.bc0) -> out %return.param: %ptr.0e0 {
|
||||
// CHECK:STDOUT: !entry:
|
||||
// CHECK:STDOUT: %p.ref: %ptr.f2d = name_ref p, %p
|
||||
// CHECK:STDOUT: %.loc17_11.1: ref %A.26b = deref %p.ref
|
||||
// CHECK:STDOUT: %p.ref: %ptr.bc0 = name_ref p, %p
|
||||
// CHECK:STDOUT: %.loc17_11.1: ref %A.e3f = deref %p.ref
|
||||
// CHECK:STDOUT: %.loc17_11.2: ref %Base = class_element_access %.loc17_11.1, element0
|
||||
// CHECK:STDOUT: %addr: %ptr.0e0 = addr_of %.loc17_11.2
|
||||
// CHECK:STDOUT: %.loc17_11.3: %ptr.0e0 = converted %p.ref, %addr
|
||||
|
||||
+1
@@ -3,6 +3,7 @@
|
||||
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
|
||||
//
|
||||
// INCLUDE-FILE: toolchain/testing/testdata/min_prelude/primitives.carbon
|
||||
// EXTRA-ARGS: --target=x86_64-linux-gnu
|
||||
//
|
||||
// AUTOUPDATE
|
||||
// TIP: To test this file alone, run:
|
||||
|
||||
+29
-3307
File diff suppressed because it is too large
Load Diff
@@ -3,6 +3,7 @@
|
||||
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
|
||||
//
|
||||
// INCLUDE-FILE: toolchain/testing/testdata/min_prelude/full.carbon
|
||||
// EXTRA-ARGS: --target=x86_64-linux-gnu
|
||||
//
|
||||
// AUTOUPDATE
|
||||
// TIP: To test this file alone, run:
|
||||
|
||||
+4069
File diff suppressed because it is too large
Load Diff
+10
-10
@@ -1101,7 +1101,7 @@ fn CopyUnsignedLong() {
|
||||
// CHECK:STDOUT: %As.impl_witness.d97: <witness> = impl_witness imports.%As.impl_witness_table.a2e [concrete]
|
||||
// CHECK:STDOUT: %As.facet: %As.type.cbc = facet_value Core.IntLiteral, (%As.impl_witness.d97) [concrete]
|
||||
// CHECK:STDOUT: %As.WithSelf.Convert.type.d45: type = fn_type @As.WithSelf.Convert, @As.WithSelf(%Cpp.long, %As.facet) [concrete]
|
||||
// CHECK:STDOUT: %.d2f: type = fn_type_with_self_type %As.WithSelf.Convert.type.d45, %As.facet [concrete]
|
||||
// CHECK:STDOUT: %.d2f4: type = fn_type_with_self_type %As.WithSelf.Convert.type.d45, %As.facet [concrete]
|
||||
// CHECK:STDOUT: %Core.IntLiteral.as.As.impl.Convert.type: type = fn_type @Core.IntLiteral.as.As.impl.Convert [concrete]
|
||||
// CHECK:STDOUT: %Core.IntLiteral.as.As.impl.Convert: %Core.IntLiteral.as.As.impl.Convert.type = struct_value () [concrete]
|
||||
// CHECK:STDOUT: %Core.IntLiteral.as.As.impl.Convert.bound: <bound method> = bound_method %int_1.5b8, %Core.IntLiteral.as.As.impl.Convert [concrete]
|
||||
@@ -1316,7 +1316,7 @@ fn CopyUnsignedLong() {
|
||||
// CHECK:STDOUT: %int_1.loc26: Core.IntLiteral = int_value 1 [concrete = constants.%int_1.5b8]
|
||||
// CHECK:STDOUT: %Cpp.ref.loc26: <namespace> = name_ref Cpp, imports.%Cpp [concrete = imports.%Cpp]
|
||||
// CHECK:STDOUT: %long.ref.loc26: type = name_ref long, constants.%Cpp.long [concrete = constants.%Cpp.long]
|
||||
// CHECK:STDOUT: %impl.elem0.loc26_30.1: %.d2f = impl_witness_access constants.%As.impl_witness.d97, element0 [concrete = constants.%Core.IntLiteral.as.As.impl.Convert]
|
||||
// CHECK:STDOUT: %impl.elem0.loc26_30.1: %.d2f4 = impl_witness_access constants.%As.impl_witness.d97, element0 [concrete = constants.%Core.IntLiteral.as.As.impl.Convert]
|
||||
// CHECK:STDOUT: %bound_method.loc26_30.1: <bound method> = bound_method %int_1.loc26, %impl.elem0.loc26_30.1 [concrete = constants.%Core.IntLiteral.as.As.impl.Convert.bound]
|
||||
// CHECK:STDOUT: %Core.IntLiteral.as.As.impl.Convert.call: init %Cpp.long = call %bound_method.loc26_30.1(%int_1.loc26) [concrete = constants.%int_1.9ce]
|
||||
// CHECK:STDOUT: %.loc26_30.1: %Cpp.long = value_of_initializer %Core.IntLiteral.as.As.impl.Convert.call [concrete = constants.%int_1.9ce]
|
||||
@@ -1514,10 +1514,10 @@ fn CopyUnsignedLong() {
|
||||
// CHECK:STDOUT: %Core.import_ref.adc9b: %Cpp.long.as.EqWith.impl.NotEqual.type.8e5 = import_ref Core//prelude/types/cpp/int, loc{{\d+_\d+}}, loaded [concrete = constants.%Cpp.long.as.EqWith.impl.NotEqual.a6a]
|
||||
// CHECK:STDOUT: %EqWith.impl_witness_table.48e = impl_witness_table (%Core.import_ref.a87, %Core.import_ref.adc9b), @Cpp.long.as.EqWith.impl.96d [concrete]
|
||||
// CHECK:STDOUT: %Core.import_ref.0e8: %Cpp.long.as.OrderedWith.impl.Less.type.335 = import_ref Core//prelude/types/cpp/int, loc{{\d+_\d+}}, loaded [concrete = constants.%Cpp.long.as.OrderedWith.impl.Less.606]
|
||||
// CHECK:STDOUT: %Core.import_ref.757: %Cpp.long.as.OrderedWith.impl.LessOrEquivalent.type.42c = import_ref Core//prelude/types/cpp/int, loc{{\d+_\d+}}, loaded [concrete = constants.%Cpp.long.as.OrderedWith.impl.LessOrEquivalent.0c8]
|
||||
// CHECK:STDOUT: %Core.import_ref.757ec: %Cpp.long.as.OrderedWith.impl.LessOrEquivalent.type.42c = import_ref Core//prelude/types/cpp/int, loc{{\d+_\d+}}, loaded [concrete = constants.%Cpp.long.as.OrderedWith.impl.LessOrEquivalent.0c8]
|
||||
// CHECK:STDOUT: %Core.import_ref.c32c: %Cpp.long.as.OrderedWith.impl.Greater.type.725 = import_ref Core//prelude/types/cpp/int, loc{{\d+_\d+}}, loaded [concrete = constants.%Cpp.long.as.OrderedWith.impl.Greater.7c8]
|
||||
// CHECK:STDOUT: %Core.import_ref.381: %Cpp.long.as.OrderedWith.impl.GreaterOrEquivalent.type.2d9 = import_ref Core//prelude/types/cpp/int, loc{{\d+_\d+}}, loaded [concrete = constants.%Cpp.long.as.OrderedWith.impl.GreaterOrEquivalent.a09]
|
||||
// CHECK:STDOUT: %OrderedWith.impl_witness_table.5d0 = impl_witness_table (%Core.import_ref.0e8, %Core.import_ref.757, %Core.import_ref.c32c, %Core.import_ref.381), @Cpp.long.as.OrderedWith.impl.894 [concrete]
|
||||
// CHECK:STDOUT: %OrderedWith.impl_witness_table.5d0 = impl_witness_table (%Core.import_ref.0e8, %Core.import_ref.757ec, %Core.import_ref.c32c, %Core.import_ref.381), @Cpp.long.as.OrderedWith.impl.894 [concrete]
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @ComparisonsHomogeneousLong() {
|
||||
@@ -1755,12 +1755,12 @@ fn CopyUnsignedLong() {
|
||||
// CHECK:STDOUT: %Core.Equal.025: @Cpp.long.as.EqWith.impl.5b1.%Cpp.long.as.EqWith.impl.Equal.type.1 (%Cpp.long.as.EqWith.impl.Equal.type.814973.2) = import_ref Core//prelude/types/cpp/int, Equal, loaded [symbolic = @Cpp.long.as.EqWith.impl.5b1.%Cpp.long.as.EqWith.impl.Equal.1 (constants.%Cpp.long.as.EqWith.impl.Equal.4a8971.2)]
|
||||
// CHECK:STDOUT: %Core.NotEqual.db5: @Cpp.long.as.EqWith.impl.5b1.%Cpp.long.as.EqWith.impl.NotEqual.type.1 (%Cpp.long.as.EqWith.impl.NotEqual.type.21e369.2) = import_ref Core//prelude/types/cpp/int, NotEqual, loaded [symbolic = @Cpp.long.as.EqWith.impl.5b1.%Cpp.long.as.EqWith.impl.NotEqual.1 (constants.%Cpp.long.as.EqWith.impl.NotEqual.385432.2)]
|
||||
// CHECK:STDOUT: %Core.import_ref.06c923.2: %i32.as.ImplicitAs.impl.Convert.type = import_ref Core//prelude/types/cpp/int, loc{{\d+_\d+}}, loaded [concrete = constants.%i32.as.ImplicitAs.impl.Convert]
|
||||
// CHECK:STDOUT: %ImplicitAs.impl_witness_table.a75 = impl_witness_table (%Core.import_ref.06c923.2), @i32.as.ImplicitAs.impl [concrete]
|
||||
// CHECK:STDOUT: %ImplicitAs.impl_witness_table.a75 = impl_witness_table (%Core.import_ref.06c923.2), @i32.as.ImplicitAs.impl.133 [concrete]
|
||||
// CHECK:STDOUT: %Core.import_ref.d32f: @Cpp.long.as.OrderedWith.impl.3fc.%Cpp.long.as.OrderedWith.impl.Less.type.2 (%Cpp.long.as.OrderedWith.impl.Less.type.3ff9ca.1) = import_ref Core//prelude/types/cpp/int, loc{{\d+_\d+}}, loaded [symbolic = @Cpp.long.as.OrderedWith.impl.3fc.%Cpp.long.as.OrderedWith.impl.Less.2 (constants.%Cpp.long.as.OrderedWith.impl.Less.76c9f3.1)]
|
||||
// CHECK:STDOUT: %Core.import_ref.4be: @Cpp.long.as.OrderedWith.impl.3fc.%Cpp.long.as.OrderedWith.impl.LessOrEquivalent.type.2 (%Cpp.long.as.OrderedWith.impl.LessOrEquivalent.type.35cecb.1) = import_ref Core//prelude/types/cpp/int, loc{{\d+_\d+}}, loaded [symbolic = @Cpp.long.as.OrderedWith.impl.3fc.%Cpp.long.as.OrderedWith.impl.LessOrEquivalent.2 (constants.%Cpp.long.as.OrderedWith.impl.LessOrEquivalent.351d50.1)]
|
||||
// CHECK:STDOUT: %Core.import_ref.b5f: @Cpp.long.as.OrderedWith.impl.3fc.%Cpp.long.as.OrderedWith.impl.Greater.type.2 (%Cpp.long.as.OrderedWith.impl.Greater.type.e2eef7.1) = import_ref Core//prelude/types/cpp/int, loc{{\d+_\d+}}, loaded [symbolic = @Cpp.long.as.OrderedWith.impl.3fc.%Cpp.long.as.OrderedWith.impl.Greater.2 (constants.%Cpp.long.as.OrderedWith.impl.Greater.37f70d.1)]
|
||||
// CHECK:STDOUT: %Core.import_ref.b5f6: @Cpp.long.as.OrderedWith.impl.3fc.%Cpp.long.as.OrderedWith.impl.Greater.type.2 (%Cpp.long.as.OrderedWith.impl.Greater.type.e2eef7.1) = import_ref Core//prelude/types/cpp/int, loc{{\d+_\d+}}, loaded [symbolic = @Cpp.long.as.OrderedWith.impl.3fc.%Cpp.long.as.OrderedWith.impl.Greater.2 (constants.%Cpp.long.as.OrderedWith.impl.Greater.37f70d.1)]
|
||||
// CHECK:STDOUT: %Core.import_ref.a8b: @Cpp.long.as.OrderedWith.impl.3fc.%Cpp.long.as.OrderedWith.impl.GreaterOrEquivalent.type.2 (%Cpp.long.as.OrderedWith.impl.GreaterOrEquivalent.type.154997.1) = import_ref Core//prelude/types/cpp/int, loc{{\d+_\d+}}, loaded [symbolic = @Cpp.long.as.OrderedWith.impl.3fc.%Cpp.long.as.OrderedWith.impl.GreaterOrEquivalent.2 (constants.%Cpp.long.as.OrderedWith.impl.GreaterOrEquivalent.e4afa3.1)]
|
||||
// CHECK:STDOUT: %OrderedWith.impl_witness_table.41e = impl_witness_table (%Core.import_ref.d32f, %Core.import_ref.4be, %Core.import_ref.b5f, %Core.import_ref.a8b), @Cpp.long.as.OrderedWith.impl.3fc [concrete]
|
||||
// CHECK:STDOUT: %OrderedWith.impl_witness_table.41e = impl_witness_table (%Core.import_ref.d32f, %Core.import_ref.4be, %Core.import_ref.b5f6, %Core.import_ref.a8b), @Cpp.long.as.OrderedWith.impl.3fc [concrete]
|
||||
// CHECK:STDOUT: %Core.Less.a91: @Cpp.long.as.OrderedWith.impl.3fc.%Cpp.long.as.OrderedWith.impl.Less.type.1 (%Cpp.long.as.OrderedWith.impl.Less.type.3ff9ca.2) = import_ref Core//prelude/types/cpp/int, Less, loaded [symbolic = @Cpp.long.as.OrderedWith.impl.3fc.%Cpp.long.as.OrderedWith.impl.Less.1 (constants.%Cpp.long.as.OrderedWith.impl.Less.76c9f3.2)]
|
||||
// CHECK:STDOUT: %Core.LessOrEquivalent.a62: @Cpp.long.as.OrderedWith.impl.3fc.%Cpp.long.as.OrderedWith.impl.LessOrEquivalent.type.1 (%Cpp.long.as.OrderedWith.impl.LessOrEquivalent.type.35cecb.2) = import_ref Core//prelude/types/cpp/int, LessOrEquivalent, loaded [symbolic = @Cpp.long.as.OrderedWith.impl.3fc.%Cpp.long.as.OrderedWith.impl.LessOrEquivalent.1 (constants.%Cpp.long.as.OrderedWith.impl.LessOrEquivalent.351d50.2)]
|
||||
// CHECK:STDOUT: %Core.Greater.ac9: @Cpp.long.as.OrderedWith.impl.3fc.%Cpp.long.as.OrderedWith.impl.Greater.type.1 (%Cpp.long.as.OrderedWith.impl.Greater.type.e2eef7.2) = import_ref Core//prelude/types/cpp/int, Greater, loaded [symbolic = @Cpp.long.as.OrderedWith.impl.3fc.%Cpp.long.as.OrderedWith.impl.Greater.1 (constants.%Cpp.long.as.OrderedWith.impl.Greater.37f70d.2)]
|
||||
@@ -2233,7 +2233,7 @@ fn CopyUnsignedLong() {
|
||||
// CHECK:STDOUT: %Core.Equal.d4c: @T.as_type.as.EqWith.impl.673.%T.as_type.as.EqWith.impl.Equal.type.1 (%T.as_type.as.EqWith.impl.Equal.type.94a46e.2) = import_ref Core//prelude/types/cpp/int, Equal, loaded [symbolic = @T.as_type.as.EqWith.impl.673.%T.as_type.as.EqWith.impl.Equal.1 (constants.%T.as_type.as.EqWith.impl.Equal.3fb574.2)]
|
||||
// CHECK:STDOUT: %Core.NotEqual.d11: @T.as_type.as.EqWith.impl.673.%T.as_type.as.EqWith.impl.NotEqual.type.1 (%T.as_type.as.EqWith.impl.NotEqual.type.92df03.2) = import_ref Core//prelude/types/cpp/int, NotEqual, loaded [symbolic = @T.as_type.as.EqWith.impl.673.%T.as_type.as.EqWith.impl.NotEqual.1 (constants.%T.as_type.as.EqWith.impl.NotEqual.a7a615.2)]
|
||||
// CHECK:STDOUT: %Core.import_ref.06c923.2: %i32.as.ImplicitAs.impl.Convert.type = import_ref Core//prelude/types/cpp/int, loc{{\d+_\d+}}, loaded [concrete = constants.%i32.as.ImplicitAs.impl.Convert]
|
||||
// CHECK:STDOUT: %ImplicitAs.impl_witness_table.a75 = impl_witness_table (%Core.import_ref.06c923.2), @i32.as.ImplicitAs.impl [concrete]
|
||||
// CHECK:STDOUT: %ImplicitAs.impl_witness_table.a75 = impl_witness_table (%Core.import_ref.06c923.2), @i32.as.ImplicitAs.impl.133 [concrete]
|
||||
// CHECK:STDOUT: %Core.import_ref.0c1: @T.as_type.as.OrderedWith.impl.821.%T.as_type.as.OrderedWith.impl.Less.type.2 (%T.as_type.as.OrderedWith.impl.Less.type.62945a.1) = import_ref Core//prelude/types/cpp/int, loc{{\d+_\d+}}, loaded [symbolic = @T.as_type.as.OrderedWith.impl.821.%T.as_type.as.OrderedWith.impl.Less.2 (constants.%T.as_type.as.OrderedWith.impl.Less.2ef721.1)]
|
||||
// CHECK:STDOUT: %Core.import_ref.f03: @T.as_type.as.OrderedWith.impl.821.%T.as_type.as.OrderedWith.impl.LessOrEquivalent.type.2 (%T.as_type.as.OrderedWith.impl.LessOrEquivalent.type.accc59.1) = import_ref Core//prelude/types/cpp/int, loc{{\d+_\d+}}, loaded [symbolic = @T.as_type.as.OrderedWith.impl.821.%T.as_type.as.OrderedWith.impl.LessOrEquivalent.2 (constants.%T.as_type.as.OrderedWith.impl.LessOrEquivalent.e8206a.1)]
|
||||
// CHECK:STDOUT: %Core.import_ref.dc8: @T.as_type.as.OrderedWith.impl.821.%T.as_type.as.OrderedWith.impl.Greater.type.2 (%T.as_type.as.OrderedWith.impl.Greater.type.4af657.1) = import_ref Core//prelude/types/cpp/int, loc{{\d+_\d+}}, loaded [symbolic = @T.as_type.as.OrderedWith.impl.821.%T.as_type.as.OrderedWith.impl.Greater.2 (constants.%T.as_type.as.OrderedWith.impl.Greater.00ebff.1)]
|
||||
@@ -3380,7 +3380,7 @@ fn CopyUnsignedLong() {
|
||||
// CHECK:STDOUT: %AddAssignWith.impl_witness_table.864 = impl_witness_table (%Core.import_ref.3ce), @Cpp.long.as.AddAssignWith.impl [concrete]
|
||||
// CHECK:STDOUT: %Core.Op.7fd: @Cpp.long.as.AddAssignWith.impl.%Cpp.long.as.AddAssignWith.impl.Op.type.1 (%Cpp.long.as.AddAssignWith.impl.Op.type.3959e4.2) = import_ref Core//prelude/types/cpp/int, Op, loaded [symbolic = @Cpp.long.as.AddAssignWith.impl.%Cpp.long.as.AddAssignWith.impl.Op.1 (constants.%Cpp.long.as.AddAssignWith.impl.Op.d1bf47.2)]
|
||||
// CHECK:STDOUT: %Core.import_ref.06c923.2: %i32.as.ImplicitAs.impl.Convert.type = import_ref Core//prelude/types/cpp/int, loc{{\d+_\d+}}, loaded [concrete = constants.%i32.as.ImplicitAs.impl.Convert]
|
||||
// CHECK:STDOUT: %ImplicitAs.impl_witness_table.a75 = impl_witness_table (%Core.import_ref.06c923.2), @i32.as.ImplicitAs.impl [concrete]
|
||||
// CHECK:STDOUT: %ImplicitAs.impl_witness_table.a75 = impl_witness_table (%Core.import_ref.06c923.2), @i32.as.ImplicitAs.impl.133 [concrete]
|
||||
// CHECK:STDOUT: %Core.import_ref.720: @Cpp.long.as.SubAssignWith.impl.%Cpp.long.as.SubAssignWith.impl.Op.type.2 (%Cpp.long.as.SubAssignWith.impl.Op.type.f4b2d1.1) = import_ref Core//prelude/types/cpp/int, loc{{\d+_\d+}}, loaded [symbolic = @Cpp.long.as.SubAssignWith.impl.%Cpp.long.as.SubAssignWith.impl.Op.2 (constants.%Cpp.long.as.SubAssignWith.impl.Op.5a5f49.1)]
|
||||
// CHECK:STDOUT: %SubAssignWith.impl_witness_table.b60 = impl_witness_table (%Core.import_ref.720), @Cpp.long.as.SubAssignWith.impl [concrete]
|
||||
// CHECK:STDOUT: %Core.Op.3ae: @Cpp.long.as.SubAssignWith.impl.%Cpp.long.as.SubAssignWith.impl.Op.type.1 (%Cpp.long.as.SubAssignWith.impl.Op.type.f4b2d1.2) = import_ref Core//prelude/types/cpp/int, Op, loaded [symbolic = @Cpp.long.as.SubAssignWith.impl.%Cpp.long.as.SubAssignWith.impl.Op.1 (constants.%Cpp.long.as.SubAssignWith.impl.Op.5a5f49.2)]
|
||||
@@ -3841,7 +3841,7 @@ fn CopyUnsignedLong() {
|
||||
// CHECK:STDOUT: %AddAssignWith.impl_witness_table.864 = impl_witness_table (%Core.import_ref.3ce), @Cpp.long.as.AddAssignWith.impl [concrete]
|
||||
// CHECK:STDOUT: %Core.Op.7fd: @Cpp.long.as.AddAssignWith.impl.%Cpp.long.as.AddAssignWith.impl.Op.type.1 (%Cpp.long.as.AddAssignWith.impl.Op.type.3959e4.2) = import_ref Core//prelude/types/cpp/int, Op, loaded [symbolic = @Cpp.long.as.AddAssignWith.impl.%Cpp.long.as.AddAssignWith.impl.Op.1 (constants.%Cpp.long.as.AddAssignWith.impl.Op.d1bf47.2)]
|
||||
// CHECK:STDOUT: %Core.import_ref.06c923.2: %i32.as.ImplicitAs.impl.Convert.type = import_ref Core//prelude/types/cpp/int, loc{{\d+_\d+}}, loaded [concrete = constants.%i32.as.ImplicitAs.impl.Convert]
|
||||
// CHECK:STDOUT: %ImplicitAs.impl_witness_table.a75 = impl_witness_table (%Core.import_ref.06c923.2), @i32.as.ImplicitAs.impl [concrete]
|
||||
// CHECK:STDOUT: %ImplicitAs.impl_witness_table.a75 = impl_witness_table (%Core.import_ref.06c923.2), @i32.as.ImplicitAs.impl.133 [concrete]
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @CompoundAssignmentLongAndRuntimeI32() {
|
||||
|
||||
+86
-86
@@ -1439,10 +1439,10 @@ fn CopyUnsignedLongLong() {
|
||||
// CHECK:STDOUT: %Core.import_ref.adc9b: %Cpp.long_long.as.EqWith.impl.NotEqual.type.8e5 = import_ref Core//prelude/types/cpp/int, loc{{\d+_\d+}}, loaded [concrete = constants.%Cpp.long_long.as.EqWith.impl.NotEqual.a6a]
|
||||
// CHECK:STDOUT: %EqWith.impl_witness_table.ed1 = impl_witness_table (%Core.import_ref.a87, %Core.import_ref.adc9b), @Cpp.long_long.as.EqWith.impl.eaa [concrete]
|
||||
// CHECK:STDOUT: %Core.import_ref.0e8: %Cpp.long_long.as.OrderedWith.impl.Less.type.335 = import_ref Core//prelude/types/cpp/int, loc{{\d+_\d+}}, loaded [concrete = constants.%Cpp.long_long.as.OrderedWith.impl.Less.606]
|
||||
// CHECK:STDOUT: %Core.import_ref.757: %Cpp.long_long.as.OrderedWith.impl.LessOrEquivalent.type.42c = import_ref Core//prelude/types/cpp/int, loc{{\d+_\d+}}, loaded [concrete = constants.%Cpp.long_long.as.OrderedWith.impl.LessOrEquivalent.0c8]
|
||||
// CHECK:STDOUT: %Core.import_ref.757ec: %Cpp.long_long.as.OrderedWith.impl.LessOrEquivalent.type.42c = import_ref Core//prelude/types/cpp/int, loc{{\d+_\d+}}, loaded [concrete = constants.%Cpp.long_long.as.OrderedWith.impl.LessOrEquivalent.0c8]
|
||||
// CHECK:STDOUT: %Core.import_ref.c32c: %Cpp.long_long.as.OrderedWith.impl.Greater.type.725 = import_ref Core//prelude/types/cpp/int, loc{{\d+_\d+}}, loaded [concrete = constants.%Cpp.long_long.as.OrderedWith.impl.Greater.7c8]
|
||||
// CHECK:STDOUT: %Core.import_ref.381: %Cpp.long_long.as.OrderedWith.impl.GreaterOrEquivalent.type.2d9 = import_ref Core//prelude/types/cpp/int, loc{{\d+_\d+}}, loaded [concrete = constants.%Cpp.long_long.as.OrderedWith.impl.GreaterOrEquivalent.a09]
|
||||
// CHECK:STDOUT: %OrderedWith.impl_witness_table.cc0 = impl_witness_table (%Core.import_ref.0e8, %Core.import_ref.757, %Core.import_ref.c32c, %Core.import_ref.381), @Cpp.long_long.as.OrderedWith.impl.278 [concrete]
|
||||
// CHECK:STDOUT: %OrderedWith.impl_witness_table.cc0 = impl_witness_table (%Core.import_ref.0e8, %Core.import_ref.757ec, %Core.import_ref.c32c, %Core.import_ref.381), @Cpp.long_long.as.OrderedWith.impl.278 [concrete]
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @ComparisonsHomogeneousLongLong() {
|
||||
@@ -1984,71 +1984,71 @@ fn CopyUnsignedLongLong() {
|
||||
// CHECK:STDOUT: %int_1.b19: %Cpp.long_long = int_value 1 [concrete]
|
||||
// CHECK:STDOUT: %EqWith.type.9fc: type = facet_type <@EqWith, @EqWith(%Cpp.long_long)> [concrete]
|
||||
// CHECK:STDOUT: %T.bf2: %ImplicitAs.type.0ec = symbolic_binding T, 0 [symbolic]
|
||||
// CHECK:STDOUT: %T.as_type.as.EqWith.impl.NotEqual.type.925fdb.1: type = fn_type @T.as_type.as.EqWith.impl.NotEqual.3, @T.as_type.as.EqWith.impl.6d3(%T.bf2) [symbolic]
|
||||
// CHECK:STDOUT: %T.as_type.as.EqWith.impl.NotEqual.type.925fdb.1: type = fn_type @T.as_type.as.EqWith.impl.NotEqual.5, @T.as_type.as.EqWith.impl.6d3(%T.bf2) [symbolic]
|
||||
// CHECK:STDOUT: %T.as_type.as.EqWith.impl.NotEqual.b16a99.1: %T.as_type.as.EqWith.impl.NotEqual.type.925fdb.1 = struct_value () [symbolic]
|
||||
// CHECK:STDOUT: %T.as_type.as.EqWith.impl.Equal.type.3cb0e1.1: type = fn_type @T.as_type.as.EqWith.impl.Equal.3, @T.as_type.as.EqWith.impl.6d3(%T.bf2) [symbolic]
|
||||
// CHECK:STDOUT: %T.as_type.as.EqWith.impl.Equal.type.3cb0e1.1: type = fn_type @T.as_type.as.EqWith.impl.Equal.5, @T.as_type.as.EqWith.impl.6d3(%T.bf2) [symbolic]
|
||||
// CHECK:STDOUT: %T.as_type.as.EqWith.impl.Equal.a1333e.1: %T.as_type.as.EqWith.impl.Equal.type.3cb0e1.1 = struct_value () [symbolic]
|
||||
// CHECK:STDOUT: %T.as_type.as.EqWith.impl.NotEqual.type.925fdb.2: type = fn_type @T.as_type.as.EqWith.impl.NotEqual.4, @T.as_type.as.EqWith.impl.6d3(%T.bf2) [symbolic]
|
||||
// CHECK:STDOUT: %T.as_type.as.EqWith.impl.NotEqual.type.925fdb.2: type = fn_type @T.as_type.as.EqWith.impl.NotEqual.6, @T.as_type.as.EqWith.impl.6d3(%T.bf2) [symbolic]
|
||||
// CHECK:STDOUT: %T.as_type.as.EqWith.impl.NotEqual.b16a99.2: %T.as_type.as.EqWith.impl.NotEqual.type.925fdb.2 = struct_value () [symbolic]
|
||||
// CHECK:STDOUT: %T.as_type.as.EqWith.impl.Equal.type.3cb0e1.2: type = fn_type @T.as_type.as.EqWith.impl.Equal.4, @T.as_type.as.EqWith.impl.6d3(%T.bf2) [symbolic]
|
||||
// CHECK:STDOUT: %T.as_type.as.EqWith.impl.Equal.type.3cb0e1.2: type = fn_type @T.as_type.as.EqWith.impl.Equal.6, @T.as_type.as.EqWith.impl.6d3(%T.bf2) [symbolic]
|
||||
// CHECK:STDOUT: %T.as_type.as.EqWith.impl.Equal.a1333e.2: %T.as_type.as.EqWith.impl.Equal.type.3cb0e1.2 = struct_value () [symbolic]
|
||||
// CHECK:STDOUT: %ImplicitAs.impl_witness.305: <witness> = impl_witness imports.%ImplicitAs.impl_witness_table.a87 [concrete]
|
||||
// CHECK:STDOUT: %ImplicitAs.facet.7a4: %ImplicitAs.type.0ec = facet_value %i64, (%ImplicitAs.impl_witness.305) [concrete]
|
||||
// CHECK:STDOUT: %EqWith.impl_witness.084: <witness> = impl_witness imports.%EqWith.impl_witness_table.db1, @T.as_type.as.EqWith.impl.6d3(%ImplicitAs.facet.7a4) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.EqWith.impl.Equal.type.6d33d6.1: type = fn_type @T.as_type.as.EqWith.impl.Equal.4, @T.as_type.as.EqWith.impl.6d3(%ImplicitAs.facet.7a4) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.EqWith.impl.Equal.type.6d33d6.1: type = fn_type @T.as_type.as.EqWith.impl.Equal.6, @T.as_type.as.EqWith.impl.6d3(%ImplicitAs.facet.7a4) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.EqWith.impl.Equal.817082.1: %T.as_type.as.EqWith.impl.Equal.type.6d33d6.1 = struct_value () [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.EqWith.impl.NotEqual.type.2c42f8.1: type = fn_type @T.as_type.as.EqWith.impl.NotEqual.4, @T.as_type.as.EqWith.impl.6d3(%ImplicitAs.facet.7a4) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.EqWith.impl.NotEqual.type.2c42f8.1: type = fn_type @T.as_type.as.EqWith.impl.NotEqual.6, @T.as_type.as.EqWith.impl.6d3(%ImplicitAs.facet.7a4) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.EqWith.impl.NotEqual.de7c60.1: %T.as_type.as.EqWith.impl.NotEqual.type.2c42f8.1 = struct_value () [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.EqWith.impl.Equal.type.6d33d6.2: type = fn_type @T.as_type.as.EqWith.impl.Equal.3, @T.as_type.as.EqWith.impl.6d3(%ImplicitAs.facet.7a4) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.EqWith.impl.Equal.type.6d33d6.2: type = fn_type @T.as_type.as.EqWith.impl.Equal.5, @T.as_type.as.EqWith.impl.6d3(%ImplicitAs.facet.7a4) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.EqWith.impl.Equal.817082.2: %T.as_type.as.EqWith.impl.Equal.type.6d33d6.2 = struct_value () [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.EqWith.impl.NotEqual.type.2c42f8.2: type = fn_type @T.as_type.as.EqWith.impl.NotEqual.3, @T.as_type.as.EqWith.impl.6d3(%ImplicitAs.facet.7a4) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.EqWith.impl.NotEqual.type.2c42f8.2: type = fn_type @T.as_type.as.EqWith.impl.NotEqual.5, @T.as_type.as.EqWith.impl.6d3(%ImplicitAs.facet.7a4) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.EqWith.impl.NotEqual.de7c60.2: %T.as_type.as.EqWith.impl.NotEqual.type.2c42f8.2 = struct_value () [concrete]
|
||||
// CHECK:STDOUT: %EqWith.facet.306: %EqWith.type.9fc = facet_value %i64, (%EqWith.impl_witness.084) [concrete]
|
||||
// CHECK:STDOUT: %EqWith.WithSelf.Equal.type.5b2: type = fn_type @EqWith.WithSelf.Equal, @EqWith.WithSelf(%Cpp.long_long, %EqWith.facet.306) [concrete]
|
||||
// CHECK:STDOUT: %EqWith.WithSelf.NotEqual.type.86d: type = fn_type @EqWith.WithSelf.NotEqual, @EqWith.WithSelf(%Cpp.long_long, %EqWith.facet.306) [concrete]
|
||||
// CHECK:STDOUT: %.183: type = fn_type_with_self_type %EqWith.WithSelf.Equal.type.5b2, %EqWith.facet.306 [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.EqWith.impl.Equal.specific_fn.044d32.1: <specific function> = specific_function %T.as_type.as.EqWith.impl.Equal.817082.2, @T.as_type.as.EqWith.impl.Equal.3(%ImplicitAs.facet.7a4) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.EqWith.impl.Equal.specific_fn.044d32.2: <specific function> = specific_function %T.as_type.as.EqWith.impl.Equal.817082.1, @T.as_type.as.EqWith.impl.Equal.4(%ImplicitAs.facet.7a4) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.EqWith.impl.Equal.specific_fn.044d32.1: <specific function> = specific_function %T.as_type.as.EqWith.impl.Equal.817082.2, @T.as_type.as.EqWith.impl.Equal.5(%ImplicitAs.facet.7a4) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.EqWith.impl.Equal.specific_fn.044d32.2: <specific function> = specific_function %T.as_type.as.EqWith.impl.Equal.817082.1, @T.as_type.as.EqWith.impl.Equal.6(%ImplicitAs.facet.7a4) [concrete]
|
||||
// CHECK:STDOUT: %ImplicitAs.WithSelf.Convert.type.3ae: type = fn_type @ImplicitAs.WithSelf.Convert, @ImplicitAs.WithSelf(%Cpp.long_long, %ImplicitAs.facet.7a4) [concrete]
|
||||
// CHECK:STDOUT: %.25e: type = fn_type_with_self_type %ImplicitAs.WithSelf.Convert.type.3ae, %ImplicitAs.facet.7a4 [concrete]
|
||||
// CHECK:STDOUT: %i64.as.ImplicitAs.impl.Convert.type: type = fn_type @i64.as.ImplicitAs.impl.Convert [concrete]
|
||||
// CHECK:STDOUT: %i64.as.ImplicitAs.impl.Convert: %i64.as.ImplicitAs.impl.Convert.type = struct_value () [concrete]
|
||||
// CHECK:STDOUT: %.eca: type = fn_type_with_self_type %EqWith.WithSelf.NotEqual.type.86d, %EqWith.facet.306 [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.EqWith.impl.NotEqual.specific_fn.b44c79.1: <specific function> = specific_function %T.as_type.as.EqWith.impl.NotEqual.de7c60.2, @T.as_type.as.EqWith.impl.NotEqual.3(%ImplicitAs.facet.7a4) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.EqWith.impl.NotEqual.specific_fn.b44c79.2: <specific function> = specific_function %T.as_type.as.EqWith.impl.NotEqual.de7c60.1, @T.as_type.as.EqWith.impl.NotEqual.4(%ImplicitAs.facet.7a4) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.EqWith.impl.NotEqual.specific_fn.b44c79.1: <specific function> = specific_function %T.as_type.as.EqWith.impl.NotEqual.de7c60.2, @T.as_type.as.EqWith.impl.NotEqual.5(%ImplicitAs.facet.7a4) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.EqWith.impl.NotEqual.specific_fn.b44c79.2: <specific function> = specific_function %T.as_type.as.EqWith.impl.NotEqual.de7c60.1, @T.as_type.as.EqWith.impl.NotEqual.6(%ImplicitAs.facet.7a4) [concrete]
|
||||
// CHECK:STDOUT: %OrderedWith.type.456: type = facet_type <@OrderedWith, @OrderedWith(%Cpp.long_long)> [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.type.d6724c.1: type = fn_type @T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.3, @T.as_type.as.OrderedWith.impl.df2(%T.bf2) [symbolic]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.type.d6724c.1: type = fn_type @T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.5, @T.as_type.as.OrderedWith.impl.df2(%T.bf2) [symbolic]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.df5290.1: %T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.type.d6724c.1 = struct_value () [symbolic]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.Greater.type.4fb98a.1: type = fn_type @T.as_type.as.OrderedWith.impl.Greater.3, @T.as_type.as.OrderedWith.impl.df2(%T.bf2) [symbolic]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.Greater.type.4fb98a.1: type = fn_type @T.as_type.as.OrderedWith.impl.Greater.5, @T.as_type.as.OrderedWith.impl.df2(%T.bf2) [symbolic]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.Greater.878ae3.1: %T.as_type.as.OrderedWith.impl.Greater.type.4fb98a.1 = struct_value () [symbolic]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.LessOrEquivalent.type.3d985f.1: type = fn_type @T.as_type.as.OrderedWith.impl.LessOrEquivalent.3, @T.as_type.as.OrderedWith.impl.df2(%T.bf2) [symbolic]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.LessOrEquivalent.type.3d985f.1: type = fn_type @T.as_type.as.OrderedWith.impl.LessOrEquivalent.5, @T.as_type.as.OrderedWith.impl.df2(%T.bf2) [symbolic]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.LessOrEquivalent.2cb445.1: %T.as_type.as.OrderedWith.impl.LessOrEquivalent.type.3d985f.1 = struct_value () [symbolic]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.Less.type.2daa9a.1: type = fn_type @T.as_type.as.OrderedWith.impl.Less.3, @T.as_type.as.OrderedWith.impl.df2(%T.bf2) [symbolic]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.Less.type.2daa9a.1: type = fn_type @T.as_type.as.OrderedWith.impl.Less.5, @T.as_type.as.OrderedWith.impl.df2(%T.bf2) [symbolic]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.Less.c37ef5.1: %T.as_type.as.OrderedWith.impl.Less.type.2daa9a.1 = struct_value () [symbolic]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.type.d6724c.2: type = fn_type @T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.4, @T.as_type.as.OrderedWith.impl.df2(%T.bf2) [symbolic]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.type.d6724c.2: type = fn_type @T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.6, @T.as_type.as.OrderedWith.impl.df2(%T.bf2) [symbolic]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.df5290.2: %T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.type.d6724c.2 = struct_value () [symbolic]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.Greater.type.4fb98a.2: type = fn_type @T.as_type.as.OrderedWith.impl.Greater.4, @T.as_type.as.OrderedWith.impl.df2(%T.bf2) [symbolic]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.Greater.type.4fb98a.2: type = fn_type @T.as_type.as.OrderedWith.impl.Greater.6, @T.as_type.as.OrderedWith.impl.df2(%T.bf2) [symbolic]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.Greater.878ae3.2: %T.as_type.as.OrderedWith.impl.Greater.type.4fb98a.2 = struct_value () [symbolic]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.LessOrEquivalent.type.3d985f.2: type = fn_type @T.as_type.as.OrderedWith.impl.LessOrEquivalent.4, @T.as_type.as.OrderedWith.impl.df2(%T.bf2) [symbolic]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.LessOrEquivalent.type.3d985f.2: type = fn_type @T.as_type.as.OrderedWith.impl.LessOrEquivalent.6, @T.as_type.as.OrderedWith.impl.df2(%T.bf2) [symbolic]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.LessOrEquivalent.2cb445.2: %T.as_type.as.OrderedWith.impl.LessOrEquivalent.type.3d985f.2 = struct_value () [symbolic]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.Less.type.2daa9a.2: type = fn_type @T.as_type.as.OrderedWith.impl.Less.4, @T.as_type.as.OrderedWith.impl.df2(%T.bf2) [symbolic]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.Less.type.2daa9a.2: type = fn_type @T.as_type.as.OrderedWith.impl.Less.6, @T.as_type.as.OrderedWith.impl.df2(%T.bf2) [symbolic]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.Less.c37ef5.2: %T.as_type.as.OrderedWith.impl.Less.type.2daa9a.2 = struct_value () [symbolic]
|
||||
// CHECK:STDOUT: %OrderedWith.impl_witness.7e3: <witness> = impl_witness imports.%OrderedWith.impl_witness_table.8b4, @T.as_type.as.OrderedWith.impl.df2(%ImplicitAs.facet.7a4) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.Less.type.7b405f.1: type = fn_type @T.as_type.as.OrderedWith.impl.Less.4, @T.as_type.as.OrderedWith.impl.df2(%ImplicitAs.facet.7a4) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.Less.type.7b405f.1: type = fn_type @T.as_type.as.OrderedWith.impl.Less.6, @T.as_type.as.OrderedWith.impl.df2(%ImplicitAs.facet.7a4) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.Less.c5f236.1: %T.as_type.as.OrderedWith.impl.Less.type.7b405f.1 = struct_value () [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.LessOrEquivalent.type.577251.1: type = fn_type @T.as_type.as.OrderedWith.impl.LessOrEquivalent.4, @T.as_type.as.OrderedWith.impl.df2(%ImplicitAs.facet.7a4) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.LessOrEquivalent.type.577251.1: type = fn_type @T.as_type.as.OrderedWith.impl.LessOrEquivalent.6, @T.as_type.as.OrderedWith.impl.df2(%ImplicitAs.facet.7a4) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.LessOrEquivalent.e5cfba.1: %T.as_type.as.OrderedWith.impl.LessOrEquivalent.type.577251.1 = struct_value () [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.Greater.type.085dd9.1: type = fn_type @T.as_type.as.OrderedWith.impl.Greater.4, @T.as_type.as.OrderedWith.impl.df2(%ImplicitAs.facet.7a4) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.Greater.type.085dd9.1: type = fn_type @T.as_type.as.OrderedWith.impl.Greater.6, @T.as_type.as.OrderedWith.impl.df2(%ImplicitAs.facet.7a4) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.Greater.749015.1: %T.as_type.as.OrderedWith.impl.Greater.type.085dd9.1 = struct_value () [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.type.0f0b65.1: type = fn_type @T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.4, @T.as_type.as.OrderedWith.impl.df2(%ImplicitAs.facet.7a4) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.type.0f0b65.1: type = fn_type @T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.6, @T.as_type.as.OrderedWith.impl.df2(%ImplicitAs.facet.7a4) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.f86b3e.1: %T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.type.0f0b65.1 = struct_value () [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.Less.type.7b405f.2: type = fn_type @T.as_type.as.OrderedWith.impl.Less.3, @T.as_type.as.OrderedWith.impl.df2(%ImplicitAs.facet.7a4) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.Less.type.7b405f.2: type = fn_type @T.as_type.as.OrderedWith.impl.Less.5, @T.as_type.as.OrderedWith.impl.df2(%ImplicitAs.facet.7a4) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.Less.c5f236.2: %T.as_type.as.OrderedWith.impl.Less.type.7b405f.2 = struct_value () [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.LessOrEquivalent.type.577251.2: type = fn_type @T.as_type.as.OrderedWith.impl.LessOrEquivalent.3, @T.as_type.as.OrderedWith.impl.df2(%ImplicitAs.facet.7a4) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.LessOrEquivalent.type.577251.2: type = fn_type @T.as_type.as.OrderedWith.impl.LessOrEquivalent.5, @T.as_type.as.OrderedWith.impl.df2(%ImplicitAs.facet.7a4) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.LessOrEquivalent.e5cfba.2: %T.as_type.as.OrderedWith.impl.LessOrEquivalent.type.577251.2 = struct_value () [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.Greater.type.085dd9.2: type = fn_type @T.as_type.as.OrderedWith.impl.Greater.3, @T.as_type.as.OrderedWith.impl.df2(%ImplicitAs.facet.7a4) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.Greater.type.085dd9.2: type = fn_type @T.as_type.as.OrderedWith.impl.Greater.5, @T.as_type.as.OrderedWith.impl.df2(%ImplicitAs.facet.7a4) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.Greater.749015.2: %T.as_type.as.OrderedWith.impl.Greater.type.085dd9.2 = struct_value () [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.type.0f0b65.2: type = fn_type @T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.3, @T.as_type.as.OrderedWith.impl.df2(%ImplicitAs.facet.7a4) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.type.0f0b65.2: type = fn_type @T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.5, @T.as_type.as.OrderedWith.impl.df2(%ImplicitAs.facet.7a4) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.f86b3e.2: %T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.type.0f0b65.2 = struct_value () [concrete]
|
||||
// CHECK:STDOUT: %OrderedWith.facet.72a: %OrderedWith.type.456 = facet_value %i64, (%OrderedWith.impl_witness.7e3) [concrete]
|
||||
// CHECK:STDOUT: %OrderedWith.WithSelf.Less.type.606: type = fn_type @OrderedWith.WithSelf.Less, @OrderedWith.WithSelf(%Cpp.long_long, %OrderedWith.facet.72a) [concrete]
|
||||
@@ -2056,59 +2056,59 @@ fn CopyUnsignedLongLong() {
|
||||
// CHECK:STDOUT: %OrderedWith.WithSelf.Greater.type.f32: type = fn_type @OrderedWith.WithSelf.Greater, @OrderedWith.WithSelf(%Cpp.long_long, %OrderedWith.facet.72a) [concrete]
|
||||
// CHECK:STDOUT: %OrderedWith.WithSelf.GreaterOrEquivalent.type.15d: type = fn_type @OrderedWith.WithSelf.GreaterOrEquivalent, @OrderedWith.WithSelf(%Cpp.long_long, %OrderedWith.facet.72a) [concrete]
|
||||
// CHECK:STDOUT: %.af0: type = fn_type_with_self_type %OrderedWith.WithSelf.Greater.type.f32, %OrderedWith.facet.72a [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.Greater.specific_fn.cbc6c2.1: <specific function> = specific_function %T.as_type.as.OrderedWith.impl.Greater.749015.2, @T.as_type.as.OrderedWith.impl.Greater.3(%ImplicitAs.facet.7a4) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.Greater.specific_fn.cbc6c2.2: <specific function> = specific_function %T.as_type.as.OrderedWith.impl.Greater.749015.1, @T.as_type.as.OrderedWith.impl.Greater.4(%ImplicitAs.facet.7a4) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.Greater.specific_fn.cbc6c2.1: <specific function> = specific_function %T.as_type.as.OrderedWith.impl.Greater.749015.2, @T.as_type.as.OrderedWith.impl.Greater.5(%ImplicitAs.facet.7a4) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.Greater.specific_fn.cbc6c2.2: <specific function> = specific_function %T.as_type.as.OrderedWith.impl.Greater.749015.1, @T.as_type.as.OrderedWith.impl.Greater.6(%ImplicitAs.facet.7a4) [concrete]
|
||||
// CHECK:STDOUT: %.901: type = fn_type_with_self_type %OrderedWith.WithSelf.Less.type.606, %OrderedWith.facet.72a [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.Less.specific_fn.a8a2ad.1: <specific function> = specific_function %T.as_type.as.OrderedWith.impl.Less.c5f236.2, @T.as_type.as.OrderedWith.impl.Less.3(%ImplicitAs.facet.7a4) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.Less.specific_fn.a8a2ad.2: <specific function> = specific_function %T.as_type.as.OrderedWith.impl.Less.c5f236.1, @T.as_type.as.OrderedWith.impl.Less.4(%ImplicitAs.facet.7a4) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.Less.specific_fn.a8a2ad.1: <specific function> = specific_function %T.as_type.as.OrderedWith.impl.Less.c5f236.2, @T.as_type.as.OrderedWith.impl.Less.5(%ImplicitAs.facet.7a4) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.Less.specific_fn.a8a2ad.2: <specific function> = specific_function %T.as_type.as.OrderedWith.impl.Less.c5f236.1, @T.as_type.as.OrderedWith.impl.Less.6(%ImplicitAs.facet.7a4) [concrete]
|
||||
// CHECK:STDOUT: %.96b: type = fn_type_with_self_type %OrderedWith.WithSelf.GreaterOrEquivalent.type.15d, %OrderedWith.facet.72a [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.specific_fn.8a93e9.1: <specific function> = specific_function %T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.f86b3e.2, @T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.3(%ImplicitAs.facet.7a4) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.specific_fn.8a93e9.2: <specific function> = specific_function %T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.f86b3e.1, @T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.4(%ImplicitAs.facet.7a4) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.specific_fn.8a93e9.1: <specific function> = specific_function %T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.f86b3e.2, @T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.5(%ImplicitAs.facet.7a4) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.specific_fn.8a93e9.2: <specific function> = specific_function %T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.f86b3e.1, @T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.6(%ImplicitAs.facet.7a4) [concrete]
|
||||
// CHECK:STDOUT: %.829: type = fn_type_with_self_type %OrderedWith.WithSelf.LessOrEquivalent.type.2a1, %OrderedWith.facet.72a [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.LessOrEquivalent.specific_fn.ab9ff7.1: <specific function> = specific_function %T.as_type.as.OrderedWith.impl.LessOrEquivalent.e5cfba.2, @T.as_type.as.OrderedWith.impl.LessOrEquivalent.3(%ImplicitAs.facet.7a4) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.LessOrEquivalent.specific_fn.ab9ff7.2: <specific function> = specific_function %T.as_type.as.OrderedWith.impl.LessOrEquivalent.e5cfba.1, @T.as_type.as.OrderedWith.impl.LessOrEquivalent.4(%ImplicitAs.facet.7a4) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.LessOrEquivalent.specific_fn.ab9ff7.1: <specific function> = specific_function %T.as_type.as.OrderedWith.impl.LessOrEquivalent.e5cfba.2, @T.as_type.as.OrderedWith.impl.LessOrEquivalent.5(%ImplicitAs.facet.7a4) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.LessOrEquivalent.specific_fn.ab9ff7.2: <specific function> = specific_function %T.as_type.as.OrderedWith.impl.LessOrEquivalent.e5cfba.1, @T.as_type.as.OrderedWith.impl.LessOrEquivalent.6(%ImplicitAs.facet.7a4) [concrete]
|
||||
// CHECK:STDOUT: %EqWith.impl_witness.cb6: <witness> = impl_witness imports.%EqWith.impl_witness_table.db1, @T.as_type.as.EqWith.impl.6d3(%ImplicitAs.facet.2ed) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.EqWith.impl.Equal.type.8e6244.1: type = fn_type @T.as_type.as.EqWith.impl.Equal.4, @T.as_type.as.EqWith.impl.6d3(%ImplicitAs.facet.2ed) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.EqWith.impl.Equal.type.8e6244.1: type = fn_type @T.as_type.as.EqWith.impl.Equal.6, @T.as_type.as.EqWith.impl.6d3(%ImplicitAs.facet.2ed) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.EqWith.impl.Equal.66756b.1: %T.as_type.as.EqWith.impl.Equal.type.8e6244.1 = struct_value () [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.EqWith.impl.NotEqual.type.fb7a86.1: type = fn_type @T.as_type.as.EqWith.impl.NotEqual.4, @T.as_type.as.EqWith.impl.6d3(%ImplicitAs.facet.2ed) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.EqWith.impl.NotEqual.type.fb7a86.1: type = fn_type @T.as_type.as.EqWith.impl.NotEqual.6, @T.as_type.as.EqWith.impl.6d3(%ImplicitAs.facet.2ed) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.EqWith.impl.NotEqual.672038.1: %T.as_type.as.EqWith.impl.NotEqual.type.fb7a86.1 = struct_value () [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.EqWith.impl.Equal.type.8e6244.2: type = fn_type @T.as_type.as.EqWith.impl.Equal.3, @T.as_type.as.EqWith.impl.6d3(%ImplicitAs.facet.2ed) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.EqWith.impl.Equal.type.8e6244.2: type = fn_type @T.as_type.as.EqWith.impl.Equal.5, @T.as_type.as.EqWith.impl.6d3(%ImplicitAs.facet.2ed) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.EqWith.impl.Equal.66756b.2: %T.as_type.as.EqWith.impl.Equal.type.8e6244.2 = struct_value () [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.EqWith.impl.NotEqual.type.fb7a86.2: type = fn_type @T.as_type.as.EqWith.impl.NotEqual.3, @T.as_type.as.EqWith.impl.6d3(%ImplicitAs.facet.2ed) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.EqWith.impl.NotEqual.type.fb7a86.2: type = fn_type @T.as_type.as.EqWith.impl.NotEqual.5, @T.as_type.as.EqWith.impl.6d3(%ImplicitAs.facet.2ed) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.EqWith.impl.NotEqual.672038.2: %T.as_type.as.EqWith.impl.NotEqual.type.fb7a86.2 = struct_value () [concrete]
|
||||
// CHECK:STDOUT: %EqWith.facet.83c: %EqWith.type.9fc = facet_value Core.IntLiteral, (%EqWith.impl_witness.cb6) [concrete]
|
||||
// CHECK:STDOUT: %EqWith.WithSelf.Equal.type.5b1: type = fn_type @EqWith.WithSelf.Equal, @EqWith.WithSelf(%Cpp.long_long, %EqWith.facet.83c) [concrete]
|
||||
// CHECK:STDOUT: %EqWith.WithSelf.NotEqual.type.a9f: type = fn_type @EqWith.WithSelf.NotEqual, @EqWith.WithSelf(%Cpp.long_long, %EqWith.facet.83c) [concrete]
|
||||
// CHECK:STDOUT: %.658: type = fn_type_with_self_type %EqWith.WithSelf.Equal.type.5b1, %EqWith.facet.83c [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.EqWith.impl.Equal.bound.2fcdd5.1: <bound method> = bound_method %int_1.5b8, %T.as_type.as.EqWith.impl.Equal.66756b.2 [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.EqWith.impl.Equal.specific_fn.7834c5.1: <specific function> = specific_function %T.as_type.as.EqWith.impl.Equal.66756b.2, @T.as_type.as.EqWith.impl.Equal.3(%ImplicitAs.facet.2ed) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.EqWith.impl.Equal.specific_fn.7834c5.1: <specific function> = specific_function %T.as_type.as.EqWith.impl.Equal.66756b.2, @T.as_type.as.EqWith.impl.Equal.5(%ImplicitAs.facet.2ed) [concrete]
|
||||
// CHECK:STDOUT: %bound_method.7c9d36.1: <bound method> = bound_method %int_1.5b8, %T.as_type.as.EqWith.impl.Equal.specific_fn.7834c5.1 [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.EqWith.impl.Equal.bound.2fcdd5.2: <bound method> = bound_method %int_1.5b8, %T.as_type.as.EqWith.impl.Equal.66756b.1 [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.EqWith.impl.Equal.specific_fn.7834c5.2: <specific function> = specific_function %T.as_type.as.EqWith.impl.Equal.66756b.1, @T.as_type.as.EqWith.impl.Equal.4(%ImplicitAs.facet.2ed) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.EqWith.impl.Equal.specific_fn.7834c5.2: <specific function> = specific_function %T.as_type.as.EqWith.impl.Equal.66756b.1, @T.as_type.as.EqWith.impl.Equal.6(%ImplicitAs.facet.2ed) [concrete]
|
||||
// CHECK:STDOUT: %bound_method.7c9d36.2: <bound method> = bound_method %int_1.5b8, %T.as_type.as.EqWith.impl.Equal.specific_fn.7834c5.2 [concrete]
|
||||
// CHECK:STDOUT: %.1f9: type = fn_type_with_self_type %EqWith.WithSelf.NotEqual.type.a9f, %EqWith.facet.83c [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.EqWith.impl.NotEqual.bound.a9911b.1: <bound method> = bound_method %int_1.5b8, %T.as_type.as.EqWith.impl.NotEqual.672038.2 [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.EqWith.impl.NotEqual.specific_fn.598adf.1: <specific function> = specific_function %T.as_type.as.EqWith.impl.NotEqual.672038.2, @T.as_type.as.EqWith.impl.NotEqual.3(%ImplicitAs.facet.2ed) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.EqWith.impl.NotEqual.specific_fn.598adf.1: <specific function> = specific_function %T.as_type.as.EqWith.impl.NotEqual.672038.2, @T.as_type.as.EqWith.impl.NotEqual.5(%ImplicitAs.facet.2ed) [concrete]
|
||||
// CHECK:STDOUT: %bound_method.1f073e.1: <bound method> = bound_method %int_1.5b8, %T.as_type.as.EqWith.impl.NotEqual.specific_fn.598adf.1 [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.EqWith.impl.NotEqual.bound.a9911b.2: <bound method> = bound_method %int_1.5b8, %T.as_type.as.EqWith.impl.NotEqual.672038.1 [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.EqWith.impl.NotEqual.specific_fn.598adf.2: <specific function> = specific_function %T.as_type.as.EqWith.impl.NotEqual.672038.1, @T.as_type.as.EqWith.impl.NotEqual.4(%ImplicitAs.facet.2ed) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.EqWith.impl.NotEqual.specific_fn.598adf.2: <specific function> = specific_function %T.as_type.as.EqWith.impl.NotEqual.672038.1, @T.as_type.as.EqWith.impl.NotEqual.6(%ImplicitAs.facet.2ed) [concrete]
|
||||
// CHECK:STDOUT: %bound_method.1f073e.2: <bound method> = bound_method %int_1.5b8, %T.as_type.as.EqWith.impl.NotEqual.specific_fn.598adf.2 [concrete]
|
||||
// CHECK:STDOUT: %OrderedWith.impl_witness.ccd: <witness> = impl_witness imports.%OrderedWith.impl_witness_table.8b4, @T.as_type.as.OrderedWith.impl.df2(%ImplicitAs.facet.2ed) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.Less.type.28a50f.1: type = fn_type @T.as_type.as.OrderedWith.impl.Less.4, @T.as_type.as.OrderedWith.impl.df2(%ImplicitAs.facet.2ed) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.Less.type.28a50f.1: type = fn_type @T.as_type.as.OrderedWith.impl.Less.6, @T.as_type.as.OrderedWith.impl.df2(%ImplicitAs.facet.2ed) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.Less.09733d.1: %T.as_type.as.OrderedWith.impl.Less.type.28a50f.1 = struct_value () [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.LessOrEquivalent.type.1522a4.1: type = fn_type @T.as_type.as.OrderedWith.impl.LessOrEquivalent.4, @T.as_type.as.OrderedWith.impl.df2(%ImplicitAs.facet.2ed) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.LessOrEquivalent.type.1522a4.1: type = fn_type @T.as_type.as.OrderedWith.impl.LessOrEquivalent.6, @T.as_type.as.OrderedWith.impl.df2(%ImplicitAs.facet.2ed) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.LessOrEquivalent.b7cd44.1: %T.as_type.as.OrderedWith.impl.LessOrEquivalent.type.1522a4.1 = struct_value () [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.Greater.type.e2356e.1: type = fn_type @T.as_type.as.OrderedWith.impl.Greater.4, @T.as_type.as.OrderedWith.impl.df2(%ImplicitAs.facet.2ed) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.Greater.type.e2356e.1: type = fn_type @T.as_type.as.OrderedWith.impl.Greater.6, @T.as_type.as.OrderedWith.impl.df2(%ImplicitAs.facet.2ed) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.Greater.a80774.1: %T.as_type.as.OrderedWith.impl.Greater.type.e2356e.1 = struct_value () [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.type.09194f.1: type = fn_type @T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.4, @T.as_type.as.OrderedWith.impl.df2(%ImplicitAs.facet.2ed) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.type.09194f.1: type = fn_type @T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.6, @T.as_type.as.OrderedWith.impl.df2(%ImplicitAs.facet.2ed) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.ae8de7.1: %T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.type.09194f.1 = struct_value () [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.Less.type.28a50f.2: type = fn_type @T.as_type.as.OrderedWith.impl.Less.3, @T.as_type.as.OrderedWith.impl.df2(%ImplicitAs.facet.2ed) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.Less.type.28a50f.2: type = fn_type @T.as_type.as.OrderedWith.impl.Less.5, @T.as_type.as.OrderedWith.impl.df2(%ImplicitAs.facet.2ed) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.Less.09733d.2: %T.as_type.as.OrderedWith.impl.Less.type.28a50f.2 = struct_value () [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.LessOrEquivalent.type.1522a4.2: type = fn_type @T.as_type.as.OrderedWith.impl.LessOrEquivalent.3, @T.as_type.as.OrderedWith.impl.df2(%ImplicitAs.facet.2ed) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.LessOrEquivalent.type.1522a4.2: type = fn_type @T.as_type.as.OrderedWith.impl.LessOrEquivalent.5, @T.as_type.as.OrderedWith.impl.df2(%ImplicitAs.facet.2ed) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.LessOrEquivalent.b7cd44.2: %T.as_type.as.OrderedWith.impl.LessOrEquivalent.type.1522a4.2 = struct_value () [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.Greater.type.e2356e.2: type = fn_type @T.as_type.as.OrderedWith.impl.Greater.3, @T.as_type.as.OrderedWith.impl.df2(%ImplicitAs.facet.2ed) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.Greater.type.e2356e.2: type = fn_type @T.as_type.as.OrderedWith.impl.Greater.5, @T.as_type.as.OrderedWith.impl.df2(%ImplicitAs.facet.2ed) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.Greater.a80774.2: %T.as_type.as.OrderedWith.impl.Greater.type.e2356e.2 = struct_value () [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.type.09194f.2: type = fn_type @T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.3, @T.as_type.as.OrderedWith.impl.df2(%ImplicitAs.facet.2ed) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.type.09194f.2: type = fn_type @T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.5, @T.as_type.as.OrderedWith.impl.df2(%ImplicitAs.facet.2ed) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.ae8de7.2: %T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.type.09194f.2 = struct_value () [concrete]
|
||||
// CHECK:STDOUT: %OrderedWith.facet.54d: %OrderedWith.type.456 = facet_value Core.IntLiteral, (%OrderedWith.impl_witness.ccd) [concrete]
|
||||
// CHECK:STDOUT: %OrderedWith.WithSelf.Less.type.a56: type = fn_type @OrderedWith.WithSelf.Less, @OrderedWith.WithSelf(%Cpp.long_long, %OrderedWith.facet.54d) [concrete]
|
||||
@@ -2117,31 +2117,31 @@ fn CopyUnsignedLongLong() {
|
||||
// CHECK:STDOUT: %OrderedWith.WithSelf.GreaterOrEquivalent.type.6ad: type = fn_type @OrderedWith.WithSelf.GreaterOrEquivalent, @OrderedWith.WithSelf(%Cpp.long_long, %OrderedWith.facet.54d) [concrete]
|
||||
// CHECK:STDOUT: %.1e0: type = fn_type_with_self_type %OrderedWith.WithSelf.Greater.type.22c, %OrderedWith.facet.54d [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.Greater.bound.ba4552.1: <bound method> = bound_method %int_1.5b8, %T.as_type.as.OrderedWith.impl.Greater.a80774.2 [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.Greater.specific_fn.3eccd1.1: <specific function> = specific_function %T.as_type.as.OrderedWith.impl.Greater.a80774.2, @T.as_type.as.OrderedWith.impl.Greater.3(%ImplicitAs.facet.2ed) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.Greater.specific_fn.3eccd1.1: <specific function> = specific_function %T.as_type.as.OrderedWith.impl.Greater.a80774.2, @T.as_type.as.OrderedWith.impl.Greater.5(%ImplicitAs.facet.2ed) [concrete]
|
||||
// CHECK:STDOUT: %bound_method.560bca.1: <bound method> = bound_method %int_1.5b8, %T.as_type.as.OrderedWith.impl.Greater.specific_fn.3eccd1.1 [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.Greater.bound.ba4552.2: <bound method> = bound_method %int_1.5b8, %T.as_type.as.OrderedWith.impl.Greater.a80774.1 [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.Greater.specific_fn.3eccd1.2: <specific function> = specific_function %T.as_type.as.OrderedWith.impl.Greater.a80774.1, @T.as_type.as.OrderedWith.impl.Greater.4(%ImplicitAs.facet.2ed) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.Greater.specific_fn.3eccd1.2: <specific function> = specific_function %T.as_type.as.OrderedWith.impl.Greater.a80774.1, @T.as_type.as.OrderedWith.impl.Greater.6(%ImplicitAs.facet.2ed) [concrete]
|
||||
// CHECK:STDOUT: %bound_method.560bca.2: <bound method> = bound_method %int_1.5b8, %T.as_type.as.OrderedWith.impl.Greater.specific_fn.3eccd1.2 [concrete]
|
||||
// CHECK:STDOUT: %.4c9: type = fn_type_with_self_type %OrderedWith.WithSelf.Less.type.a56, %OrderedWith.facet.54d [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.Less.bound.069497.1: <bound method> = bound_method %int_1.5b8, %T.as_type.as.OrderedWith.impl.Less.09733d.2 [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.Less.specific_fn.0beaf8.1: <specific function> = specific_function %T.as_type.as.OrderedWith.impl.Less.09733d.2, @T.as_type.as.OrderedWith.impl.Less.3(%ImplicitAs.facet.2ed) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.Less.specific_fn.0beaf8.1: <specific function> = specific_function %T.as_type.as.OrderedWith.impl.Less.09733d.2, @T.as_type.as.OrderedWith.impl.Less.5(%ImplicitAs.facet.2ed) [concrete]
|
||||
// CHECK:STDOUT: %bound_method.103f49.1: <bound method> = bound_method %int_1.5b8, %T.as_type.as.OrderedWith.impl.Less.specific_fn.0beaf8.1 [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.Less.bound.069497.2: <bound method> = bound_method %int_1.5b8, %T.as_type.as.OrderedWith.impl.Less.09733d.1 [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.Less.specific_fn.0beaf8.2: <specific function> = specific_function %T.as_type.as.OrderedWith.impl.Less.09733d.1, @T.as_type.as.OrderedWith.impl.Less.4(%ImplicitAs.facet.2ed) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.Less.specific_fn.0beaf8.2: <specific function> = specific_function %T.as_type.as.OrderedWith.impl.Less.09733d.1, @T.as_type.as.OrderedWith.impl.Less.6(%ImplicitAs.facet.2ed) [concrete]
|
||||
// CHECK:STDOUT: %bound_method.103f49.2: <bound method> = bound_method %int_1.5b8, %T.as_type.as.OrderedWith.impl.Less.specific_fn.0beaf8.2 [concrete]
|
||||
// CHECK:STDOUT: %.b09: type = fn_type_with_self_type %OrderedWith.WithSelf.GreaterOrEquivalent.type.6ad, %OrderedWith.facet.54d [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.bound.22317d.1: <bound method> = bound_method %int_1.5b8, %T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.ae8de7.2 [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.specific_fn.371f57.1: <specific function> = specific_function %T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.ae8de7.2, @T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.3(%ImplicitAs.facet.2ed) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.specific_fn.371f57.1: <specific function> = specific_function %T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.ae8de7.2, @T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.5(%ImplicitAs.facet.2ed) [concrete]
|
||||
// CHECK:STDOUT: %bound_method.ffa540.1: <bound method> = bound_method %int_1.5b8, %T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.specific_fn.371f57.1 [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.bound.22317d.2: <bound method> = bound_method %int_1.5b8, %T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.ae8de7.1 [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.specific_fn.371f57.2: <specific function> = specific_function %T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.ae8de7.1, @T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.4(%ImplicitAs.facet.2ed) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.specific_fn.371f57.2: <specific function> = specific_function %T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.ae8de7.1, @T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.6(%ImplicitAs.facet.2ed) [concrete]
|
||||
// CHECK:STDOUT: %bound_method.ffa540.2: <bound method> = bound_method %int_1.5b8, %T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.specific_fn.371f57.2 [concrete]
|
||||
// CHECK:STDOUT: %.cab: type = fn_type_with_self_type %OrderedWith.WithSelf.LessOrEquivalent.type.21f, %OrderedWith.facet.54d [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.LessOrEquivalent.bound.2eaa72.1: <bound method> = bound_method %int_1.5b8, %T.as_type.as.OrderedWith.impl.LessOrEquivalent.b7cd44.2 [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.LessOrEquivalent.specific_fn.05fce2.1: <specific function> = specific_function %T.as_type.as.OrderedWith.impl.LessOrEquivalent.b7cd44.2, @T.as_type.as.OrderedWith.impl.LessOrEquivalent.3(%ImplicitAs.facet.2ed) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.LessOrEquivalent.specific_fn.05fce2.1: <specific function> = specific_function %T.as_type.as.OrderedWith.impl.LessOrEquivalent.b7cd44.2, @T.as_type.as.OrderedWith.impl.LessOrEquivalent.5(%ImplicitAs.facet.2ed) [concrete]
|
||||
// CHECK:STDOUT: %bound_method.83e687.1: <bound method> = bound_method %int_1.5b8, %T.as_type.as.OrderedWith.impl.LessOrEquivalent.specific_fn.05fce2.1 [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.LessOrEquivalent.bound.2eaa72.2: <bound method> = bound_method %int_1.5b8, %T.as_type.as.OrderedWith.impl.LessOrEquivalent.b7cd44.1 [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.LessOrEquivalent.specific_fn.05fce2.2: <specific function> = specific_function %T.as_type.as.OrderedWith.impl.LessOrEquivalent.b7cd44.1, @T.as_type.as.OrderedWith.impl.LessOrEquivalent.4(%ImplicitAs.facet.2ed) [concrete]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.LessOrEquivalent.specific_fn.05fce2.2: <specific function> = specific_function %T.as_type.as.OrderedWith.impl.LessOrEquivalent.b7cd44.1, @T.as_type.as.OrderedWith.impl.LessOrEquivalent.6(%ImplicitAs.facet.2ed) [concrete]
|
||||
// CHECK:STDOUT: %bound_method.83e687.2: <bound method> = bound_method %int_1.5b8, %T.as_type.as.OrderedWith.impl.LessOrEquivalent.specific_fn.05fce2.2 [concrete]
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
@@ -2195,12 +2195,12 @@ fn CopyUnsignedLongLong() {
|
||||
// CHECK:STDOUT: %.loc10_5.1: %ImplicitAs.type.0ec = converted constants.%i64, %ImplicitAs.facet.loc10_5.1 [concrete = constants.%ImplicitAs.facet.7a4]
|
||||
// CHECK:STDOUT: %ImplicitAs.facet.loc10_5.2: %ImplicitAs.type.0ec = facet_value constants.%i64, (constants.%ImplicitAs.impl_witness.305) [concrete = constants.%ImplicitAs.facet.7a4]
|
||||
// CHECK:STDOUT: %.loc10_5.2: %ImplicitAs.type.0ec = converted constants.%i64, %ImplicitAs.facet.loc10_5.2 [concrete = constants.%ImplicitAs.facet.7a4]
|
||||
// CHECK:STDOUT: %specific_fn.loc10: <specific function> = specific_function %impl.elem0.loc10_5, @T.as_type.as.EqWith.impl.Equal.3(constants.%ImplicitAs.facet.7a4) [concrete = constants.%T.as_type.as.EqWith.impl.Equal.specific_fn.044d32.1]
|
||||
// CHECK:STDOUT: %specific_fn.loc10: <specific function> = specific_function %impl.elem0.loc10_5, @T.as_type.as.EqWith.impl.Equal.5(constants.%ImplicitAs.facet.7a4) [concrete = constants.%T.as_type.as.EqWith.impl.Equal.specific_fn.044d32.1]
|
||||
// CHECK:STDOUT: %bound_method.loc10_5.2: <bound method> = bound_method %b.ref.loc10, %specific_fn.loc10
|
||||
// CHECK:STDOUT: %.loc10_5.3: %T.as_type.as.EqWith.impl.Equal.type.6d33d6.1 = specific_constant imports.%Core.Equal.4f5, @T.as_type.as.EqWith.impl.6d3(constants.%ImplicitAs.facet.7a4) [concrete = constants.%T.as_type.as.EqWith.impl.Equal.817082.1]
|
||||
// CHECK:STDOUT: %Equal.ref.loc10: %T.as_type.as.EqWith.impl.Equal.type.6d33d6.1 = name_ref Equal, %.loc10_5.3 [concrete = constants.%T.as_type.as.EqWith.impl.Equal.817082.1]
|
||||
// CHECK:STDOUT: %T.as_type.as.EqWith.impl.Equal.bound.loc10: <bound method> = bound_method %b.ref.loc10, %Equal.ref.loc10
|
||||
// CHECK:STDOUT: %T.as_type.as.EqWith.impl.Equal.specific_fn.loc10: <specific function> = specific_function %Equal.ref.loc10, @T.as_type.as.EqWith.impl.Equal.4(constants.%ImplicitAs.facet.7a4) [concrete = constants.%T.as_type.as.EqWith.impl.Equal.specific_fn.044d32.2]
|
||||
// CHECK:STDOUT: %T.as_type.as.EqWith.impl.Equal.specific_fn.loc10: <specific function> = specific_function %Equal.ref.loc10, @T.as_type.as.EqWith.impl.Equal.6(constants.%ImplicitAs.facet.7a4) [concrete = constants.%T.as_type.as.EqWith.impl.Equal.specific_fn.044d32.2]
|
||||
// CHECK:STDOUT: %bound_method.loc10_5.3: <bound method> = bound_method %b.ref.loc10, %T.as_type.as.EqWith.impl.Equal.specific_fn.loc10
|
||||
// CHECK:STDOUT: %impl.elem0.loc10_3: %.25e = impl_witness_access constants.%ImplicitAs.impl_witness.305, element0 [concrete = constants.%i64.as.ImplicitAs.impl.Convert]
|
||||
// CHECK:STDOUT: %bound_method.loc10_3: <bound method> = bound_method %b.ref.loc10, %impl.elem0.loc10_3
|
||||
@@ -2216,12 +2216,12 @@ fn CopyUnsignedLongLong() {
|
||||
// CHECK:STDOUT: %.loc11_5.1: %ImplicitAs.type.0ec = converted constants.%i64, %ImplicitAs.facet.loc11_5.1 [concrete = constants.%ImplicitAs.facet.7a4]
|
||||
// CHECK:STDOUT: %ImplicitAs.facet.loc11_5.2: %ImplicitAs.type.0ec = facet_value constants.%i64, (constants.%ImplicitAs.impl_witness.305) [concrete = constants.%ImplicitAs.facet.7a4]
|
||||
// CHECK:STDOUT: %.loc11_5.2: %ImplicitAs.type.0ec = converted constants.%i64, %ImplicitAs.facet.loc11_5.2 [concrete = constants.%ImplicitAs.facet.7a4]
|
||||
// CHECK:STDOUT: %specific_fn.loc11: <specific function> = specific_function %impl.elem1.loc11, @T.as_type.as.EqWith.impl.NotEqual.3(constants.%ImplicitAs.facet.7a4) [concrete = constants.%T.as_type.as.EqWith.impl.NotEqual.specific_fn.b44c79.1]
|
||||
// CHECK:STDOUT: %specific_fn.loc11: <specific function> = specific_function %impl.elem1.loc11, @T.as_type.as.EqWith.impl.NotEqual.5(constants.%ImplicitAs.facet.7a4) [concrete = constants.%T.as_type.as.EqWith.impl.NotEqual.specific_fn.b44c79.1]
|
||||
// CHECK:STDOUT: %bound_method.loc11_5.2: <bound method> = bound_method %b.ref.loc11, %specific_fn.loc11
|
||||
// CHECK:STDOUT: %.loc11_5.3: %T.as_type.as.EqWith.impl.NotEqual.type.2c42f8.1 = specific_constant imports.%Core.NotEqual.0b2, @T.as_type.as.EqWith.impl.6d3(constants.%ImplicitAs.facet.7a4) [concrete = constants.%T.as_type.as.EqWith.impl.NotEqual.de7c60.1]
|
||||
// CHECK:STDOUT: %NotEqual.ref.loc11: %T.as_type.as.EqWith.impl.NotEqual.type.2c42f8.1 = name_ref NotEqual, %.loc11_5.3 [concrete = constants.%T.as_type.as.EqWith.impl.NotEqual.de7c60.1]
|
||||
// CHECK:STDOUT: %T.as_type.as.EqWith.impl.NotEqual.bound.loc11: <bound method> = bound_method %b.ref.loc11, %NotEqual.ref.loc11
|
||||
// CHECK:STDOUT: %T.as_type.as.EqWith.impl.NotEqual.specific_fn.loc11: <specific function> = specific_function %NotEqual.ref.loc11, @T.as_type.as.EqWith.impl.NotEqual.4(constants.%ImplicitAs.facet.7a4) [concrete = constants.%T.as_type.as.EqWith.impl.NotEqual.specific_fn.b44c79.2]
|
||||
// CHECK:STDOUT: %T.as_type.as.EqWith.impl.NotEqual.specific_fn.loc11: <specific function> = specific_function %NotEqual.ref.loc11, @T.as_type.as.EqWith.impl.NotEqual.6(constants.%ImplicitAs.facet.7a4) [concrete = constants.%T.as_type.as.EqWith.impl.NotEqual.specific_fn.b44c79.2]
|
||||
// CHECK:STDOUT: %bound_method.loc11_5.3: <bound method> = bound_method %b.ref.loc11, %T.as_type.as.EqWith.impl.NotEqual.specific_fn.loc11
|
||||
// CHECK:STDOUT: %impl.elem0.loc11: %.25e = impl_witness_access constants.%ImplicitAs.impl_witness.305, element0 [concrete = constants.%i64.as.ImplicitAs.impl.Convert]
|
||||
// CHECK:STDOUT: %bound_method.loc11_3: <bound method> = bound_method %b.ref.loc11, %impl.elem0.loc11
|
||||
@@ -2237,12 +2237,12 @@ fn CopyUnsignedLongLong() {
|
||||
// CHECK:STDOUT: %.loc12_5.1: %ImplicitAs.type.0ec = converted constants.%i64, %ImplicitAs.facet.loc12_5.1 [concrete = constants.%ImplicitAs.facet.7a4]
|
||||
// CHECK:STDOUT: %ImplicitAs.facet.loc12_5.2: %ImplicitAs.type.0ec = facet_value constants.%i64, (constants.%ImplicitAs.impl_witness.305) [concrete = constants.%ImplicitAs.facet.7a4]
|
||||
// CHECK:STDOUT: %.loc12_5.2: %ImplicitAs.type.0ec = converted constants.%i64, %ImplicitAs.facet.loc12_5.2 [concrete = constants.%ImplicitAs.facet.7a4]
|
||||
// CHECK:STDOUT: %specific_fn.loc12: <specific function> = specific_function %impl.elem2.loc12, @T.as_type.as.OrderedWith.impl.Greater.3(constants.%ImplicitAs.facet.7a4) [concrete = constants.%T.as_type.as.OrderedWith.impl.Greater.specific_fn.cbc6c2.1]
|
||||
// CHECK:STDOUT: %specific_fn.loc12: <specific function> = specific_function %impl.elem2.loc12, @T.as_type.as.OrderedWith.impl.Greater.5(constants.%ImplicitAs.facet.7a4) [concrete = constants.%T.as_type.as.OrderedWith.impl.Greater.specific_fn.cbc6c2.1]
|
||||
// CHECK:STDOUT: %bound_method.loc12_5.2: <bound method> = bound_method %b.ref.loc12, %specific_fn.loc12
|
||||
// CHECK:STDOUT: %.loc12_5.3: %T.as_type.as.OrderedWith.impl.Greater.type.085dd9.1 = specific_constant imports.%Core.Greater.c24, @T.as_type.as.OrderedWith.impl.df2(constants.%ImplicitAs.facet.7a4) [concrete = constants.%T.as_type.as.OrderedWith.impl.Greater.749015.1]
|
||||
// CHECK:STDOUT: %Greater.ref.loc12: %T.as_type.as.OrderedWith.impl.Greater.type.085dd9.1 = name_ref Greater, %.loc12_5.3 [concrete = constants.%T.as_type.as.OrderedWith.impl.Greater.749015.1]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.Greater.bound.loc12: <bound method> = bound_method %b.ref.loc12, %Greater.ref.loc12
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.Greater.specific_fn.loc12: <specific function> = specific_function %Greater.ref.loc12, @T.as_type.as.OrderedWith.impl.Greater.4(constants.%ImplicitAs.facet.7a4) [concrete = constants.%T.as_type.as.OrderedWith.impl.Greater.specific_fn.cbc6c2.2]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.Greater.specific_fn.loc12: <specific function> = specific_function %Greater.ref.loc12, @T.as_type.as.OrderedWith.impl.Greater.6(constants.%ImplicitAs.facet.7a4) [concrete = constants.%T.as_type.as.OrderedWith.impl.Greater.specific_fn.cbc6c2.2]
|
||||
// CHECK:STDOUT: %bound_method.loc12_5.3: <bound method> = bound_method %b.ref.loc12, %T.as_type.as.OrderedWith.impl.Greater.specific_fn.loc12
|
||||
// CHECK:STDOUT: %impl.elem0.loc12: %.25e = impl_witness_access constants.%ImplicitAs.impl_witness.305, element0 [concrete = constants.%i64.as.ImplicitAs.impl.Convert]
|
||||
// CHECK:STDOUT: %bound_method.loc12_3: <bound method> = bound_method %b.ref.loc12, %impl.elem0.loc12
|
||||
@@ -2258,12 +2258,12 @@ fn CopyUnsignedLongLong() {
|
||||
// CHECK:STDOUT: %.loc13_5.1: %ImplicitAs.type.0ec = converted constants.%i64, %ImplicitAs.facet.loc13_5.1 [concrete = constants.%ImplicitAs.facet.7a4]
|
||||
// CHECK:STDOUT: %ImplicitAs.facet.loc13_5.2: %ImplicitAs.type.0ec = facet_value constants.%i64, (constants.%ImplicitAs.impl_witness.305) [concrete = constants.%ImplicitAs.facet.7a4]
|
||||
// CHECK:STDOUT: %.loc13_5.2: %ImplicitAs.type.0ec = converted constants.%i64, %ImplicitAs.facet.loc13_5.2 [concrete = constants.%ImplicitAs.facet.7a4]
|
||||
// CHECK:STDOUT: %specific_fn.loc13: <specific function> = specific_function %impl.elem0.loc13_5, @T.as_type.as.OrderedWith.impl.Less.3(constants.%ImplicitAs.facet.7a4) [concrete = constants.%T.as_type.as.OrderedWith.impl.Less.specific_fn.a8a2ad.1]
|
||||
// CHECK:STDOUT: %specific_fn.loc13: <specific function> = specific_function %impl.elem0.loc13_5, @T.as_type.as.OrderedWith.impl.Less.5(constants.%ImplicitAs.facet.7a4) [concrete = constants.%T.as_type.as.OrderedWith.impl.Less.specific_fn.a8a2ad.1]
|
||||
// CHECK:STDOUT: %bound_method.loc13_5.2: <bound method> = bound_method %b.ref.loc13, %specific_fn.loc13
|
||||
// CHECK:STDOUT: %.loc13_5.3: %T.as_type.as.OrderedWith.impl.Less.type.7b405f.1 = specific_constant imports.%Core.Less.2d9, @T.as_type.as.OrderedWith.impl.df2(constants.%ImplicitAs.facet.7a4) [concrete = constants.%T.as_type.as.OrderedWith.impl.Less.c5f236.1]
|
||||
// CHECK:STDOUT: %Less.ref.loc13: %T.as_type.as.OrderedWith.impl.Less.type.7b405f.1 = name_ref Less, %.loc13_5.3 [concrete = constants.%T.as_type.as.OrderedWith.impl.Less.c5f236.1]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.Less.bound.loc13: <bound method> = bound_method %b.ref.loc13, %Less.ref.loc13
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.Less.specific_fn.loc13: <specific function> = specific_function %Less.ref.loc13, @T.as_type.as.OrderedWith.impl.Less.4(constants.%ImplicitAs.facet.7a4) [concrete = constants.%T.as_type.as.OrderedWith.impl.Less.specific_fn.a8a2ad.2]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.Less.specific_fn.loc13: <specific function> = specific_function %Less.ref.loc13, @T.as_type.as.OrderedWith.impl.Less.6(constants.%ImplicitAs.facet.7a4) [concrete = constants.%T.as_type.as.OrderedWith.impl.Less.specific_fn.a8a2ad.2]
|
||||
// CHECK:STDOUT: %bound_method.loc13_5.3: <bound method> = bound_method %b.ref.loc13, %T.as_type.as.OrderedWith.impl.Less.specific_fn.loc13
|
||||
// CHECK:STDOUT: %impl.elem0.loc13_3: %.25e = impl_witness_access constants.%ImplicitAs.impl_witness.305, element0 [concrete = constants.%i64.as.ImplicitAs.impl.Convert]
|
||||
// CHECK:STDOUT: %bound_method.loc13_3: <bound method> = bound_method %b.ref.loc13, %impl.elem0.loc13_3
|
||||
@@ -2279,12 +2279,12 @@ fn CopyUnsignedLongLong() {
|
||||
// CHECK:STDOUT: %.loc14_5.1: %ImplicitAs.type.0ec = converted constants.%i64, %ImplicitAs.facet.loc14_5.1 [concrete = constants.%ImplicitAs.facet.7a4]
|
||||
// CHECK:STDOUT: %ImplicitAs.facet.loc14_5.2: %ImplicitAs.type.0ec = facet_value constants.%i64, (constants.%ImplicitAs.impl_witness.305) [concrete = constants.%ImplicitAs.facet.7a4]
|
||||
// CHECK:STDOUT: %.loc14_5.2: %ImplicitAs.type.0ec = converted constants.%i64, %ImplicitAs.facet.loc14_5.2 [concrete = constants.%ImplicitAs.facet.7a4]
|
||||
// CHECK:STDOUT: %specific_fn.loc14: <specific function> = specific_function %impl.elem3.loc14, @T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.3(constants.%ImplicitAs.facet.7a4) [concrete = constants.%T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.specific_fn.8a93e9.1]
|
||||
// CHECK:STDOUT: %specific_fn.loc14: <specific function> = specific_function %impl.elem3.loc14, @T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.5(constants.%ImplicitAs.facet.7a4) [concrete = constants.%T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.specific_fn.8a93e9.1]
|
||||
// CHECK:STDOUT: %bound_method.loc14_5.2: <bound method> = bound_method %b.ref.loc14, %specific_fn.loc14
|
||||
// CHECK:STDOUT: %.loc14_5.3: %T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.type.0f0b65.1 = specific_constant imports.%Core.GreaterOrEquivalent.8e2, @T.as_type.as.OrderedWith.impl.df2(constants.%ImplicitAs.facet.7a4) [concrete = constants.%T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.f86b3e.1]
|
||||
// CHECK:STDOUT: %GreaterOrEquivalent.ref.loc14: %T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.type.0f0b65.1 = name_ref GreaterOrEquivalent, %.loc14_5.3 [concrete = constants.%T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.f86b3e.1]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.bound.loc14: <bound method> = bound_method %b.ref.loc14, %GreaterOrEquivalent.ref.loc14
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.specific_fn.loc14: <specific function> = specific_function %GreaterOrEquivalent.ref.loc14, @T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.4(constants.%ImplicitAs.facet.7a4) [concrete = constants.%T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.specific_fn.8a93e9.2]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.specific_fn.loc14: <specific function> = specific_function %GreaterOrEquivalent.ref.loc14, @T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.6(constants.%ImplicitAs.facet.7a4) [concrete = constants.%T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.specific_fn.8a93e9.2]
|
||||
// CHECK:STDOUT: %bound_method.loc14_5.3: <bound method> = bound_method %b.ref.loc14, %T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.specific_fn.loc14
|
||||
// CHECK:STDOUT: %impl.elem0.loc14: %.25e = impl_witness_access constants.%ImplicitAs.impl_witness.305, element0 [concrete = constants.%i64.as.ImplicitAs.impl.Convert]
|
||||
// CHECK:STDOUT: %bound_method.loc14_3: <bound method> = bound_method %b.ref.loc14, %impl.elem0.loc14
|
||||
@@ -2300,12 +2300,12 @@ fn CopyUnsignedLongLong() {
|
||||
// CHECK:STDOUT: %.loc15_5.1: %ImplicitAs.type.0ec = converted constants.%i64, %ImplicitAs.facet.loc15_5.1 [concrete = constants.%ImplicitAs.facet.7a4]
|
||||
// CHECK:STDOUT: %ImplicitAs.facet.loc15_5.2: %ImplicitAs.type.0ec = facet_value constants.%i64, (constants.%ImplicitAs.impl_witness.305) [concrete = constants.%ImplicitAs.facet.7a4]
|
||||
// CHECK:STDOUT: %.loc15_5.2: %ImplicitAs.type.0ec = converted constants.%i64, %ImplicitAs.facet.loc15_5.2 [concrete = constants.%ImplicitAs.facet.7a4]
|
||||
// CHECK:STDOUT: %specific_fn.loc15: <specific function> = specific_function %impl.elem1.loc15, @T.as_type.as.OrderedWith.impl.LessOrEquivalent.3(constants.%ImplicitAs.facet.7a4) [concrete = constants.%T.as_type.as.OrderedWith.impl.LessOrEquivalent.specific_fn.ab9ff7.1]
|
||||
// CHECK:STDOUT: %specific_fn.loc15: <specific function> = specific_function %impl.elem1.loc15, @T.as_type.as.OrderedWith.impl.LessOrEquivalent.5(constants.%ImplicitAs.facet.7a4) [concrete = constants.%T.as_type.as.OrderedWith.impl.LessOrEquivalent.specific_fn.ab9ff7.1]
|
||||
// CHECK:STDOUT: %bound_method.loc15_5.2: <bound method> = bound_method %b.ref.loc15, %specific_fn.loc15
|
||||
// CHECK:STDOUT: %.loc15_5.3: %T.as_type.as.OrderedWith.impl.LessOrEquivalent.type.577251.1 = specific_constant imports.%Core.LessOrEquivalent.d90, @T.as_type.as.OrderedWith.impl.df2(constants.%ImplicitAs.facet.7a4) [concrete = constants.%T.as_type.as.OrderedWith.impl.LessOrEquivalent.e5cfba.1]
|
||||
// CHECK:STDOUT: %LessOrEquivalent.ref.loc15: %T.as_type.as.OrderedWith.impl.LessOrEquivalent.type.577251.1 = name_ref LessOrEquivalent, %.loc15_5.3 [concrete = constants.%T.as_type.as.OrderedWith.impl.LessOrEquivalent.e5cfba.1]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.LessOrEquivalent.bound.loc15: <bound method> = bound_method %b.ref.loc15, %LessOrEquivalent.ref.loc15
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.LessOrEquivalent.specific_fn.loc15: <specific function> = specific_function %LessOrEquivalent.ref.loc15, @T.as_type.as.OrderedWith.impl.LessOrEquivalent.4(constants.%ImplicitAs.facet.7a4) [concrete = constants.%T.as_type.as.OrderedWith.impl.LessOrEquivalent.specific_fn.ab9ff7.2]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.LessOrEquivalent.specific_fn.loc15: <specific function> = specific_function %LessOrEquivalent.ref.loc15, @T.as_type.as.OrderedWith.impl.LessOrEquivalent.6(constants.%ImplicitAs.facet.7a4) [concrete = constants.%T.as_type.as.OrderedWith.impl.LessOrEquivalent.specific_fn.ab9ff7.2]
|
||||
// CHECK:STDOUT: %bound_method.loc15_5.3: <bound method> = bound_method %b.ref.loc15, %T.as_type.as.OrderedWith.impl.LessOrEquivalent.specific_fn.loc15
|
||||
// CHECK:STDOUT: %impl.elem0.loc15: %.25e = impl_witness_access constants.%ImplicitAs.impl_witness.305, element0 [concrete = constants.%i64.as.ImplicitAs.impl.Convert]
|
||||
// CHECK:STDOUT: %bound_method.loc15_3: <bound method> = bound_method %b.ref.loc15, %impl.elem0.loc15
|
||||
@@ -2321,12 +2321,12 @@ fn CopyUnsignedLongLong() {
|
||||
// CHECK:STDOUT: %.loc17_5.1: %ImplicitAs.type.0ec = converted Core.IntLiteral, %ImplicitAs.facet.loc17_5.1 [concrete = constants.%ImplicitAs.facet.2ed]
|
||||
// CHECK:STDOUT: %ImplicitAs.facet.loc17_5.2: %ImplicitAs.type.0ec = facet_value Core.IntLiteral, (constants.%ImplicitAs.impl_witness.660) [concrete = constants.%ImplicitAs.facet.2ed]
|
||||
// CHECK:STDOUT: %.loc17_5.2: %ImplicitAs.type.0ec = converted Core.IntLiteral, %ImplicitAs.facet.loc17_5.2 [concrete = constants.%ImplicitAs.facet.2ed]
|
||||
// CHECK:STDOUT: %specific_fn.loc17: <specific function> = specific_function %impl.elem0.loc17_5, @T.as_type.as.EqWith.impl.Equal.3(constants.%ImplicitAs.facet.2ed) [concrete = constants.%T.as_type.as.EqWith.impl.Equal.specific_fn.7834c5.1]
|
||||
// CHECK:STDOUT: %specific_fn.loc17: <specific function> = specific_function %impl.elem0.loc17_5, @T.as_type.as.EqWith.impl.Equal.5(constants.%ImplicitAs.facet.2ed) [concrete = constants.%T.as_type.as.EqWith.impl.Equal.specific_fn.7834c5.1]
|
||||
// CHECK:STDOUT: %bound_method.loc17_5.2: <bound method> = bound_method %int_1.loc17, %specific_fn.loc17 [concrete = constants.%bound_method.7c9d36.1]
|
||||
// CHECK:STDOUT: %.loc17_5.3: %T.as_type.as.EqWith.impl.Equal.type.8e6244.1 = specific_constant imports.%Core.Equal.4f5, @T.as_type.as.EqWith.impl.6d3(constants.%ImplicitAs.facet.2ed) [concrete = constants.%T.as_type.as.EqWith.impl.Equal.66756b.1]
|
||||
// CHECK:STDOUT: %Equal.ref.loc17: %T.as_type.as.EqWith.impl.Equal.type.8e6244.1 = name_ref Equal, %.loc17_5.3 [concrete = constants.%T.as_type.as.EqWith.impl.Equal.66756b.1]
|
||||
// CHECK:STDOUT: %T.as_type.as.EqWith.impl.Equal.bound.loc17: <bound method> = bound_method %int_1.loc17, %Equal.ref.loc17 [concrete = constants.%T.as_type.as.EqWith.impl.Equal.bound.2fcdd5.2]
|
||||
// CHECK:STDOUT: %T.as_type.as.EqWith.impl.Equal.specific_fn.loc17: <specific function> = specific_function %Equal.ref.loc17, @T.as_type.as.EqWith.impl.Equal.4(constants.%ImplicitAs.facet.2ed) [concrete = constants.%T.as_type.as.EqWith.impl.Equal.specific_fn.7834c5.2]
|
||||
// CHECK:STDOUT: %T.as_type.as.EqWith.impl.Equal.specific_fn.loc17: <specific function> = specific_function %Equal.ref.loc17, @T.as_type.as.EqWith.impl.Equal.6(constants.%ImplicitAs.facet.2ed) [concrete = constants.%T.as_type.as.EqWith.impl.Equal.specific_fn.7834c5.2]
|
||||
// CHECK:STDOUT: %bound_method.loc17_5.3: <bound method> = bound_method %int_1.loc17, %T.as_type.as.EqWith.impl.Equal.specific_fn.loc17 [concrete = constants.%bound_method.7c9d36.2]
|
||||
// CHECK:STDOUT: %impl.elem0.loc17_3: %.ca2 = impl_witness_access constants.%ImplicitAs.impl_witness.660, element0 [concrete = constants.%Core.IntLiteral.as.ImplicitAs.impl.Convert.3ce]
|
||||
// CHECK:STDOUT: %bound_method.loc17_3: <bound method> = bound_method %int_1.loc17, %impl.elem0.loc17_3 [concrete = constants.%Core.IntLiteral.as.ImplicitAs.impl.Convert.bound.5d7]
|
||||
@@ -2342,12 +2342,12 @@ fn CopyUnsignedLongLong() {
|
||||
// CHECK:STDOUT: %.loc18_5.1: %ImplicitAs.type.0ec = converted Core.IntLiteral, %ImplicitAs.facet.loc18_5.1 [concrete = constants.%ImplicitAs.facet.2ed]
|
||||
// CHECK:STDOUT: %ImplicitAs.facet.loc18_5.2: %ImplicitAs.type.0ec = facet_value Core.IntLiteral, (constants.%ImplicitAs.impl_witness.660) [concrete = constants.%ImplicitAs.facet.2ed]
|
||||
// CHECK:STDOUT: %.loc18_5.2: %ImplicitAs.type.0ec = converted Core.IntLiteral, %ImplicitAs.facet.loc18_5.2 [concrete = constants.%ImplicitAs.facet.2ed]
|
||||
// CHECK:STDOUT: %specific_fn.loc18: <specific function> = specific_function %impl.elem1.loc18, @T.as_type.as.EqWith.impl.NotEqual.3(constants.%ImplicitAs.facet.2ed) [concrete = constants.%T.as_type.as.EqWith.impl.NotEqual.specific_fn.598adf.1]
|
||||
// CHECK:STDOUT: %specific_fn.loc18: <specific function> = specific_function %impl.elem1.loc18, @T.as_type.as.EqWith.impl.NotEqual.5(constants.%ImplicitAs.facet.2ed) [concrete = constants.%T.as_type.as.EqWith.impl.NotEqual.specific_fn.598adf.1]
|
||||
// CHECK:STDOUT: %bound_method.loc18_5.2: <bound method> = bound_method %int_1.loc18, %specific_fn.loc18 [concrete = constants.%bound_method.1f073e.1]
|
||||
// CHECK:STDOUT: %.loc18_5.3: %T.as_type.as.EqWith.impl.NotEqual.type.fb7a86.1 = specific_constant imports.%Core.NotEqual.0b2, @T.as_type.as.EqWith.impl.6d3(constants.%ImplicitAs.facet.2ed) [concrete = constants.%T.as_type.as.EqWith.impl.NotEqual.672038.1]
|
||||
// CHECK:STDOUT: %NotEqual.ref.loc18: %T.as_type.as.EqWith.impl.NotEqual.type.fb7a86.1 = name_ref NotEqual, %.loc18_5.3 [concrete = constants.%T.as_type.as.EqWith.impl.NotEqual.672038.1]
|
||||
// CHECK:STDOUT: %T.as_type.as.EqWith.impl.NotEqual.bound.loc18: <bound method> = bound_method %int_1.loc18, %NotEqual.ref.loc18 [concrete = constants.%T.as_type.as.EqWith.impl.NotEqual.bound.a9911b.2]
|
||||
// CHECK:STDOUT: %T.as_type.as.EqWith.impl.NotEqual.specific_fn.loc18: <specific function> = specific_function %NotEqual.ref.loc18, @T.as_type.as.EqWith.impl.NotEqual.4(constants.%ImplicitAs.facet.2ed) [concrete = constants.%T.as_type.as.EqWith.impl.NotEqual.specific_fn.598adf.2]
|
||||
// CHECK:STDOUT: %T.as_type.as.EqWith.impl.NotEqual.specific_fn.loc18: <specific function> = specific_function %NotEqual.ref.loc18, @T.as_type.as.EqWith.impl.NotEqual.6(constants.%ImplicitAs.facet.2ed) [concrete = constants.%T.as_type.as.EqWith.impl.NotEqual.specific_fn.598adf.2]
|
||||
// CHECK:STDOUT: %bound_method.loc18_5.3: <bound method> = bound_method %int_1.loc18, %T.as_type.as.EqWith.impl.NotEqual.specific_fn.loc18 [concrete = constants.%bound_method.1f073e.2]
|
||||
// CHECK:STDOUT: %impl.elem0.loc18: %.ca2 = impl_witness_access constants.%ImplicitAs.impl_witness.660, element0 [concrete = constants.%Core.IntLiteral.as.ImplicitAs.impl.Convert.3ce]
|
||||
// CHECK:STDOUT: %bound_method.loc18_3: <bound method> = bound_method %int_1.loc18, %impl.elem0.loc18 [concrete = constants.%Core.IntLiteral.as.ImplicitAs.impl.Convert.bound.5d7]
|
||||
@@ -2363,12 +2363,12 @@ fn CopyUnsignedLongLong() {
|
||||
// CHECK:STDOUT: %.loc19_5.1: %ImplicitAs.type.0ec = converted Core.IntLiteral, %ImplicitAs.facet.loc19_5.1 [concrete = constants.%ImplicitAs.facet.2ed]
|
||||
// CHECK:STDOUT: %ImplicitAs.facet.loc19_5.2: %ImplicitAs.type.0ec = facet_value Core.IntLiteral, (constants.%ImplicitAs.impl_witness.660) [concrete = constants.%ImplicitAs.facet.2ed]
|
||||
// CHECK:STDOUT: %.loc19_5.2: %ImplicitAs.type.0ec = converted Core.IntLiteral, %ImplicitAs.facet.loc19_5.2 [concrete = constants.%ImplicitAs.facet.2ed]
|
||||
// CHECK:STDOUT: %specific_fn.loc19: <specific function> = specific_function %impl.elem2.loc19, @T.as_type.as.OrderedWith.impl.Greater.3(constants.%ImplicitAs.facet.2ed) [concrete = constants.%T.as_type.as.OrderedWith.impl.Greater.specific_fn.3eccd1.1]
|
||||
// CHECK:STDOUT: %specific_fn.loc19: <specific function> = specific_function %impl.elem2.loc19, @T.as_type.as.OrderedWith.impl.Greater.5(constants.%ImplicitAs.facet.2ed) [concrete = constants.%T.as_type.as.OrderedWith.impl.Greater.specific_fn.3eccd1.1]
|
||||
// CHECK:STDOUT: %bound_method.loc19_5.2: <bound method> = bound_method %int_1.loc19, %specific_fn.loc19 [concrete = constants.%bound_method.560bca.1]
|
||||
// CHECK:STDOUT: %.loc19_5.3: %T.as_type.as.OrderedWith.impl.Greater.type.e2356e.1 = specific_constant imports.%Core.Greater.c24, @T.as_type.as.OrderedWith.impl.df2(constants.%ImplicitAs.facet.2ed) [concrete = constants.%T.as_type.as.OrderedWith.impl.Greater.a80774.1]
|
||||
// CHECK:STDOUT: %Greater.ref.loc19: %T.as_type.as.OrderedWith.impl.Greater.type.e2356e.1 = name_ref Greater, %.loc19_5.3 [concrete = constants.%T.as_type.as.OrderedWith.impl.Greater.a80774.1]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.Greater.bound.loc19: <bound method> = bound_method %int_1.loc19, %Greater.ref.loc19 [concrete = constants.%T.as_type.as.OrderedWith.impl.Greater.bound.ba4552.2]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.Greater.specific_fn.loc19: <specific function> = specific_function %Greater.ref.loc19, @T.as_type.as.OrderedWith.impl.Greater.4(constants.%ImplicitAs.facet.2ed) [concrete = constants.%T.as_type.as.OrderedWith.impl.Greater.specific_fn.3eccd1.2]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.Greater.specific_fn.loc19: <specific function> = specific_function %Greater.ref.loc19, @T.as_type.as.OrderedWith.impl.Greater.6(constants.%ImplicitAs.facet.2ed) [concrete = constants.%T.as_type.as.OrderedWith.impl.Greater.specific_fn.3eccd1.2]
|
||||
// CHECK:STDOUT: %bound_method.loc19_5.3: <bound method> = bound_method %int_1.loc19, %T.as_type.as.OrderedWith.impl.Greater.specific_fn.loc19 [concrete = constants.%bound_method.560bca.2]
|
||||
// CHECK:STDOUT: %impl.elem0.loc19: %.ca2 = impl_witness_access constants.%ImplicitAs.impl_witness.660, element0 [concrete = constants.%Core.IntLiteral.as.ImplicitAs.impl.Convert.3ce]
|
||||
// CHECK:STDOUT: %bound_method.loc19_3: <bound method> = bound_method %int_1.loc19, %impl.elem0.loc19 [concrete = constants.%Core.IntLiteral.as.ImplicitAs.impl.Convert.bound.5d7]
|
||||
@@ -2384,12 +2384,12 @@ fn CopyUnsignedLongLong() {
|
||||
// CHECK:STDOUT: %.loc20_5.1: %ImplicitAs.type.0ec = converted Core.IntLiteral, %ImplicitAs.facet.loc20_5.1 [concrete = constants.%ImplicitAs.facet.2ed]
|
||||
// CHECK:STDOUT: %ImplicitAs.facet.loc20_5.2: %ImplicitAs.type.0ec = facet_value Core.IntLiteral, (constants.%ImplicitAs.impl_witness.660) [concrete = constants.%ImplicitAs.facet.2ed]
|
||||
// CHECK:STDOUT: %.loc20_5.2: %ImplicitAs.type.0ec = converted Core.IntLiteral, %ImplicitAs.facet.loc20_5.2 [concrete = constants.%ImplicitAs.facet.2ed]
|
||||
// CHECK:STDOUT: %specific_fn.loc20: <specific function> = specific_function %impl.elem0.loc20_5, @T.as_type.as.OrderedWith.impl.Less.3(constants.%ImplicitAs.facet.2ed) [concrete = constants.%T.as_type.as.OrderedWith.impl.Less.specific_fn.0beaf8.1]
|
||||
// CHECK:STDOUT: %specific_fn.loc20: <specific function> = specific_function %impl.elem0.loc20_5, @T.as_type.as.OrderedWith.impl.Less.5(constants.%ImplicitAs.facet.2ed) [concrete = constants.%T.as_type.as.OrderedWith.impl.Less.specific_fn.0beaf8.1]
|
||||
// CHECK:STDOUT: %bound_method.loc20_5.2: <bound method> = bound_method %int_1.loc20, %specific_fn.loc20 [concrete = constants.%bound_method.103f49.1]
|
||||
// CHECK:STDOUT: %.loc20_5.3: %T.as_type.as.OrderedWith.impl.Less.type.28a50f.1 = specific_constant imports.%Core.Less.2d9, @T.as_type.as.OrderedWith.impl.df2(constants.%ImplicitAs.facet.2ed) [concrete = constants.%T.as_type.as.OrderedWith.impl.Less.09733d.1]
|
||||
// CHECK:STDOUT: %Less.ref.loc20: %T.as_type.as.OrderedWith.impl.Less.type.28a50f.1 = name_ref Less, %.loc20_5.3 [concrete = constants.%T.as_type.as.OrderedWith.impl.Less.09733d.1]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.Less.bound.loc20: <bound method> = bound_method %int_1.loc20, %Less.ref.loc20 [concrete = constants.%T.as_type.as.OrderedWith.impl.Less.bound.069497.2]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.Less.specific_fn.loc20: <specific function> = specific_function %Less.ref.loc20, @T.as_type.as.OrderedWith.impl.Less.4(constants.%ImplicitAs.facet.2ed) [concrete = constants.%T.as_type.as.OrderedWith.impl.Less.specific_fn.0beaf8.2]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.Less.specific_fn.loc20: <specific function> = specific_function %Less.ref.loc20, @T.as_type.as.OrderedWith.impl.Less.6(constants.%ImplicitAs.facet.2ed) [concrete = constants.%T.as_type.as.OrderedWith.impl.Less.specific_fn.0beaf8.2]
|
||||
// CHECK:STDOUT: %bound_method.loc20_5.3: <bound method> = bound_method %int_1.loc20, %T.as_type.as.OrderedWith.impl.Less.specific_fn.loc20 [concrete = constants.%bound_method.103f49.2]
|
||||
// CHECK:STDOUT: %impl.elem0.loc20_3: %.ca2 = impl_witness_access constants.%ImplicitAs.impl_witness.660, element0 [concrete = constants.%Core.IntLiteral.as.ImplicitAs.impl.Convert.3ce]
|
||||
// CHECK:STDOUT: %bound_method.loc20_3: <bound method> = bound_method %int_1.loc20, %impl.elem0.loc20_3 [concrete = constants.%Core.IntLiteral.as.ImplicitAs.impl.Convert.bound.5d7]
|
||||
@@ -2405,12 +2405,12 @@ fn CopyUnsignedLongLong() {
|
||||
// CHECK:STDOUT: %.loc21_5.1: %ImplicitAs.type.0ec = converted Core.IntLiteral, %ImplicitAs.facet.loc21_5.1 [concrete = constants.%ImplicitAs.facet.2ed]
|
||||
// CHECK:STDOUT: %ImplicitAs.facet.loc21_5.2: %ImplicitAs.type.0ec = facet_value Core.IntLiteral, (constants.%ImplicitAs.impl_witness.660) [concrete = constants.%ImplicitAs.facet.2ed]
|
||||
// CHECK:STDOUT: %.loc21_5.2: %ImplicitAs.type.0ec = converted Core.IntLiteral, %ImplicitAs.facet.loc21_5.2 [concrete = constants.%ImplicitAs.facet.2ed]
|
||||
// CHECK:STDOUT: %specific_fn.loc21: <specific function> = specific_function %impl.elem3.loc21, @T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.3(constants.%ImplicitAs.facet.2ed) [concrete = constants.%T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.specific_fn.371f57.1]
|
||||
// CHECK:STDOUT: %specific_fn.loc21: <specific function> = specific_function %impl.elem3.loc21, @T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.5(constants.%ImplicitAs.facet.2ed) [concrete = constants.%T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.specific_fn.371f57.1]
|
||||
// CHECK:STDOUT: %bound_method.loc21_5.2: <bound method> = bound_method %int_1.loc21, %specific_fn.loc21 [concrete = constants.%bound_method.ffa540.1]
|
||||
// CHECK:STDOUT: %.loc21_5.3: %T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.type.09194f.1 = specific_constant imports.%Core.GreaterOrEquivalent.8e2, @T.as_type.as.OrderedWith.impl.df2(constants.%ImplicitAs.facet.2ed) [concrete = constants.%T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.ae8de7.1]
|
||||
// CHECK:STDOUT: %GreaterOrEquivalent.ref.loc21: %T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.type.09194f.1 = name_ref GreaterOrEquivalent, %.loc21_5.3 [concrete = constants.%T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.ae8de7.1]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.bound.loc21: <bound method> = bound_method %int_1.loc21, %GreaterOrEquivalent.ref.loc21 [concrete = constants.%T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.bound.22317d.2]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.specific_fn.loc21: <specific function> = specific_function %GreaterOrEquivalent.ref.loc21, @T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.4(constants.%ImplicitAs.facet.2ed) [concrete = constants.%T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.specific_fn.371f57.2]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.specific_fn.loc21: <specific function> = specific_function %GreaterOrEquivalent.ref.loc21, @T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.6(constants.%ImplicitAs.facet.2ed) [concrete = constants.%T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.specific_fn.371f57.2]
|
||||
// CHECK:STDOUT: %bound_method.loc21_5.3: <bound method> = bound_method %int_1.loc21, %T.as_type.as.OrderedWith.impl.GreaterOrEquivalent.specific_fn.loc21 [concrete = constants.%bound_method.ffa540.2]
|
||||
// CHECK:STDOUT: %impl.elem0.loc21: %.ca2 = impl_witness_access constants.%ImplicitAs.impl_witness.660, element0 [concrete = constants.%Core.IntLiteral.as.ImplicitAs.impl.Convert.3ce]
|
||||
// CHECK:STDOUT: %bound_method.loc21_3: <bound method> = bound_method %int_1.loc21, %impl.elem0.loc21 [concrete = constants.%Core.IntLiteral.as.ImplicitAs.impl.Convert.bound.5d7]
|
||||
@@ -2426,12 +2426,12 @@ fn CopyUnsignedLongLong() {
|
||||
// CHECK:STDOUT: %.loc22_5.1: %ImplicitAs.type.0ec = converted Core.IntLiteral, %ImplicitAs.facet.loc22_5.1 [concrete = constants.%ImplicitAs.facet.2ed]
|
||||
// CHECK:STDOUT: %ImplicitAs.facet.loc22_5.2: %ImplicitAs.type.0ec = facet_value Core.IntLiteral, (constants.%ImplicitAs.impl_witness.660) [concrete = constants.%ImplicitAs.facet.2ed]
|
||||
// CHECK:STDOUT: %.loc22_5.2: %ImplicitAs.type.0ec = converted Core.IntLiteral, %ImplicitAs.facet.loc22_5.2 [concrete = constants.%ImplicitAs.facet.2ed]
|
||||
// CHECK:STDOUT: %specific_fn.loc22: <specific function> = specific_function %impl.elem1.loc22, @T.as_type.as.OrderedWith.impl.LessOrEquivalent.3(constants.%ImplicitAs.facet.2ed) [concrete = constants.%T.as_type.as.OrderedWith.impl.LessOrEquivalent.specific_fn.05fce2.1]
|
||||
// CHECK:STDOUT: %specific_fn.loc22: <specific function> = specific_function %impl.elem1.loc22, @T.as_type.as.OrderedWith.impl.LessOrEquivalent.5(constants.%ImplicitAs.facet.2ed) [concrete = constants.%T.as_type.as.OrderedWith.impl.LessOrEquivalent.specific_fn.05fce2.1]
|
||||
// CHECK:STDOUT: %bound_method.loc22_5.2: <bound method> = bound_method %int_1.loc22, %specific_fn.loc22 [concrete = constants.%bound_method.83e687.1]
|
||||
// CHECK:STDOUT: %.loc22_5.3: %T.as_type.as.OrderedWith.impl.LessOrEquivalent.type.1522a4.1 = specific_constant imports.%Core.LessOrEquivalent.d90, @T.as_type.as.OrderedWith.impl.df2(constants.%ImplicitAs.facet.2ed) [concrete = constants.%T.as_type.as.OrderedWith.impl.LessOrEquivalent.b7cd44.1]
|
||||
// CHECK:STDOUT: %LessOrEquivalent.ref.loc22: %T.as_type.as.OrderedWith.impl.LessOrEquivalent.type.1522a4.1 = name_ref LessOrEquivalent, %.loc22_5.3 [concrete = constants.%T.as_type.as.OrderedWith.impl.LessOrEquivalent.b7cd44.1]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.LessOrEquivalent.bound.loc22: <bound method> = bound_method %int_1.loc22, %LessOrEquivalent.ref.loc22 [concrete = constants.%T.as_type.as.OrderedWith.impl.LessOrEquivalent.bound.2eaa72.2]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.LessOrEquivalent.specific_fn.loc22: <specific function> = specific_function %LessOrEquivalent.ref.loc22, @T.as_type.as.OrderedWith.impl.LessOrEquivalent.4(constants.%ImplicitAs.facet.2ed) [concrete = constants.%T.as_type.as.OrderedWith.impl.LessOrEquivalent.specific_fn.05fce2.2]
|
||||
// CHECK:STDOUT: %T.as_type.as.OrderedWith.impl.LessOrEquivalent.specific_fn.loc22: <specific function> = specific_function %LessOrEquivalent.ref.loc22, @T.as_type.as.OrderedWith.impl.LessOrEquivalent.6(constants.%ImplicitAs.facet.2ed) [concrete = constants.%T.as_type.as.OrderedWith.impl.LessOrEquivalent.specific_fn.05fce2.2]
|
||||
// CHECK:STDOUT: %bound_method.loc22_5.3: <bound method> = bound_method %int_1.loc22, %T.as_type.as.OrderedWith.impl.LessOrEquivalent.specific_fn.loc22 [concrete = constants.%bound_method.83e687.2]
|
||||
// CHECK:STDOUT: %impl.elem0.loc22: %.ca2 = impl_witness_access constants.%ImplicitAs.impl_witness.660, element0 [concrete = constants.%Core.IntLiteral.as.ImplicitAs.impl.Convert.3ce]
|
||||
// CHECK:STDOUT: %bound_method.loc22_3: <bound method> = bound_method %int_1.loc22, %impl.elem0.loc22 [concrete = constants.%Core.IntLiteral.as.ImplicitAs.impl.Convert.bound.5d7]
|
||||
|
||||
+92
-27
@@ -53,8 +53,23 @@ fn TestFailures() {
|
||||
library "[[@TEST_NAME]]";
|
||||
|
||||
fn TestCppCompat() {
|
||||
var c: i32 = 1;
|
||||
var unused d: Core.CppCompat.Long32 = c;
|
||||
var a: i32 = 1;
|
||||
var unused b: Core.CppCompat.Long32 = a;
|
||||
|
||||
var c: u32 = 1;
|
||||
var unused d: Core.CppCompat.ULong32 = c;
|
||||
|
||||
var e: Core.CppCompat.Long64 = 1;
|
||||
var unused f: i64 = e;
|
||||
|
||||
var g: Core.CppCompat.ULong64 = 1;
|
||||
var unused h: u64 = g;
|
||||
|
||||
var i: i64 = 1;
|
||||
var unused j: Core.CppCompat.LongLong64 = i;
|
||||
|
||||
var k: u64 = 1;
|
||||
var unused l: Core.CppCompat.ULongLong64 = k;
|
||||
}
|
||||
|
||||
// --- fail_todo_cpp_compat_widen.carbon
|
||||
@@ -76,47 +91,75 @@ fn TestCppCompat() {
|
||||
// CHECK:STDERR:
|
||||
var unused b: i33 = a;
|
||||
|
||||
var c: Core.CppCompat.LongLong64 = 1;
|
||||
var c: Core.CppCompat.Long64 = 1;
|
||||
// CHECK:STDERR: fail_todo_cpp_compat_widen.carbon:[[@LINE+11]]:17: error: bit width of integer type literal must be a multiple of 8; use `Core.Int(65)` instead [IntWidthNotMultipleOf8]
|
||||
// CHECK:STDERR: var unused d: i65 = c;
|
||||
// CHECK:STDERR: ^~~
|
||||
// CHECK:STDERR:
|
||||
// CHECK:STDERR: fail_todo_cpp_compat_widen.carbon:[[@LINE+7]]:3: error: cannot implicitly convert expression of type `Core.CppCompat.LongLong64` to `i65` [ConversionFailure]
|
||||
// CHECK:STDERR: fail_todo_cpp_compat_widen.carbon:[[@LINE+7]]:3: error: cannot implicitly convert expression of type `Core.CppCompat.Long64` to `i65` [ConversionFailure]
|
||||
// CHECK:STDERR: var unused d: i65 = c;
|
||||
// CHECK:STDERR: ^~~~~~~~~~~~~~~~~
|
||||
// CHECK:STDERR: fail_todo_cpp_compat_widen.carbon:[[@LINE+4]]:3: note: type `Core.CppCompat.LongLong64` does not implement interface `Core.ImplicitAs(i65)` [MissingImplInMemberAccessInContext]
|
||||
// CHECK:STDERR: fail_todo_cpp_compat_widen.carbon:[[@LINE+4]]:3: note: type `Core.CppCompat.Long64` does not implement interface `Core.ImplicitAs(i65)` [MissingImplInMemberAccessInContext]
|
||||
// CHECK:STDERR: var unused d: i65 = c;
|
||||
// CHECK:STDERR: ^~~~~~~~~~~~~~~~~
|
||||
// CHECK:STDERR:
|
||||
var unused d: i65 = c;
|
||||
|
||||
var e: Core.CppCompat.ULong32 = 1;
|
||||
var e: Core.CppCompat.LongLong64 = 1;
|
||||
// CHECK:STDERR: fail_todo_cpp_compat_widen.carbon:[[@LINE+11]]:17: error: bit width of integer type literal must be a multiple of 8; use `Core.Int(65)` instead [IntWidthNotMultipleOf8]
|
||||
// CHECK:STDERR: var unused f: i65 = e;
|
||||
// CHECK:STDERR: ^~~
|
||||
// CHECK:STDERR:
|
||||
// CHECK:STDERR: fail_todo_cpp_compat_widen.carbon:[[@LINE+7]]:3: error: cannot implicitly convert expression of type `Core.CppCompat.LongLong64` to `i65` [ConversionFailure]
|
||||
// CHECK:STDERR: var unused f: i65 = e;
|
||||
// CHECK:STDERR: ^~~~~~~~~~~~~~~~~
|
||||
// CHECK:STDERR: fail_todo_cpp_compat_widen.carbon:[[@LINE+4]]:3: note: type `Core.CppCompat.LongLong64` does not implement interface `Core.ImplicitAs(i65)` [MissingImplInMemberAccessInContext]
|
||||
// CHECK:STDERR: var unused f: i65 = e;
|
||||
// CHECK:STDERR: ^~~~~~~~~~~~~~~~~
|
||||
// CHECK:STDERR:
|
||||
var unused f: i65 = e;
|
||||
|
||||
var g: Core.CppCompat.ULong32 = 1;
|
||||
// CHECK:STDERR: fail_todo_cpp_compat_widen.carbon:[[@LINE+11]]:17: error: bit width of integer type literal must be a multiple of 8; use `Core.UInt(33)` instead [IntWidthNotMultipleOf8]
|
||||
// CHECK:STDERR: var unused f: u33 = e;
|
||||
// CHECK:STDERR: var unused h: u33 = g;
|
||||
// CHECK:STDERR: ^~~
|
||||
// CHECK:STDERR:
|
||||
// CHECK:STDERR: fail_todo_cpp_compat_widen.carbon:[[@LINE+7]]:3: error: cannot implicitly convert expression of type `Core.CppCompat.ULong32` to `u33` [ConversionFailure]
|
||||
// CHECK:STDERR: var unused f: u33 = e;
|
||||
// CHECK:STDERR: var unused h: u33 = g;
|
||||
// CHECK:STDERR: ^~~~~~~~~~~~~~~~~
|
||||
// CHECK:STDERR: fail_todo_cpp_compat_widen.carbon:[[@LINE+4]]:3: note: type `Core.CppCompat.ULong32` does not implement interface `Core.ImplicitAs(u33)` [MissingImplInMemberAccessInContext]
|
||||
// CHECK:STDERR: var unused f: u33 = e;
|
||||
// CHECK:STDERR: var unused h: u33 = g;
|
||||
// CHECK:STDERR: ^~~~~~~~~~~~~~~~~
|
||||
// CHECK:STDERR:
|
||||
var unused f: u33 = e;
|
||||
var unused h: u33 = g;
|
||||
|
||||
var g: Core.CppCompat.ULongLong64 = 1;
|
||||
var i: Core.CppCompat.ULong64 = 1;
|
||||
// CHECK:STDERR: fail_todo_cpp_compat_widen.carbon:[[@LINE+11]]:17: error: bit width of integer type literal must be a multiple of 8; use `Core.UInt(65)` instead [IntWidthNotMultipleOf8]
|
||||
// CHECK:STDERR: var unused h: u65 = g;
|
||||
// CHECK:STDERR: var unused j: u65 = i;
|
||||
// CHECK:STDERR: ^~~
|
||||
// CHECK:STDERR:
|
||||
// CHECK:STDERR: fail_todo_cpp_compat_widen.carbon:[[@LINE+7]]:3: error: cannot implicitly convert expression of type `Core.CppCompat.ULong64` to `u65` [ConversionFailure]
|
||||
// CHECK:STDERR: var unused j: u65 = i;
|
||||
// CHECK:STDERR: ^~~~~~~~~~~~~~~~~
|
||||
// CHECK:STDERR: fail_todo_cpp_compat_widen.carbon:[[@LINE+4]]:3: note: type `Core.CppCompat.ULong64` does not implement interface `Core.ImplicitAs(u65)` [MissingImplInMemberAccessInContext]
|
||||
// CHECK:STDERR: var unused j: u65 = i;
|
||||
// CHECK:STDERR: ^~~~~~~~~~~~~~~~~
|
||||
// CHECK:STDERR:
|
||||
var unused j: u65 = i;
|
||||
|
||||
var k: Core.CppCompat.ULongLong64 = 1;
|
||||
// CHECK:STDERR: fail_todo_cpp_compat_widen.carbon:[[@LINE+11]]:17: error: bit width of integer type literal must be a multiple of 8; use `Core.UInt(65)` instead [IntWidthNotMultipleOf8]
|
||||
// CHECK:STDERR: var unused l: u65 = k;
|
||||
// CHECK:STDERR: ^~~
|
||||
// CHECK:STDERR:
|
||||
// CHECK:STDERR: fail_todo_cpp_compat_widen.carbon:[[@LINE+7]]:3: error: cannot implicitly convert expression of type `Core.CppCompat.ULongLong64` to `u65` [ConversionFailure]
|
||||
// CHECK:STDERR: var unused h: u65 = g;
|
||||
// CHECK:STDERR: var unused l: u65 = k;
|
||||
// CHECK:STDERR: ^~~~~~~~~~~~~~~~~
|
||||
// CHECK:STDERR: fail_todo_cpp_compat_widen.carbon:[[@LINE+4]]:3: note: type `Core.CppCompat.ULongLong64` does not implement interface `Core.ImplicitAs(u65)` [MissingImplInMemberAccessInContext]
|
||||
// CHECK:STDERR: var unused h: u65 = g;
|
||||
// CHECK:STDERR: var unused l: u65 = k;
|
||||
// CHECK:STDERR: ^~~~~~~~~~~~~~~~~
|
||||
// CHECK:STDERR:
|
||||
var unused h: u65 = g;
|
||||
var unused l: u65 = k;
|
||||
}
|
||||
|
||||
// --- fail_cpp_compat_narrow.carbon
|
||||
@@ -135,38 +178,60 @@ fn TestCppCompat() {
|
||||
// CHECK:STDERR:
|
||||
var unused b: i32 = a;
|
||||
|
||||
// i64 is slightly wider than Long64.
|
||||
var c: i64 = 1;
|
||||
// CHECK:STDERR: fail_cpp_compat_narrow.carbon:[[@LINE+7]]:3: error: cannot implicitly convert expression of type `i64` to `Core.CppCompat.Long64` [ConversionFailure]
|
||||
// CHECK:STDERR: var unused d: Core.CppCompat.Long64 = c;
|
||||
// CHECK:STDERR: ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
// CHECK:STDERR: fail_cpp_compat_narrow.carbon:[[@LINE+4]]:3: note: type `i64` does not implement interface `Core.ImplicitAs(Core.CppCompat.Long64)` [MissingImplInMemberAccessInContext]
|
||||
// CHECK:STDERR: var unused d: Core.CppCompat.Long64 = c;
|
||||
// CHECK:STDERR: ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
// CHECK:STDERR:
|
||||
var unused d: Core.CppCompat.Long64 = c;
|
||||
|
||||
// LongLong64 is slightly wider than i64.
|
||||
var c: Core.CppCompat.LongLong64 = 1;
|
||||
var e: Core.CppCompat.LongLong64 = 1;
|
||||
// CHECK:STDERR: fail_cpp_compat_narrow.carbon:[[@LINE+7]]:3: error: cannot implicitly convert expression of type `Core.CppCompat.LongLong64` to `i64` [ConversionFailure]
|
||||
// CHECK:STDERR: var unused d: i64 = c;
|
||||
// CHECK:STDERR: var unused f: i64 = e;
|
||||
// CHECK:STDERR: ^~~~~~~~~~~~~~~~~
|
||||
// CHECK:STDERR: fail_cpp_compat_narrow.carbon:[[@LINE+4]]:3: note: type `Core.CppCompat.LongLong64` does not implement interface `Core.ImplicitAs(i64)` [MissingImplInMemberAccessInContext]
|
||||
// CHECK:STDERR: var unused d: i64 = c;
|
||||
// CHECK:STDERR: var unused f: i64 = e;
|
||||
// CHECK:STDERR: ^~~~~~~~~~~~~~~~~
|
||||
// CHECK:STDERR:
|
||||
var unused d: i64 = c;
|
||||
var unused f: i64 = e;
|
||||
|
||||
// ULong32 is slightly wider than u32.
|
||||
var e: Core.CppCompat.ULong32 = 1;
|
||||
var g: Core.CppCompat.ULong32 = 1;
|
||||
// CHECK:STDERR: fail_cpp_compat_narrow.carbon:[[@LINE+7]]:3: error: cannot implicitly convert expression of type `Core.CppCompat.ULong32` to `u32` [ConversionFailure]
|
||||
// CHECK:STDERR: var unused f: u32 = e;
|
||||
// CHECK:STDERR: var unused h: u32 = g;
|
||||
// CHECK:STDERR: ^~~~~~~~~~~~~~~~~
|
||||
// CHECK:STDERR: fail_cpp_compat_narrow.carbon:[[@LINE+4]]:3: note: type `Core.CppCompat.ULong32` does not implement interface `Core.ImplicitAs(u32)` [MissingImplInMemberAccessInContext]
|
||||
// CHECK:STDERR: var unused f: u32 = e;
|
||||
// CHECK:STDERR: var unused h: u32 = g;
|
||||
// CHECK:STDERR: ^~~~~~~~~~~~~~~~~
|
||||
// CHECK:STDERR:
|
||||
var unused f: u32 = e;
|
||||
var unused h: u32 = g;
|
||||
|
||||
// u64 is slightly wider than ULong64.
|
||||
var i: u64 = 1;
|
||||
// CHECK:STDERR: fail_cpp_compat_narrow.carbon:[[@LINE+7]]:3: error: cannot implicitly convert expression of type `u64` to `Core.CppCompat.ULong64` [ConversionFailure]
|
||||
// CHECK:STDERR: var unused j: Core.CppCompat.ULong64 = i;
|
||||
// CHECK:STDERR: ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
// CHECK:STDERR: fail_cpp_compat_narrow.carbon:[[@LINE+4]]:3: note: type `u64` does not implement interface `Core.ImplicitAs(Core.CppCompat.ULong64)` [MissingImplInMemberAccessInContext]
|
||||
// CHECK:STDERR: var unused j: Core.CppCompat.ULong64 = i;
|
||||
// CHECK:STDERR: ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
// CHECK:STDERR:
|
||||
var unused j: Core.CppCompat.ULong64 = i;
|
||||
|
||||
// ULongLong64 is slightly wider than u64.
|
||||
var g: Core.CppCompat.ULongLong64 = 1;
|
||||
var k: Core.CppCompat.ULongLong64 = 1;
|
||||
// CHECK:STDERR: fail_cpp_compat_narrow.carbon:[[@LINE+7]]:3: error: cannot implicitly convert expression of type `Core.CppCompat.ULongLong64` to `u64` [ConversionFailure]
|
||||
// CHECK:STDERR: var unused h: u64 = g;
|
||||
// CHECK:STDERR: var unused l: u64 = k;
|
||||
// CHECK:STDERR: ^~~~~~~~~~~~~~~~~
|
||||
// CHECK:STDERR: fail_cpp_compat_narrow.carbon:[[@LINE+4]]:3: note: type `Core.CppCompat.ULongLong64` does not implement interface `Core.ImplicitAs(u64)` [MissingImplInMemberAccessInContext]
|
||||
// CHECK:STDERR: var unused h: u64 = g;
|
||||
// CHECK:STDERR: var unused l: u64 = k;
|
||||
// CHECK:STDERR: ^~~~~~~~~~~~~~~~~
|
||||
// CHECK:STDERR:
|
||||
var unused h: u64 = g;
|
||||
var unused l: u64 = k;
|
||||
}
|
||||
|
||||
// --- widen_sign_change.carbon
|
||||
|
||||
+41
-5
@@ -26,6 +26,18 @@ fn DoubleULong32(ul32: Core.CppCompat.ULong32) -> u32 {
|
||||
return 2 * (ul32 as u32);
|
||||
}
|
||||
|
||||
// TODO: Return `Core.CppCompat.Long64` when it's copyable.
|
||||
fn DoubleLong64(l64: Core.CppCompat.Long64) -> i64 {
|
||||
// TODO: Avoid explicit conversion when multiplication on `Long64` is available.
|
||||
return 2 * (l64 as i64);
|
||||
}
|
||||
|
||||
// TODO: Return `Core.CppCompat.ULong64` when it's copyable.
|
||||
fn DoubleULong64(ul64: Core.CppCompat.ULong64) -> u64 {
|
||||
// TODO: Avoid explicit conversion when multiplication on `ULong64` is available.
|
||||
return 2 * (ul64 as u64);
|
||||
}
|
||||
|
||||
// TODO: Return `Core.CppCompat.LongLong64` when it's copyable.
|
||||
fn DoubleLongLong64(ll64: Core.CppCompat.LongLong64) -> i64 {
|
||||
// TODO: Avoid explicit conversion when multiplication on `LongLong64` is available.
|
||||
@@ -33,9 +45,9 @@ fn DoubleLongLong64(ll64: Core.CppCompat.LongLong64) -> i64 {
|
||||
}
|
||||
|
||||
// TODO: Return `Core.CppCompat.ULongLong64` when it's copyable.
|
||||
fn DoubleULong64(ul64: Core.CppCompat.ULongLong64) -> u64 {
|
||||
fn DoubleULongLong64(ull64: Core.CppCompat.ULongLong64) -> u64 {
|
||||
// TODO: Avoid explicit conversion when multiplication on `ULongLong64` is available.
|
||||
return 2 * (ul64 as u64);
|
||||
return 2 * (ull64 as u64);
|
||||
}
|
||||
|
||||
// CHECK:STDOUT: ; ---
|
||||
@@ -57,9 +69,9 @@ fn DoubleULong64(ul64: Core.CppCompat.ULongLong64) -> u64 {
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define i64 @_CDoubleLongLong64.Main(i64 %ll64) #0 !dbg !20 {
|
||||
// CHECK:STDOUT: define i64 @_CDoubleLong64.Main(i64 %l64) #0 !dbg !20 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %T.as_type.as.MulWith.impl.Op.call = mul i64 2, %ll64, !dbg !26
|
||||
// CHECK:STDOUT: %T.as_type.as.MulWith.impl.Op.call = mul i64 2, %l64, !dbg !26
|
||||
// CHECK:STDOUT: ret i64 %T.as_type.as.MulWith.impl.Op.call, !dbg !27
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
@@ -70,6 +82,20 @@ fn DoubleULong64(ul64: Core.CppCompat.ULongLong64) -> u64 {
|
||||
// CHECK:STDOUT: ret i64 %T.as_type.as.MulWith.impl.Op.call, !dbg !35
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define i64 @_CDoubleLongLong64.Main(i64 %ll64) #0 !dbg !36 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %T.as_type.as.MulWith.impl.Op.call = mul i64 2, %ll64, !dbg !39
|
||||
// CHECK:STDOUT: ret i64 %T.as_type.as.MulWith.impl.Op.call, !dbg !40
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define i64 @_CDoubleULongLong64.Main(i64 %ull64) #0 !dbg !41 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %T.as_type.as.MulWith.impl.Op.call = mul i64 2, %ull64, !dbg !44
|
||||
// CHECK:STDOUT: ret i64 %T.as_type.as.MulWith.impl.Op.call, !dbg !45
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: attributes #0 = { nounwind }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: !llvm.dbg.cu = !{!0}
|
||||
@@ -95,7 +121,7 @@ fn DoubleULong64(ul64: Core.CppCompat.ULongLong64) -> u64 {
|
||||
// CHECK:STDOUT: !17 = !DILocalVariable(arg: 1, scope: !12, type: !15)
|
||||
// CHECK:STDOUT: !18 = !DILocation(line: 13, column: 10, scope: !12)
|
||||
// CHECK:STDOUT: !19 = !DILocation(line: 13, column: 3, scope: !12)
|
||||
// CHECK:STDOUT: !20 = distinct !DISubprogram(name: "DoubleLongLong64", linkageName: "_CDoubleLongLong64.Main", scope: null, file: !1, line: 17, type: !21, spFlags: DISPFlagDefinition, unit: !0, retainedNodes: !24)
|
||||
// CHECK:STDOUT: !20 = distinct !DISubprogram(name: "DoubleLong64", linkageName: "_CDoubleLong64.Main", scope: null, file: !1, line: 17, type: !21, spFlags: DISPFlagDefinition, unit: !0, retainedNodes: !24)
|
||||
// CHECK:STDOUT: !21 = !DISubroutineType(types: !22)
|
||||
// CHECK:STDOUT: !22 = !{!23, !23}
|
||||
// CHECK:STDOUT: !23 = !DIBasicType(name: "int", size: 64, encoding: DW_ATE_signed)
|
||||
@@ -111,4 +137,14 @@ fn DoubleULong64(ul64: Core.CppCompat.ULongLong64) -> u64 {
|
||||
// CHECK:STDOUT: !33 = !DILocalVariable(arg: 1, scope: !28, type: !31)
|
||||
// CHECK:STDOUT: !34 = !DILocation(line: 25, column: 10, scope: !28)
|
||||
// CHECK:STDOUT: !35 = !DILocation(line: 25, column: 3, scope: !28)
|
||||
// CHECK:STDOUT: !36 = distinct !DISubprogram(name: "DoubleLongLong64", linkageName: "_CDoubleLongLong64.Main", scope: null, file: !1, line: 29, type: !21, spFlags: DISPFlagDefinition, unit: !0, retainedNodes: !37)
|
||||
// CHECK:STDOUT: !37 = !{!38}
|
||||
// CHECK:STDOUT: !38 = !DILocalVariable(arg: 1, scope: !36, type: !23)
|
||||
// CHECK:STDOUT: !39 = !DILocation(line: 31, column: 10, scope: !36)
|
||||
// CHECK:STDOUT: !40 = !DILocation(line: 31, column: 3, scope: !36)
|
||||
// CHECK:STDOUT: !41 = distinct !DISubprogram(name: "DoubleULongLong64", linkageName: "_CDoubleULongLong64.Main", scope: null, file: !1, line: 35, type: !29, spFlags: DISPFlagDefinition, unit: !0, retainedNodes: !42)
|
||||
// CHECK:STDOUT: !42 = !{!43}
|
||||
// CHECK:STDOUT: !43 = !DILocalVariable(arg: 1, scope: !41, type: !31)
|
||||
// CHECK:STDOUT: !44 = !DILocation(line: 37, column: 10, scope: !41)
|
||||
// CHECK:STDOUT: !45 = !DILocation(line: 37, column: 3, scope: !41)
|
||||
// CHECK:STDOUT:
|
||||
|
||||
@@ -198,7 +198,9 @@ auto RecognizedTypeInfo::ForType(const File& file, ClassType class_type)
|
||||
if (parent_name_ident == "CppCompat") {
|
||||
Kind kind = llvm::StringSwitch<Kind>(*name_ident)
|
||||
.Case("Long32", CppLong32)
|
||||
.Case("Long64", CppLong64)
|
||||
.Case("ULong32", CppULong32)
|
||||
.Case("ULong64", CppULong64)
|
||||
.Case("LongLong64", CppLongLong64)
|
||||
.Case("ULongLong64", CppULongLong64)
|
||||
.Case("NullptrT", CppNullptrT)
|
||||
@@ -244,9 +246,15 @@ auto RecognizedTypeInfo::PrintLiteral(const File& file,
|
||||
case CppLong32:
|
||||
return PrintCppCompatLiteral(file, &clang::ASTContext::LongTy, 32, "long",
|
||||
out);
|
||||
case CppLong64:
|
||||
return PrintCppCompatLiteral(file, &clang::ASTContext::LongTy, 64, "long",
|
||||
out);
|
||||
case CppULong32:
|
||||
return PrintCppCompatLiteral(file, &clang::ASTContext::UnsignedLongTy, 32,
|
||||
"unsigned_long", out);
|
||||
case CppULong64:
|
||||
return PrintCppCompatLiteral(file, &clang::ASTContext::UnsignedLongTy, 64,
|
||||
"unsigned_long", out);
|
||||
case CppLongLong64:
|
||||
return PrintCppCompatLiteral(file, &clang::ASTContext::LongLongTy, 64,
|
||||
"long_long", out);
|
||||
|
||||
@@ -357,14 +357,20 @@ struct RecognizedTypeInfo {
|
||||
Char,
|
||||
// `Core.CppCompat.Long32` which is `Cpp.long` when `long` is 32 bits.
|
||||
CppLong32,
|
||||
// `Core.CppCompat.Long64` which is `Cpp.long` when `long` is 64 bits but
|
||||
// `int64_t` is `long long`.
|
||||
CppLong64,
|
||||
// `Core.CppCompat.ULong32` which is `Cpp.unsigned_long` when `unsigned
|
||||
// long` is 32 bits.
|
||||
CppULong32,
|
||||
// `Core.CppCompat.LongLong64` which is `Cpp.long_long` when `long` is 64
|
||||
// bits.
|
||||
// `Core.CppCompat.ULong64` which is `Cpp.unsigned_long` when `unsigned
|
||||
// long` is 64 bits but `uint64_t` is `unsigned long long`.
|
||||
CppULong64,
|
||||
// `Core.CppCompat.LongLong64` which is `Cpp.long_long` when `long` is
|
||||
// `int64_t`.
|
||||
CppLongLong64,
|
||||
// `Core.CppCompat.ULongLong64` which is `Cpp.unsigned_long_long` when
|
||||
// `unsigned long` is 64 bits.
|
||||
// `unsigned long` is `uint64_t`.
|
||||
CppULongLong64,
|
||||
// `Cpp.nullptr_t` / `Core.CppCompat.NullptrT`.
|
||||
CppNullptrT,
|
||||
|
||||
Reference in New Issue
Block a user