@@ -1067,7 +1067,7 @@ public struct Errno: RawRepresentable, Error, Hashable, Codable {
10671067 public static var ENOSYS : Errno { noFunction }
10681068
10691069// BSD
1070- #if SYSTEM_PACKAGE_DARWIN
1070+ #if SYSTEM_PACKAGE_DARWIN || os(FreeBSD)
10711071 /// Inappropriate file type or format.
10721072 ///
10731073 /// The file was the wrong type for the operation,
@@ -1082,7 +1082,7 @@ public struct Errno: RawRepresentable, Error, Hashable, Codable {
10821082 public static var EFTYPE : Errno { badFileTypeOrFormat }
10831083#endif
10841084
1085- #if SYSTEM_PACKAGE_DARWIN
1085+ #if SYSTEM_PACKAGE_DARWIN || os(FreeBSD)
10861086 /// Authentication error.
10871087 ///
10881088 /// The authentication ticket used to mount an NFS file system was invalid.
@@ -1253,7 +1253,7 @@ public struct Errno: RawRepresentable, Error, Hashable, Codable {
12531253 @available ( * , unavailable, renamed: " illegalByteSequence " )
12541254 public static var EILSEQ : Errno { illegalByteSequence }
12551255
1256- #if SYSTEM_PACKAGE_DARWIN
1256+ #if SYSTEM_PACKAGE_DARWIN || os(FreeBSD)
12571257 /// Attribute not found.
12581258 ///
12591259 /// The specified extended attribute doesn't exist.
@@ -1294,7 +1294,7 @@ public struct Errno: RawRepresentable, Error, Hashable, Codable {
12941294 @available ( * , unavailable, renamed: " multiHop " )
12951295 public static var EMULTIHOP : Errno { multiHop }
12961296
1297- #if !os(WASI)
1297+ #if !os(WASI) && !os(FreeBSD)
12981298 /// No message available.
12991299 ///
13001300 /// No message was available to be received by the requested operation.
@@ -1320,7 +1320,7 @@ public struct Errno: RawRepresentable, Error, Hashable, Codable {
13201320 @available ( * , unavailable, renamed: " noLink " )
13211321 public static var ENOLINK : Errno { noLink }
13221322
1323- #if !os(WASI)
1323+ #if !os(WASI) && !os(FreeBSD)
13241324 /// Reserved.
13251325 ///
13261326 /// This error is reserved for future use.
@@ -1361,7 +1361,7 @@ public struct Errno: RawRepresentable, Error, Hashable, Codable {
13611361 @available ( * , unavailable, renamed: " protocolError " )
13621362 public static var EPROTO : Errno { protocolError }
13631363
1364- #if !os(OpenBSD) && !os(WASI)
1364+ #if !os(OpenBSD) && !os(WASI) && !os(FreeBSD)
13651365 /// Reserved.
13661366 ///
13671367 /// This error is reserved for future use.
@@ -1459,6 +1459,38 @@ extension Errno {
14591459 public static var EOWNERDEAD : Errno { previousOwnerDied }
14601460#endif
14611461
1462+ #if os(FreeBSD)
1463+ /// Capabilities insufficient.
1464+ ///
1465+ /// The corresponding C error is `ENOTCAPABLE`.
1466+ @_alwaysEmitIntoClient
1467+ public static var notCapable : Errno { . init( rawValue: _ENOTCAPABLE) }
1468+
1469+ @_alwaysEmitIntoClient
1470+ @available ( * , unavailable, renamed: " notCapable " )
1471+ public static var ENOTCAPABLE : Errno { notCapable }
1472+
1473+ /// Not permitted in capability mode.
1474+ ///
1475+ /// The corresponding C error is `ECAPMODE`.
1476+ @_alwaysEmitIntoClient
1477+ public static var capabilityMode : Errno { . init( rawValue: _ECAPMODE) }
1478+
1479+ @_alwaysEmitIntoClient
1480+ @available ( * , unavailable, renamed: " capabilityMode " )
1481+ public static var ECAPMODE : Errno { capabilityMode }
1482+
1483+ /// Integrity check failed.
1484+ ///
1485+ /// The corresponding C error is `EINTEGRITY`.
1486+ @_alwaysEmitIntoClient
1487+ public static var integrityCheckFailed : Errno { . init( rawValue: _EINTEGRITY) }
1488+
1489+ @_alwaysEmitIntoClient
1490+ @available ( * , unavailable, renamed: " integrityCheckFailed " )
1491+ public static var EINTEGRITY : Errno { integrityCheckFailed }
1492+ #endif
1493+
14621494#if SYSTEM_PACKAGE_DARWIN
14631495 /// Interface output queue is full.
14641496 ///
@@ -1469,7 +1501,9 @@ extension Errno {
14691501 @_alwaysEmitIntoClient
14701502 @available ( * , unavailable, renamed: " outputQueueFull " )
14711503 public static var EQFULL : Errno { outputQueueFull }
1504+ #endif
14721505
1506+ #if SYSTEM_PACKAGE_DARWIN || os(FreeBSD)
14731507 /// The largest valid error.
14741508 ///
14751509 /// This value is the largest valid value
0 commit comments