You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Protocols are currently a bit misused in the code design... we are using them with a new() function to convert data on callsite.
We should consider Protocol as providing the capability to be "used as a different type of data, regardless the original data structure".
For instance having one function per key of the map we want to emulate.
The struct being one specific, optimized version of this protocol...
This applies specifically for the code in the :xest library where we want to have a "common data format" for our purpose.
It seems it would make the conversion rules clearer, and would mean that we do the conversion only as needed, even if it might be a bit more cumbersome to write the first time...
The text was updated successfully, but these errors were encountered:
Protocols are currently a bit misused in the code design... we are using them with a new() function to convert data on callsite.
We should consider Protocol as providing the capability to be "used as a different type of data, regardless the original data structure".
For instance having one function per key of the map we want to emulate.
The struct being one specific, optimized version of this protocol...
This applies specifically for the code in the
:xest
library where we want to have a "common data format" for our purpose.It seems it would make the conversion rules clearer, and would mean that we do the conversion only as needed, even if it might be a bit more cumbersome to write the first time...
The text was updated successfully, but these errors were encountered: