| 23 Jan 2024 |
John Ericson | otherwise I'll just merge | 17:22:27 |
John Ericson | (no code is changed, only a struct) | 17:22:36 |
@delroth:delroth.net | John Ericson: https://github.com/NixOS/hydra/pull/1341/files#diff-0e7b6b6b57906dff7078309c6bef4ad2b354478ad474fa7d102591652c1dd4afR155 somehow after like 15 years of doing C++ professionally I seemingly still don't understand it - how does that even work? | 17:44:18 |
@delroth:delroth.net | specifically: how can a ::Machine get built from a nix::Machine there | 17:44:53 |
John Ericson | delroth: The ::machine has no fields which have to be set construction time, it just needs the new super class to be construct=ed | 17:45:45 |
@delroth:delroth.net | sure, but there isn't a ::Machine constructor from nix::Machine here, as far as I can tell - is that implicitly defined? | 17:47:48 |
John Ericson | delroth: yes that is implicitly defined | 17:49:23 |
John Ericson | merely because ::Machine has no explicit constructor, and it has the public base class | 17:49:44 |
John Ericson | I would probably get rid of the inheritence eventually because inheritance is ugly :) | 17:50:11 |
John Ericson | but that would be more churn because field names, so I am saving that for after the Nix-side code is cleaned up and matching Hydra | 17:50:35 |
@delroth:delroth.net | In reply to @Ericson2314:matrix.org delroth: yes that is implicitly defined after some digging the answer I was looking for was https://www.open-std.org/jtc1/sc22/wg21/docs/papers/2015/p0017r1.html from C++17 :p | 18:05:50 |
@delroth:delroth.net | TIL | 18:05:59 |
@delroth:delroth.net | I think this might be the first time I actually encounter this, somehow | 18:06:25 |
John Ericson | delroth: ah OK | 18:07:14 |
John Ericson | I never did C++ pre C++17 and Nix :) | 18:07:26 |