ninjasource / embedded-websocket

A rust websocket library for embedded systems (no_std)
Apache License 2.0
98 stars 28 forks source link

A few more tweaks #3

Closed benbrittain closed 4 years ago

benbrittain commented 4 years ago

removed </p>, also added some ZSTs to prevent the need to panic

ninjasource commented 4 years ago

Thanks for this! I'll be able to take a look later today.

benbrittain commented 4 years ago

It mildly complicates the type signatures, totally understandable if not merged. I'm just a big fan of avoiding panics where possible.

I was also thinking about how much of this could be made less manual with the right trait. Haven't thought about it too much though because I got distracted by a different project :P

ninjasource commented 4 years ago

Thank you so much for this PR. I think that getting rid of the need to panic using PhantomData is really neat. I'm going to merge it and and make the changes I mentioned above.