Skip to content

Commit 18950e9

Browse files
Reordered NSTDOptional variants.
1 parent 229e099 commit 18950e9

File tree

2 files changed

+7
-7
lines changed

2 files changed

+7
-7
lines changed

include/nstd/core/optional.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,10 @@
33

44
/// Describes an `NSTDOptional` variant.
55
typedef enum {
6-
/// "Some" initialized value.
7-
NSTD_OPTIONAL_STATUS_SOME,
86
/// No value.
9-
NSTD_OPTIONAL_STATUS_NONE
7+
NSTD_OPTIONAL_STATUS_NONE,
8+
/// "Some" initialized value.
9+
NSTD_OPTIONAL_STATUS_SOME
1010
} NSTDOptionalStatus;
1111

1212
/// Represents an optional (possibly uninitialized) value.

src/core/optional.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,17 +4,17 @@
44
#[repr(C)]
55
#[allow(non_camel_case_types)]
66
pub enum NSTDOptionalStatus {
7-
/// "Some" initialized value.
8-
NSTD_OPTIONAL_STATUS_SOME,
97
/// No value.
108
NSTD_OPTIONAL_STATUS_NONE,
9+
/// "Some" initialized value.
10+
NSTD_OPTIONAL_STATUS_SOME,
1111
}
1212

1313
/// Represents an optional (possibly uninitialized) value.
1414
#[repr(C)]
1515
pub enum NSTDOptional<T> {
16-
/// The initialized variant.
17-
Some(T),
1816
/// The uninitialized variant.
1917
None,
18+
/// The initialized variant.
19+
Some(T),
2020
}

0 commit comments

Comments
 (0)