Files
swift-mirror/test/Interop/Cxx/templates/class-template-with-simd-parameter-module-interface.swift
Egor Zhdan d19c9eb32b [cxx-interop] Disambiguate template instantiations with SIMD parameters
When converting a C++ class template instantiation name into Swift, we previously didn't account for possible SIMD types. Those types were printed as `_`. This meant that e.g. `std::vector<simd::float3>` and `std::vector<simd::float4>` would get the same Swift name, causing compiler errors down the road.

rdar://134214091
2024-09-04 16:46:23 +01:00

10 lines
560 B
Swift

// RUN: %target-swift-ide-test -print-module -module-to-print=ClassTemplateWithSIMDParameter -I %S/Inputs -source-filename=x -cxx-interoperability-mode=upcoming-swift | %FileCheck %s
// REQUIRES: OS=macosx || OS=ios
// CHECK: typealias TemplatedSIMDUInt1 = Templated<CUnsignedInt>
// CHECK: typealias TemplatedSIMDUInt16 = Templated<SIMD16<CUnsignedInt>>
// CHECK: typealias TemplatedSIMDFloat3 = Templated<SIMD3<CFloat>>
// CHECK: typealias TemplatedSIMDFloat4 = Templated<SIMD4<CFloat>>
// CHECK: typealias TemplatedSIMDDouble8 = Templated<SIMD8<CDouble>>