cplusplus / cplusplus/draft

[time.syn] <chrono> synopsis uses time_zone before declaring it

Open
#5,937 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
TeX
Stars
221
Forks
813
Avg merge
16h 4m
Merged PRs (30d)
36

Description

We have:

// 29.11.2.3, time zone database access
const tzdb& get_tzdb();
tzdb_list& get_tzdb_list();
const time_zone* locate_zone(string_view tz_name);
const time_zone* current_zone();

before:

// 29.11.5, class time_zone
enum class choose {earliest, latest};
class time_zone;

I know we don't always require the spec to be compilable without changes, but this seems unnecessarily invalid. We could just move the 29.11.5 decls before the 29.11.2.3 ones.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Compare the 29.11.2.3 time zone database access synopsis with the 29.11.5 class time_zone declarations shown in the issue. Move the enum class choose and class time_zone declarations before the functions that use time_zone, then verify the synopsis no longer refers to an undeclared type.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp
Domain
documentation
Issue type
Bug
Difficulty
1/5
Estimated time
Under an hour
Activity status
Stale
Clarity
Clearly specified
Newbie friendliness
55/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.