While reviewing #1789, Casey Carter (@CaseyCarter) noticed several things in <chrono> that could be cleaned up. None of them are correctness issues or have ABI impact, so we're filing a followup issue.
Also while reviewing #1870, Miya Natsuhara (@mnatsuhara) identified several good cleanups. Casey Carter (@CaseyCarter) also found some things to clean up with comments in #1870 (review).
One more issue (noticed while explaining a decltype) - the occurrences of decltype(tzdb::zones) and decltype(tzdb::links) are relics of an earlier attempt to use special allocators (which was foiled by the Standard's insistence on std::allocator here). It would probably be simpler to replace these with their actual types. Example occurrences:
|
_NODISCARD inline tuple<string, decltype(tzdb::zones), decltype(tzdb::links)> _Tzdb_generate_time_zones() {
|
|
decltype(tzdb::zones) _Time_zones;
|
|
decltype(tzdb::links) _Time_zone_links;
|
While reviewing #1789, Casey Carter (@CaseyCarter) noticed several things in
<chrono>that could be cleaned up. None of them are correctness issues or have ABI impact, so we're filing a followup issue.Also while reviewing #1870, Miya Natsuhara (@mnatsuhara) identified several good cleanups. Casey Carter (@CaseyCarter) also found some things to clean up with comments in #1870 (review).
One more issue (noticed while explaining a
decltype) - the occurrences ofdecltype(tzdb::zones)anddecltype(tzdb::links)are relics of an earlier attempt to use special allocators (which was foiled by the Standard's insistence onstd::allocatorhere). It would probably be simpler to replace these with their actual types. Example occurrences:STL/stl/inc/chrono
Line 2607 in dde4623
STL/stl/inc/chrono
Lines 2618 to 2619 in dde4623