library: consistently use American spelling for 'behavior' · qinheping/verify-rust-std@295b932 (original) (raw)

`@@ -355,7 +355,7 @@ where

`

355

355

`}

`

356

356

``

357

357

`/// Creates a non-zero without checking whether the value is non-zero.

`

358

``

`-

/// This results in undefined behaviour if the value is zero.

`

``

358

`+

/// This results in undefined behavior if the value is zero.

`

359

359

`///

`

360

360

`/// # Safety

`

361

361

`///

`

`@@ -952,9 +952,9 @@ macro_rules! nonzero_integer {

`

952

952

``

953

953

`/// Multiplies two non-zero integers together,

`

954

954

`/// assuming overflow cannot occur.

`

955

``

`-

/// Overflow is unchecked, and it is undefined behaviour to overflow

`

``

955

`+

/// Overflow is unchecked, and it is undefined behavior to overflow

`

956

956

`/// even if the result would wrap to a non-zero value.

`

957

``

`-

/// The behaviour is undefined as soon as

`

``

957

`+

/// The behavior is undefined as soon as

`

958

958

` #[doc = sign_dependent_expr!{

`

959

959

` $signedness ?

`

960

960

`if signed {

`

`@@ -1323,9 +1323,9 @@ macro_rules! nonzero_integer_signedness_dependent_methods {

`

1323

1323

``

1324

1324

`/// Adds an unsigned integer to a non-zero value,

`

1325

1325

`/// assuming overflow cannot occur.

`

1326

``

`-

/// Overflow is unchecked, and it is undefined behaviour to overflow

`

``

1326

`+

/// Overflow is unchecked, and it is undefined behavior to overflow

`

1327

1327

`/// even if the result would wrap to a non-zero value.

`

1328

``

`-

/// The behaviour is undefined as soon as

`

``

1328

`+

/// The behavior is undefined as soon as

`

1329

1329

`` #[doc = concat!("self + rhs > ", stringify!($Int), "::MAX.")]

``

1330

1330

`///

`

1331

1331

`/// # Examples

`

`@@ -1599,7 +1599,7 @@ macro_rules! nonzero_integer_signedness_dependent_methods {

`

1599

1599

``

1600

1600

`/// Computes the absolute value of self.

`

1601

1601

`` #[doc = concat!("See [", stringify!($Int), "::abs]")]

``

1602

``

`-

/// for documentation on overflow behaviour.

`

``

1602

`+

/// for documentation on overflow behavior.

`

1603

1603

`///

`

1604

1604

`/// # Example

`

1605

1605

`///

`

`@@ -1878,7 +1878,7 @@ macro_rules! nonzero_integer_signedness_dependent_methods {

`

1878

1878

`/// Negates self, overflowing if this is equal to the minimum value.

`

1879

1879

`///

`

1880

1880

`` #[doc = concat!("See [", stringify!($Int), "::overflowing_neg]")]

``

1881

``

`-

/// for documentation on overflow behaviour.

`

``

1881

`+

/// for documentation on overflow behavior.

`

1882

1882

`///

`

1883

1883

`/// # Example

`

1884

1884

`///

`

`@@ -1943,7 +1943,7 @@ macro_rules! nonzero_integer_signedness_dependent_methods {

`

1943

1943

`/// of the type.

`

1944

1944

`///

`

1945

1945

`` #[doc = concat!("See [", stringify!($Int), "::wrapping_neg]")]

``

1946

``

`-

/// for documentation on overflow behaviour.

`

``

1946

`+

/// for documentation on overflow behavior.

`

1947

1947

`///

`

1948

1948

`/// # Example

`

1949

1949

`///

`