Files
swift-mirror/test/ModuleInterface/layout_pre_specialization.swift
Allan Shortlidge c6dad96492 Make LayoutPrespecialization a baseline feature instead of experimental.
Since LayoutPrespecialization has been enabled by default in all compiler
invocations for quite some time, it doesn't make sense for it to be treated as
experimental feature. Make it a baseline feature and remove all the
checks for it from the compiler.
2025-07-10 11:25:28 -07:00

14 lines
751 B
Swift

// RUN: %empty-directory(%t)
// RUN: %target-swift-emit-module-interface(%t/LayoutPrespec.swiftinterface) %s -module-name LayoutPrespec -disable-availability-checking
// RUN: %target-swift-typecheck-module-from-interface(%t/LayoutPrespec.swiftinterface) -module-name LayoutPrespec -disable-availability-checking
// RUN: %target-swift-typecheck-module-from-interface(%t/LayoutPrespec.swiftinterface) -module-name LayoutPrespec -disable-availability-checking
// RUN: %FileCheck %s < %t/LayoutPrespec.swiftinterface
// CHECK: @_specialize(exported: true, kind: full, where @_noMetadata A : _Class)
// CHECK-NEXT: public func test<A>(a: A) -> A
@_specialize(exported: true, where @_noMetadata A : _Class)
public func test<A>(a: A) -> A {
return a
}