"Fossies" - the Fresh Open Source Software Archive

Member "swift-swift-5.1.2-RELEASE/validation-test/compiler_crashers_fixed/00006-swift-mangle-mangler-manglecontext.swift" (7 Nov 2019, 604 Bytes) of package /linux/misc/swift-swift-5.1.2-RELEASE.tar.gz:


As a special service "Fossies" has tried to format the requested source page into HTML format using (guessed) Swift source code syntax highlighting (style: standard) with prefixed line numbers and code folding option. Alternatively you can here view or download the uninterpreted source code file.

    1 // This source file is part of the Swift.org open source project
    2 //
    3 // Copyright (c) 2014 - 2017 Apple Inc. and the Swift project authors
    4 // Licensed under Apache License v2.0 with Runtime Library Exception
    5 //
    6 // See https://swift.org/LICENSE.txt for license information
    7 // See https://swift.org/CONTRIBUTORS.txt for the list of Swift project authors
    8 
    9 // RUN: %target-swift-frontend %s -typecheck -verify
   10 
   11 // Issue found by https://github.com/AlexDenisov (Alexey Denisov)
   12 
   13 func i(c: () -> ()) {
   14 }
   15 class a {
   16     var _ = i() { // expected-error {{property declaration does not bind any variables}}
   17     }
   18 }