Skip to content

Reasons for 'DependencyClient' macro not working #3480

Closed Answered by mbrandonw
iharandreyev asked this question in Q&A
Discussion options

You must be logged in to vote

Thanks for that. The issue is the let. If you change it to a var it should work.

Currently lets are omitted from the initializer because they are given a default value (one that throws the Unimplemented error), and so Swift would not be able to set that variable again. We do have some changes planned for the macro that would make this possible, but it's just not how it is today.

Replies: 1 comment 4 replies

Comment options

You must be logged in to vote
4 replies
@iharandreyev
Comment options

@mbrandonw
Comment options

@iharandreyev
Comment options

@mbrandonw
Comment options

Answer selected by iharandreyev
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants