Stream: project-error-handling

Topic: embedded story


view this post on Zulip Antwan Gaggi (Sep 18 2020 at 18:09):

Hello! As someone who works on embedded and latency sensitive environments, being able to use the standard library is a breath of fresh air compared to C++, error handling alone was enough to convince many people at my team to consider rust.

Reading the announcement has me both excited yet very very skeptical, excited because I use rust at home as well for fun projects and it will make that part easier, skeptical because the current way is ideal (lowest common denominator, works well with embedded and high latency requirements)

One recurring theme I see in those points is best practices, those don't scale from a microcontroller to a web app to a server... etc. I am not sure what the goals of the working group are but if it is to adopt a single error handling story it will be going down the path of std and exceptions in C++

final note, thank you to all the people whose names were mentioned in the announcement for your work

view this post on Zulip Jake Goulding (Sep 18 2020 at 18:12):

@Antwan Gaggi I think something especially valuable you could do is to continue advocating for the embedded story.

I am biased, but I think that SNAFU does scale from microcontrollers to webservers (and I've used it as such!). The biggest missing piece for me is that Error is in libstd, not libcore. At least this is a well-known pain point that people have expressed interest in addressing.

view this post on Zulip Jake Goulding (Sep 18 2020 at 18:14):

But explaining how you see the differences in the different worlds and how those impact your design decisions is invaluable.

view this post on Zulip Lokathor (Sep 18 2020 at 19:04):

some sort of non-boxing solution is what's necessary for core

view this post on Zulip Jane Lusby (Sep 18 2020 at 19:07):

One recurring theme I see in those points is best practices, those don't scale from a microcontroller to a web app to a server... etc. I am not sure what the goals of the working group are but if it is to adopt a single error handling story it will be going down the path of std and exceptions in C++

When I drafted the charter I didn't really imagine a single error handling solution that everyone should adopt. I mean more of documenting all the different tools available and how to best leverage them. Some of this would be more specific to micro controllers and some would be more specific to web apps and so on.

view this post on Zulip Jake Goulding (Sep 18 2020 at 19:24):

some sort of non-boxing solution is what's necessary for core

Which is part of the reason that SNAFU doesn't require boxing :-)

view this post on Zulip Jane Lusby (Sep 18 2020 at 19:27):

more on the core boxing btw https://github.com/rust-lang/project-error-handling/issues/3


Last updated: Jan 26 2022 at 14:20 UTC