docker / libchan

Like Go channels over the network
Apache License 2.0
2.47k stars 142 forks source link

Anonymous embedded structs aren't supported #77

Open stevvooe opened 9 years ago

stevvooe commented 9 years ago

It seems when using anonymous embedded structs, field values are not transmitted. For example, given the following types:

type B struct {
    I int
}

type A struct {
    B
    J int
}

If A is sent on a channel, values for the anonymously embedded B struct are not sent.

Shelnutt2 commented 8 years ago

Is this still an issue? I went to add a unit test to track this down and it appears to work.

https://github.com/Shelnutt2/libchan/commit/6a229ba8bb3b444d4e6b7c28b5c95958dbd645b1

dmcgowan commented 8 years ago

I do expect this to work as well with the latest encoding change. I would try to make this test work with the spdy package since that will hit the encoder. The in mem should not be a problem since it is only passing along a reference.