Files
swift-mirror/test/Interpreter/SDK/objc_block_generic.swift
Joe Groff c0a2994564 AST: Start printing function types with @convention instead of old attributes.
And update tests to match.

Swift SVN r27262
2015-04-13 22:51:34 +00:00

17 lines
363 B
Swift

// RUN: %target-run-simple-swift | FileCheck %s
// 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
println(gg!(219))
}