// This source file is part of the Swift.org open source project
// Copyright (c) 2014 - 2016 Apple Inc. and the Swift project authors
// Licensed under Apache License v2.0 with Runtime Library Exception
//
// See http://swift.org/LICENSE.txt for license information
// See http://swift.org/CONTRIBUTORS.txt for the list of Swift project authors

// RUN: not --crash %target-swift-frontend %s -parse
// REQUIRES: asserts
protocol A{{}typealias e}extension A{{}typealias e:T

Add test case for crash triggered in swift::TypeChecker::computeDefaultAccessibility(swift::ExtensionDecl*)
[swiftc] Add test case for crash triggered in swift::TypeChecker::computeDefaultAccessibility(swift::ExtensionDecl*)

Stack trace:

```
swift: /path/to/swift/include/swift/AST/Decl.h:1716: void swift::ExtensionDecl::setDefaultAndMaxAccessibility(swift::Accessibility, swift::Accessibility): Assertion `!hasDefaultAccessibility() && "default accessibility already set"' failed.
9  swift           0x0000000000e4e9ee swift::TypeChecker::computeDefaultAccessibility(swift::ExtensionDecl*) + 830
10 swift           0x0000000000e4eec9 swift::TypeChecker::computeAccessibility(swift::ValueDecl*) + 633
11 swift           0x0000000000e4f20c swift::TypeChecker::validateAccessibility(swift::ValueDecl*) + 76
12 swift           0x0000000000e4c6d2 swift::TypeChecker::validateDecl(swift::ValueDecl*, bool) + 66
16 swift           0x0000000000e52296 swift::TypeChecker::typeCheckDecl(swift::Decl*, bool) + 150
17 swift           0x0000000000e75542 swift::performTypeChecking(swift::SourceFile&, swift::TopLevelContext&, swift::OptionSet<swift::TypeCheckingFlags, unsigned int>, unsigned int) + 994
18 swift           0x0000000000cc6e2f swift::CompilerInstance::performSema() + 3087
20 swift           0x000000000078d17c frontend_main(llvm::ArrayRef<char const*>, char const*, void*) + 2492
21 swift           0x0000000000787c45 main + 2837
Stack dump:
0.	Program arguments: /path/to/swift/bin/swift -frontend -c -primary-file validation-test/compiler_crashers/28276-swift-typechecker-computedefaultaccessibility.swift -target x86_64-unknown-linux-gnu -disable-objc-interop -module-name main -o /tmp/28276-swift-typechecker-computedefaultaccessibility-b0a9ad.o
1.	While type-checking 'A' at validation-test/compiler_crashers/28276-swift-typechecker-computedefaultaccessibility.swift:10:1
<unknown>:0: error: unable to execute command: Aborted
<unknown>:0: error: compile command failed due to signal (use -v to see invocation)
```
