| 40 | }; |
| 41 | |
| 42 | int main() { |
| 43 | auto id = e1; |
| 44 | |
| 45 | /*<<create interface with `id = e1`>>*/ |
| 46 | auto injector = di::make_injector(dynamic_bindings(id)); |
| 47 | assert(dynamic_cast<implementation1*>(injector.create<std::shared_ptr<interface>>().get())); |
| 48 | |
| 49 | id = e2; |
| 50 | /*<<create interface with `id = e2`>>*/ |
| 51 | assert(dynamic_cast<implementation2*>(injector.create<std::shared_ptr<interface>>().get())); |
| 52 | (void)id; |
| 53 | } |
nothing calls this directly
no test coverage detected