Resolve both occurrences of an ambiguous wall time
One wall time can occur twice during a fall-back transition and disappear entirely during a forward jump. Expose the number of valid UTC candidates. After the offset moves back, local tick 11000 has two UTC candidates. Fold 1 selects the later occurrence.
Run the framework with your own input
Install Blyx 0.2.1 and a Rust toolchain with a host linker, then run the versioned project. Each positional argument is a number or a comma-separated numerical vector. The CLI accepts up to 16 entries per vector. The imported module accepts longer inputs.
git clone --depth 1 --branch v0.1.0 https://github.com/Rahulchaube1/blyx-blackbird.git
cd blyx-blackbird
blyxc native-run project.blyx -- 11000 10000 3600 0 1API and return values
Returns [candidate count, selected UTC, selected offset]. For a gap the latter two values are zero. Fold 0 chooses the earlier occurrence and fold 1 the later. Supply transition data from a trusted timezone database. Invalid input returns an empty vector.
| Argument | Accepted input |
|---|---|
| local | exact signed integer |
| transition | exact signed integer |
| before | exact signed integer |
| after | exact signed integer |
| fold | nonnegative exact integer |
Use the libraries independently
The framework vendors the same library source published in these two repositories. Each module has its own package page, input contract and regression suite.
Try the program
Expected output
2 11000 0
Practice
Change fold = 0.0. Predict the result, then run the program.
Hint
Returns [candidate count, selected UTC, selected offset]. For a gap the latter two values are zero. Fold 0 chooses the earlier occurrence and fold 1 the later. Supply transition data from a trusted timezone database.
Worked solution
The result vector is [2, 7400, 3600]. Compare its fields with the return layout in the API section.
Find
let fold = 1.0;Replace with
let fold = 0.0;Output after the change
2 7400 3600
