From e264c32068893a4e9c9e4ba102bc8fc8843a964f Mon Sep 17 00:00:00 2001 From: "Shane F. Carr" Date: Mon, 16 Dec 2024 18:56:46 -0800 Subject: [PATCH] oops --- ffi/capi/bindings/c/DateFormatter.h | 2 +- ffi/capi/bindings/c/DateTimeFormatter.h | 2 +- ffi/capi/bindings/cpp/icu4x/DateFormatter.d.hpp | 2 +- ffi/capi/bindings/cpp/icu4x/DateFormatter.hpp | 6 +++--- ffi/capi/bindings/cpp/icu4x/DateTimeFormatter.d.hpp | 2 +- ffi/capi/bindings/cpp/icu4x/DateTimeFormatter.hpp | 6 +++--- ffi/capi/bindings/dart/DateFormatter.g.dart | 10 +++++----- ffi/capi/bindings/dart/DateTimeFormatter.g.dart | 10 +++++----- ffi/capi/bindings/js/DateFormatter.d.ts | 2 +- ffi/capi/bindings/js/DateFormatter.mjs | 4 ++-- ffi/capi/bindings/js/DateTimeFormatter.d.ts | 2 +- ffi/capi/bindings/js/DateTimeFormatter.mjs | 4 ++-- ffi/capi/src/datetime_formatter.rs | 8 ++++---- 13 files changed, 30 insertions(+), 30 deletions(-) diff --git a/ffi/capi/bindings/c/DateFormatter.h b/ffi/capi/bindings/c/DateFormatter.h index adb740d0c11..3b5532aceb3 100644 --- a/ffi/capi/bindings/c/DateFormatter.h +++ b/ffi/capi/bindings/c/DateFormatter.h @@ -43,7 +43,7 @@ icu4x_DateFormatter_format_datetime_mv1_result icu4x_DateFormatter_format_dateti typedef struct icu4x_DateFormatter_format_iso_datetime_mv1_result {union { DateTimeFormatError err;}; bool is_ok;} icu4x_DateFormatter_format_iso_datetime_mv1_result; icu4x_DateFormatter_format_iso_datetime_mv1_result icu4x_DateFormatter_format_iso_datetime_mv1(const DateFormatter* self, const IsoDateTime* value, DiplomatWrite* write); -AnyCalendarKind icu4x_DateFormatter_calendar_bcp47_mv1(const DateFormatter* self); +AnyCalendarKind icu4x_DateFormatter_calendar_kind_mv1(const DateFormatter* self); void icu4x_DateFormatter_destroy_mv1(DateFormatter* self); diff --git a/ffi/capi/bindings/c/DateTimeFormatter.h b/ffi/capi/bindings/c/DateTimeFormatter.h index 7c5d6792094..306caee11ca 100644 --- a/ffi/capi/bindings/c/DateTimeFormatter.h +++ b/ffi/capi/bindings/c/DateTimeFormatter.h @@ -35,7 +35,7 @@ icu4x_DateTimeFormatter_format_datetime_mv1_result icu4x_DateTimeFormatter_forma typedef struct icu4x_DateTimeFormatter_format_iso_datetime_mv1_result {union { DateTimeFormatError err;}; bool is_ok;} icu4x_DateTimeFormatter_format_iso_datetime_mv1_result; icu4x_DateTimeFormatter_format_iso_datetime_mv1_result icu4x_DateTimeFormatter_format_iso_datetime_mv1(const DateTimeFormatter* self, const IsoDateTime* value, DiplomatWrite* write); -AnyCalendarKind icu4x_DateTimeFormatter_calendar_bcp47_mv1(const DateTimeFormatter* self); +AnyCalendarKind icu4x_DateTimeFormatter_calendar_kind_mv1(const DateTimeFormatter* self); void icu4x_DateTimeFormatter_destroy_mv1(DateTimeFormatter* self); diff --git a/ffi/capi/bindings/cpp/icu4x/DateFormatter.d.hpp b/ffi/capi/bindings/cpp/icu4x/DateFormatter.d.hpp index 8cb8b280e69..dc8b56c4bb5 100644 --- a/ffi/capi/bindings/cpp/icu4x/DateFormatter.d.hpp +++ b/ffi/capi/bindings/cpp/icu4x/DateFormatter.d.hpp @@ -53,7 +53,7 @@ class DateFormatter { inline diplomat::result format_iso_datetime(const icu4x::IsoDateTime& value) const; - inline icu4x::AnyCalendarKind calendar_bcp47() const; + inline icu4x::AnyCalendarKind calendar_kind() const; inline const icu4x::capi::DateFormatter* AsFFI() const; inline icu4x::capi::DateFormatter* AsFFI(); diff --git a/ffi/capi/bindings/cpp/icu4x/DateFormatter.hpp b/ffi/capi/bindings/cpp/icu4x/DateFormatter.hpp index bee73236721..aad249f7e98 100644 --- a/ffi/capi/bindings/cpp/icu4x/DateFormatter.hpp +++ b/ffi/capi/bindings/cpp/icu4x/DateFormatter.hpp @@ -44,7 +44,7 @@ namespace capi { typedef struct icu4x_DateFormatter_format_iso_datetime_mv1_result {union { icu4x::capi::DateTimeFormatError err;}; bool is_ok;} icu4x_DateFormatter_format_iso_datetime_mv1_result; icu4x_DateFormatter_format_iso_datetime_mv1_result icu4x_DateFormatter_format_iso_datetime_mv1(const icu4x::capi::DateFormatter* self, const icu4x::capi::IsoDateTime* value, diplomat::capi::DiplomatWrite* write); - icu4x::capi::AnyCalendarKind icu4x_DateFormatter_calendar_bcp47_mv1(const icu4x::capi::DateFormatter* self); + icu4x::capi::AnyCalendarKind icu4x_DateFormatter_calendar_kind_mv1(const icu4x::capi::DateFormatter* self); void icu4x_DateFormatter_destroy_mv1(DateFormatter* self); @@ -102,8 +102,8 @@ inline diplomat::result icu4x::DateForm return result.is_ok ? diplomat::result(diplomat::Ok(std::move(output))) : diplomat::result(diplomat::Err(icu4x::DateTimeFormatError::FromFFI(result.err))); } -inline icu4x::AnyCalendarKind icu4x::DateFormatter::calendar_bcp47() const { - auto result = icu4x::capi::icu4x_DateFormatter_calendar_bcp47_mv1(this->AsFFI()); +inline icu4x::AnyCalendarKind icu4x::DateFormatter::calendar_kind() const { + auto result = icu4x::capi::icu4x_DateFormatter_calendar_kind_mv1(this->AsFFI()); return icu4x::AnyCalendarKind::FromFFI(result); } diff --git a/ffi/capi/bindings/cpp/icu4x/DateTimeFormatter.d.hpp b/ffi/capi/bindings/cpp/icu4x/DateTimeFormatter.d.hpp index a8acc68a406..56c4d5eb5f9 100644 --- a/ffi/capi/bindings/cpp/icu4x/DateTimeFormatter.d.hpp +++ b/ffi/capi/bindings/cpp/icu4x/DateTimeFormatter.d.hpp @@ -45,7 +45,7 @@ class DateTimeFormatter { inline diplomat::result format_iso_datetime(const icu4x::IsoDateTime& value) const; - inline icu4x::AnyCalendarKind calendar_bcp47() const; + inline icu4x::AnyCalendarKind calendar_kind() const; inline const icu4x::capi::DateTimeFormatter* AsFFI() const; inline icu4x::capi::DateTimeFormatter* AsFFI(); diff --git a/ffi/capi/bindings/cpp/icu4x/DateTimeFormatter.hpp b/ffi/capi/bindings/cpp/icu4x/DateTimeFormatter.hpp index de2e6de3182..65246177659 100644 --- a/ffi/capi/bindings/cpp/icu4x/DateTimeFormatter.hpp +++ b/ffi/capi/bindings/cpp/icu4x/DateTimeFormatter.hpp @@ -36,7 +36,7 @@ namespace capi { typedef struct icu4x_DateTimeFormatter_format_iso_datetime_mv1_result {union { icu4x::capi::DateTimeFormatError err;}; bool is_ok;} icu4x_DateTimeFormatter_format_iso_datetime_mv1_result; icu4x_DateTimeFormatter_format_iso_datetime_mv1_result icu4x_DateTimeFormatter_format_iso_datetime_mv1(const icu4x::capi::DateTimeFormatter* self, const icu4x::capi::IsoDateTime* value, diplomat::capi::DiplomatWrite* write); - icu4x::capi::AnyCalendarKind icu4x_DateTimeFormatter_calendar_bcp47_mv1(const icu4x::capi::DateTimeFormatter* self); + icu4x::capi::AnyCalendarKind icu4x_DateTimeFormatter_calendar_kind_mv1(const icu4x::capi::DateTimeFormatter* self); void icu4x_DateTimeFormatter_destroy_mv1(DateTimeFormatter* self); @@ -76,8 +76,8 @@ inline diplomat::result icu4x::DateTime return result.is_ok ? diplomat::result(diplomat::Ok(std::move(output))) : diplomat::result(diplomat::Err(icu4x::DateTimeFormatError::FromFFI(result.err))); } -inline icu4x::AnyCalendarKind icu4x::DateTimeFormatter::calendar_bcp47() const { - auto result = icu4x::capi::icu4x_DateTimeFormatter_calendar_bcp47_mv1(this->AsFFI()); +inline icu4x::AnyCalendarKind icu4x::DateTimeFormatter::calendar_kind() const { + auto result = icu4x::capi::icu4x_DateTimeFormatter_calendar_kind_mv1(this->AsFFI()); return icu4x::AnyCalendarKind::FromFFI(result); } diff --git a/ffi/capi/bindings/dart/DateFormatter.g.dart b/ffi/capi/bindings/dart/DateFormatter.g.dart index 7b6cf7cce18..3635269998e 100644 --- a/ffi/capi/bindings/dart/DateFormatter.g.dart +++ b/ffi/capi/bindings/dart/DateFormatter.g.dart @@ -101,9 +101,9 @@ final class DateFormatter implements ffi.Finalizable { /// Returns the calendar system used in this formatter. /// - /// See the [Rust documentation for `calendar_bcp47`](https://docs.rs/icu/latest/icu/datetime/struct.DateTimeFormatter.html#method.calendar_bcp47) for more information. - AnyCalendarKind calendarBcp47() { - final result = _icu4x_DateFormatter_calendar_bcp47_mv1(_ffi); + /// See the [Rust documentation for `calendar_kind`](https://docs.rs/icu/latest/icu/datetime/struct.DateTimeFormatter.html#method.calendar_kind) for more information. + AnyCalendarKind calendarKind() { + final result = _icu4x_DateFormatter_calendar_kind_mv1(_ffi); return AnyCalendarKind.values[result]; } } @@ -144,6 +144,6 @@ external _ResultVoidInt32 _icu4x_DateFormatter_format_datetime_mv1(ffi.Pointer self, ffi.Pointer value, ffi.Pointer write); @meta.RecordUse() -@ffi.Native)>(isLeaf: true, symbol: 'icu4x_DateFormatter_calendar_bcp47_mv1') +@ffi.Native)>(isLeaf: true, symbol: 'icu4x_DateFormatter_calendar_kind_mv1') // ignore: non_constant_identifier_names -external int _icu4x_DateFormatter_calendar_bcp47_mv1(ffi.Pointer self); +external int _icu4x_DateFormatter_calendar_kind_mv1(ffi.Pointer self); diff --git a/ffi/capi/bindings/dart/DateTimeFormatter.g.dart b/ffi/capi/bindings/dart/DateTimeFormatter.g.dart index 0ed21e71fe7..fb2bc1c92f4 100644 --- a/ffi/capi/bindings/dart/DateTimeFormatter.g.dart +++ b/ffi/capi/bindings/dart/DateTimeFormatter.g.dart @@ -75,9 +75,9 @@ final class DateTimeFormatter implements ffi.Finalizable { /// Returns the calendar system used in this formatter. /// - /// See the [Rust documentation for `calendar_bcp47`](https://docs.rs/icu/latest/icu/datetime/struct.DateTimeFormatter.html#method.calendar_bcp47) for more information. - AnyCalendarKind calendarBcp47() { - final result = _icu4x_DateTimeFormatter_calendar_bcp47_mv1(_ffi); + /// See the [Rust documentation for `calendar_kind`](https://docs.rs/icu/latest/icu/datetime/struct.DateTimeFormatter.html#method.calendar_kind) for more information. + AnyCalendarKind calendarKind() { + final result = _icu4x_DateTimeFormatter_calendar_kind_mv1(_ffi); return AnyCalendarKind.values[result]; } } @@ -108,6 +108,6 @@ external _ResultVoidInt32 _icu4x_DateTimeFormatter_format_datetime_mv1(ffi.Point external _ResultVoidInt32 _icu4x_DateTimeFormatter_format_iso_datetime_mv1(ffi.Pointer self, ffi.Pointer value, ffi.Pointer write); @meta.RecordUse() -@ffi.Native)>(isLeaf: true, symbol: 'icu4x_DateTimeFormatter_calendar_bcp47_mv1') +@ffi.Native)>(isLeaf: true, symbol: 'icu4x_DateTimeFormatter_calendar_kind_mv1') // ignore: non_constant_identifier_names -external int _icu4x_DateTimeFormatter_calendar_bcp47_mv1(ffi.Pointer self); +external int _icu4x_DateTimeFormatter_calendar_kind_mv1(ffi.Pointer self); diff --git a/ffi/capi/bindings/js/DateFormatter.d.ts b/ffi/capi/bindings/js/DateFormatter.d.ts index a973fbf80d2..7a8c8880897 100644 --- a/ffi/capi/bindings/js/DateFormatter.d.ts +++ b/ffi/capi/bindings/js/DateFormatter.d.ts @@ -34,5 +34,5 @@ export class DateFormatter { formatIsoDatetime(value: IsoDateTime): string; - calendarBcp47(): AnyCalendarKind; + calendarKind(): AnyCalendarKind; } \ No newline at end of file diff --git a/ffi/capi/bindings/js/DateFormatter.mjs b/ffi/capi/bindings/js/DateFormatter.mjs index 5747a2a9f41..4e1e7639161 100644 --- a/ffi/capi/bindings/js/DateFormatter.mjs +++ b/ffi/capi/bindings/js/DateFormatter.mjs @@ -173,8 +173,8 @@ export class DateFormatter { } } - calendarBcp47() { - const result = wasm.icu4x_DateFormatter_calendar_bcp47_mv1(this.ffiValue); + calendarKind() { + const result = wasm.icu4x_DateFormatter_calendar_kind_mv1(this.ffiValue); try { return new AnyCalendarKind(diplomatRuntime.internalConstructor, result); diff --git a/ffi/capi/bindings/js/DateTimeFormatter.d.ts b/ffi/capi/bindings/js/DateTimeFormatter.d.ts index 34d60d2584d..78fbb2fbb16 100644 --- a/ffi/capi/bindings/js/DateTimeFormatter.d.ts +++ b/ffi/capi/bindings/js/DateTimeFormatter.d.ts @@ -28,5 +28,5 @@ export class DateTimeFormatter { formatIsoDatetime(value: IsoDateTime): string; - calendarBcp47(): AnyCalendarKind; + calendarKind(): AnyCalendarKind; } \ No newline at end of file diff --git a/ffi/capi/bindings/js/DateTimeFormatter.mjs b/ffi/capi/bindings/js/DateTimeFormatter.mjs index 9dd2f78d2c0..524e6bfad15 100644 --- a/ffi/capi/bindings/js/DateTimeFormatter.mjs +++ b/ffi/capi/bindings/js/DateTimeFormatter.mjs @@ -127,8 +127,8 @@ export class DateTimeFormatter { } } - calendarBcp47() { - const result = wasm.icu4x_DateTimeFormatter_calendar_bcp47_mv1(this.ffiValue); + calendarKind() { + const result = wasm.icu4x_DateTimeFormatter_calendar_kind_mv1(this.ffiValue); try { return new AnyCalendarKind(diplomatRuntime.internalConstructor, result); diff --git a/ffi/capi/src/datetime_formatter.rs b/ffi/capi/src/datetime_formatter.rs index bdd578537ab..b4eeba75df7 100644 --- a/ffi/capi/src/datetime_formatter.rs +++ b/ffi/capi/src/datetime_formatter.rs @@ -309,8 +309,8 @@ pub mod ffi { } /// Returns the calendar system used in this formatter. - #[diplomat::rust_link(icu::datetime::DateTimeFormatter::calendar_bcp47, FnInStruct)] - pub fn calendar_bcp47(&self) -> AnyCalendarKind { + #[diplomat::rust_link(icu::datetime::DateTimeFormatter::calendar_kind, FnInStruct)] + pub fn calendar_kind(&self) -> AnyCalendarKind { self.0.calendar_kind().into() } } @@ -381,8 +381,8 @@ pub mod ffi { } /// Returns the calendar system used in this formatter. - #[diplomat::rust_link(icu::datetime::DateTimeFormatter::calendar_bcp47, FnInStruct)] - pub fn calendar_bcp47(&self) -> AnyCalendarKind { + #[diplomat::rust_link(icu::datetime::DateTimeFormatter::calendar_kind, FnInStruct)] + pub fn calendar_kind(&self) -> AnyCalendarKind { self.0.calendar_kind().into() } }