Let's say I'm calling an API with a bunch of optional parameters that looks like
EventSource::GetSource(const string& database, std::vector<uint32> stream_ids, const Time start, const Time end, const uint128 start_id = 0, const uint128 end_id = Uint128Max(), const bool offline_access = false, string_view identity = "", const uint64 read_timestamp = 0);
``` If the thing I'd like to call it with is the minimum number of required parameters (database, stream_ids, start, end) plus the very last optional parameter (read_timestamp), what's the idiomatic way to do this? Let's say refactoring the order of the API parameters isn't an option.
Obviously I could just pass in the defaults manually: ```cpp
GetSource(my_database, my_stream_ids, my_start, my_end, /*start_id=*/0, /*end_id=*/Uint128Max(), /*offline_access=*/false, /*identity=*/"", my_read_timestamp)
``` but this runs into the problem that if the API's defaults change, my function has to change too or be out of date (and besides, it's ugly). I know in Python I could just do ```py
GetSource(my_database, my_stream_ids, my_start, my_end, read_timestamp=my_read_timestamp
``` Is there an equivalent syntax or preferred pattern in C++?