Skip to content

Commit 62016b2

Browse files
TaojunshenTylerMSFTColin Robertsonkylereedmsftweijiechai
authored
10/12/2021 AM Publish (#3830)
* add new classes: ambiguous_local_time & nonexistent_local_time * acrolinx * fix links * finish descriptions * fix more links * smoothing out * proofing * add some better linking * tune description * update descriptions * needed to update local-info-struct.md to reflect changes to descriptions for nonexistent and ambiguous * add chrono functions * rounding out duration links * Add documentation for IntelliSense linter for C++ (MicrosoftDocs#3821) * Add first draft of linter check documentation * WIP overview. Signed-off-by: Kyle Reed <kylereed@microsoft.com> * Update toc. First draft of the linter overview. * Add screenshots, move files, code samples are stand-alone. Signed-off-by: Kyle Reed <kylereed@microsoft.com> * Style and Acrolinx grammar checker pass * Add missing Options cues for checks * Update to use latest option names Co-authored-by: 3836425+corob-msft@users.noreply.github.com <corob@microsoft.com> * connecting duration up to it's non-member pieces and doing some general updates * fix links * cleanup * Split out VS2019 content for linter (#3824) * Update working-with-project-properties.md * cleanup * cleanup * cleanup * cleanup * cleanup * cleanup * cleanup * fix function signature * fix line ending * remove duplicate Co-authored-by: TylerMSFT <Tyler.Whitney@microsoft.com> Co-authored-by: Colin Robertson <corob@microsoft.com> Co-authored-by: Kyle Reed <kylereed@microsoft.com> Co-authored-by: Chai Wei Jie <chai_weijie@hotmail.com> Co-authored-by: PRMerger19 <prmrgr19@microsoft.com> Co-authored-by: Laura Brenner <90344170+laurabren@users.noreply.github.com> Co-authored-by: Courtney Wales <62625502+Court72@users.noreply.github.com> Co-authored-by: Andrea Courtright <74212614+v-andreaco@users.noreply.github.com> Co-authored-by: PRMerger15 <prmrgr15@microsoft.com>
1 parent be63209 commit 62016b2

File tree

2 files changed

+16
-15
lines changed

2 files changed

+16
-15
lines changed

docs/c-runtime-library/reference/get-dstbias.md

Lines changed: 13 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -8,49 +8,48 @@ api_type: ["DLLExport"]
88
topic_type: ["apiref"]
99
f1_keywords: ["__dstbias", "_get_dstbias", "get_dstbias"]
1010
helpviewer_keywords: ["__dstbias", "daylight saving time offset", "get_dstbias function", "_get_dstbias function"]
11-
ms.assetid: e751358c-1ecc-411b-ae2c-81b2ec54ea45
1211
---
13-
# _get_dstbias
12+
# `_get_dstbias`
1413

1514
Retrieves the daylight saving time offset in seconds.
1615

1716
## Syntax
1817

1918
```C
20-
error_t _get_dstbias( int* seconds );
19+
error_t _get_dstbias( long* seconds );
2120
```
2221
2322
### Parameters
2423
25-
*seconds*<br/>
24+
*`seconds`*\
2625
The offset in seconds of daylight saving time.
2726
2827
## Return Value
2928
30-
Zero if successful or an **errno** value if an error occurs.
29+
Zero if successful or an **`errno`** value if an error occurs.
3130
3231
## Remarks
3332
34-
The **_get_dstbias** function retrieves the number of seconds in daylight saving time as an integer. If daylight saving time is in effect, the default offset is 3600 seconds, which is the number of seconds in one hour (though a few regions do observe a two-hour offset).
33+
The **`_get_dstbias`** function retrieves the number of seconds in daylight saving time as an integer. If daylight saving time is in effect, the default offset is 3600 seconds, which is the number of seconds in one hour (though a few regions do observe a two-hour offset).
3534
36-
If *seconds* is **NULL**, the invalid parameter handler is invoked as described in [Parameter Validation](../../c-runtime-library/parameter-validation.md). If execution is allowed to continue, this function sets **errno** to **EINVAL** and returns **EINVAL**.
35+
If *`seconds`* is **`NULL`**, the invalid parameter handler is invoked as described in [Parameter Validation](../../c-runtime-library/parameter-validation.md). If execution is allowed to continue, this function sets **`errno`** to **`EINVAL`** and returns **`EINVAL`**.
3736
38-
We recommend you use this function instead of the macro **_dstbias** or the deprecated function **__dstbias**.
37+
We recommend you use this function instead of the macro **`_dstbias`** or the deprecated function **`__dstbias`**.
3938
4039
By default, this function's global state is scoped to the application. To change this, see [Global state in the CRT](../global-state.md).
4140
4241
## Requirements
4342
4443
|Routine|Required header|
4544
|-------------|---------------------|
46-
|**_get_dstbias**|\<time.h>|
45+
|**`_get_dstbias`**|`<time.h>`|
4746
4847
For more information, see [Compatibility](../../c-runtime-library/compatibility.md).
4948
5049
## See also
5150
52-
[Time Management](../../c-runtime-library/time-management.md)<br/>
53-
[errno, _doserrno, _sys_errlist, and _sys_nerr](../../c-runtime-library/errno-doserrno-sys-errlist-and-sys-nerr.md)<br/>
54-
[_get_daylight](get-daylight.md)<br/>
55-
[_get_timezone](get-timezone.md)<br/>
56-
[_get_tzname](get-tzname.md)<br/>
51+
[Time Management](../../c-runtime-library/time-management.md)\
52+
[`errno`, `_doserrno`, `_sys_errlist`, and `_sys_nerr`](../../c-runtime-library/errno-doserrno-sys-errlist-and-sys-nerr.md)\
53+
[`_get_daylight`](get-daylight.md)\
54+
[`_get_timezone`](get-timezone.md)\
55+
[`_get_tzname`](get-tzname.md)

docs/standard-library/choose-enum.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,9 @@ If a `local_time` specifies a time during this "extra" hour, it isn't clear how
3838
3939
**Nonexistent conversion error**
4040
41-
When converting from standard time to daylight saving time, a different problem can arise. In that case, a different problem can arise. During the transition from standard time to daylight saving time in the spring, clocks essentially lose an hour. This can be confusing because doesn't the transition to daylight saving time mean adding an hour?
41+
42+
When converting from standard time to daylight saving time, a different problem can arise. During the transition from standard time to daylight saving time in the spring, clocks essentially lose an hour. This can be confusing because doesn't the transition to daylight saving time mean adding an hour?
43+
4244
4345
By "springing forward" an hour, the hour following the transition is effectively removed. Consider the change to daylight saving time in New York, which happens on the second Sunday in March at 2am. At 2am, the clock transitions to daylight savings time and now reads 3:00am. If the `local_time` being converted is 2:30am, for example, that time is during the period that was "removed" and so is "nonexistent", resulting in a [`nonexistent_local_time`](nonexistent-local-time.md#example-nonexistent_local_time) exception.
4446

0 commit comments

Comments
 (0)