fzyzcjy / flutter_rust_bridge

Flutter/Dart <-> Rust binding generator, feature-rich, but seamless and simple.
https://fzyzcjy.github.io/flutter_rust_bridge/
MIT License
4.09k stars 278 forks source link

Normal type can't be used in StreamSink #716

Closed TENX-S closed 1 year ago

TENX-S commented 1 year ago

flutter_rust_bridge: 1.45.0

image

Message:

#[derive(Debug)]
pub enum MessageKind {
    Error,
    Info,
}

#[derive(Debug)]
pub struct Message {
    pub kind: Box<MessageKind>,
    pub body: String,
}

exposed api signature:

pub fn listen(stream: StreamSink<Message>) -> anyhow::Result<()> 
fzyzcjy commented 1 year ago

?

TENX-S commented 1 year ago

I forget to run codegen, sry

github-actions[bot] commented 1 year ago

This thread has been automatically locked since there has not been any recent activity after it was closed. If you are still experiencing a similar issue, please open a new issue.