sideeffect-io / AsyncExtensions

AsyncExtensions aims to mimic Swift Combine operators for async sequences.
MIT License
324 stars 26 forks source link

[BUG] AsyncCurrentValueStream `element` is not public #4

Closed Prince2k3 closed 2 years ago

Prince2k3 commented 2 years ago

Unable to use property element. It isn't public

To Reproduce Steps to reproduce the behavior:

  1. use AsyncStreams.CurrentValue
  2. attempt to print(currentValue.element)
  3. See build error
let currentValue = AsyncStreams.CurrentValue<Int>(1)

Task {
    for try await element in currentValue {
        print(element) 
    }
}

print(currentValue.element)  // error will occur

Expected behavior Expect that element is accessible

Environment:

twittemb commented 2 years ago

resolved by https://github.com/AsyncCommunity/AsyncExtensions/pull/5. Thanks.