Hi dev list,
Could there be a way to give abstractions the ability to raise pd_error() and highlight the abstraction instance with find last error? The reason for it would be that externals often distribute with a mix of binaries and abstractions, and it would be cool to have the user get an error pointer to the abstraction instance rather than the inside of an abstraction, e.g. when they send an unexpected data type.
Matt
Am 6. Februar 2023 21:24:54 MEZ schrieb Matt Barber brbrofsvl@gmail.com:
Hi dev list,
Could there be a way to give abstractions the ability to raise pd_error() and highlight the abstraction instance with find last error? The reason for it would be that externals often distribute with a mix of binaries and abstractions, and it would be cool to have the user get an error pointer to the abstraction instance rather than the inside of an abstraction, e.g. when they send an unexpected data type.
I think my "log" library (available on denken, except for Darwin/arm iirc) provides something like this.
Matt
mfg.sfg.jfd IOhannes
That would be great a feature! I think many of us have thought about that, but nobody has made a PR yet.
I think the easiest solution would be to add more options to [print]. I particularly like the idea that [print] could (optionally) set the containing abstraction as the error source.
You could make a feature request on GitHub. There is a somewhat related issue (https://github.com/pure-data/pure-data/issues/1174), but that one is not very specific.
Christof
On 06.02.2023 21:24, Matt Barber wrote:
Hi dev list,
Could there be a way to give abstractions the ability to raise pd_error() and highlight the abstraction instance with find last error? The reason for it would be that externals often distribute with a mix of binaries and abstractions, and it would be cool to have the user get an error pointer to the abstraction instance rather than the inside of an abstraction, e.g. when they send an unexpected data type.
Matt
Pd-dev mailing list Pd-dev@lists.iem.at https://lists.puredata.info/listinfo/pd-dev