|
Should we create a general "systems errors" SRFI?
hga@xxxxxx
(19 Sep 2019 13:27 UTC)
|
|
Re: Should we create a general "systems errors" SRFI?
Lassi Kortela
(19 Sep 2019 13:34 UTC)
|
|
Re: Should we create a general "systems errors" SRFI?
John Cowan
(19 Sep 2019 20:26 UTC)
|
|
Re: Should we create a general "systems errors" SRFI?
Lassi Kortela
(19 Sep 2019 20:54 UTC)
|
|
Re: Should we create a general "systems errors" SRFI?
John Cowan
(19 Sep 2019 21:04 UTC)
|
|
Re: Should we create a general "systems errors" SRFI?
Lassi Kortela
(19 Sep 2019 21:21 UTC)
|
|
Re: Should we create a general "systems errors" SRFI?
hga@xxxxxx
(19 Sep 2019 21:23 UTC)
|
|
Re: Should we create a general "systems errors" SRFI?
Lassi Kortela
(19 Sep 2019 21:32 UTC)
|
|
Re: Should we create a general "systems errors" SRFI?
hga@xxxxxx
(19 Sep 2019 22:12 UTC)
|
|
Re: Should we create a general "systems errors" SRFI? Lassi Kortela (20 Sep 2019 10:37 UTC)
|
|
Re: Should we create a general "systems errors" SRFI?
John Cowan
(20 Sep 2019 11:27 UTC)
|
> For now, why don't we both put it on our task list, and if one of us
> feels like making the first draft, email the other to old-fashioned
> "check out" that task.
Sounds good.
> First, though, we should start publicly collecting desiderata. Offhand:
>
> As previously mentioned, it should be a union of "system errors", which
> I define to be stuff in the stack that the Scheme system sits on or uses
> (this *might* include a Boehm GC library), and errors library writers
> need to signal when using system code. I.e. making a simple test and
> raising an error instead of handing it to an FFI which will segfault.
I still think "system" is quite vague, and if we go that far we might as
well go the whole way and make it a generic errors-with-metadata SRFI.
> (Optional) indication of where the error happened!!! Not just what
> procedure, but allow for a Scheme to insert a file name and line number,
> or the user to say "That port you think you gave me? It isn't a
> port....", that is, a string that can be searched on. A scheme like
> the one below could also provide the same thing if not for the cut
> and paste disease:
This is nice. It's starting to look more like a generic error SRFI,
giving the ability to tack arbitrary metadata onto errors (some of it
standardized), than an OS-error-only SRFI.
> As previously discussed, we can use a short abbreviation to make the
> source of error codes more obviously, like Oracle's "ORA-".
Since Scheme has rich hierarchical data structures we could have
pre-parsed codes such as ("ORA" . "WHATEVER") or ("ORA" . "WHATEVER").
Of course, in the specific case of Oracle if the standard convention is
to call them "ORA-1234" then we should probably follow that.