3 ms·
If you write code manually, you can forget to update it in the future. For instance, a manual implementation of PartialEq might become stale if you add new fiel
by bobbylarrybobby 1y ago
If you write code manually, you can forget to update it in the future. For instance, a manual implementation of PartialEq might become stale if you add new fields in the future. If you could automatically generate the implementation, and simply guide the macro to use non-default behavior (e.g. skip a field, or use a more complicated trait bound on a generic type) then you can have the advantages of generated code without the disadvantages. Seems worth trying for, IMO.