我如何处理 RxBluetoothKit 中的 "Ambiguous reference to member '=='"?

How do I deal with "Ambiguous reference to member '=='" in RxBluetoothKit?

尝试使用 RxBluetoothKit 扫描 Bluetooth peripherals 我得到一个名为

error

"Ambiguous reference to member '==' using this code:

func observeState() -> Observable<[BluetoothState]> {
    return manager.observeState()
           .startWith(manager.state)
           .do(onNext: { print("CHECK POWER", [=11=]) })
           .filter{ [=11=] == .poweredOn }
           .take(1)
           .do(onNext:{
               print("POWERED ON", [=11=])
           })
           .flatMap { _ in
               self.manager
                   .scanForPeripherals(withServices: nil)
                   .map { BlePeripheral(peripheral: [=11=].peripheral) }
                   .do(onNext: {
                       print([=11=].peripheral.name)
                       print([=11=].peripheral.identifier)
                       print([=11=].peripheral.connected)
                    })
           }
    }

错误在.filter{ [=16=] == .poweredOn }

如果我从 flatMap 及以后删除所有内容,错误就会消失,但显然我需要在某个时候拥有该部分。不确定我是否理解 error。我查看了 question/answers 上的相同错误,但我仍然不确定它如何适用于我的情况或 compiler 要我做什么。感谢任何有关如何解决此问题的指示。

问题是类型不匹配。 return函数类型是Observable<[BluetoothState]>,但是flatMap里面return类型是Observable<BlePeripheral >