Files
swift-mirror/validation-test/Serialization/AllowErrors/invalid-attr.swift
Ben Barham 073a5828a2 [Serialization] Skip verifying attributes when allowing errors
When allowing errors any attribute could be on any decl, so don't verify
whether an attribute can appear on a decl. Note that these attributes
aren't serialized anyway since they'll be set to invalid during
typechecking and hence skipped.
2021-06-02 11:44:53 +10:00

10 lines
311 B
Swift

// RUN: %empty-directory(%t)
// RUN: %target-swift-frontend -module-name errors -emit-module -o %t/errors.swiftmodule -experimental-allow-module-with-compiler-errors %s
// @discardableResult is not allowed on a struct, make sure we don't crash
// when allowing errors
@discardableResult
struct SomeStruct {}