[SR-11477] Property Wrapper with initializer with default arguments can be used without parenthesis #53877
Labels
bug
A deviation from expected or documented behavior. Also: expected but undesirable behavior.
compiler
The Swift compiler in itself
property wrappers
Feature: property wrappers
Environment
Tested on:
Apple Swift version 5.1 (swiftlang-1100.0.270.13 clang-1100.0.33.7)
Target: x86_64-apple-darwin18.7.0
Additional Detail from JIRA
md5: bcbfc6c2401f99dce119ce97768cb959
Issue Description:
Let's take a simple useless property wrapper with two initializers: one without argument (implemented with a default value) and one with the argument
All three way to use the property wrapper is accepted by the compiler.
Now if we implement the same property wrapper but with one initializer using default parameter :
We have a compilation error. The property wrapper without parenthesis doesn't match the initializer with default parameter.
Expected result :
Initializer with default parameter should match when using property wrapper without parenthesis.
The text was updated successfully, but these errors were encountered: