Files
swift-mirror/test/Interpreter/SDK/objc_block_generic.swift
Arnold Schwaighofer 859fbc0162 More executable_test for the test directory
Swift SVN r29280
2015-06-03 23:28:51 +00:00

18 lines
390 B
Swift

// RUN: %target-run-simple-swift | FileCheck %s
// REQUIRES: executable_test
// REQUIRES: objc_interop
import Foundation
autoreleasepool {
let f: @convention(block) Int -> Int = { $0 }
// In an -Onone build this instantiates the generic metadata for
// @convention(block) Int -> Int
let ff: (@convention(block) Int -> Int)? = f
let gg = ff
// CHECK: 219
print(gg!(219))
}