Skip to content

Commit b935818

Browse files
authored
Get rid of cfg(skip) (#5076)
It was a hack and it breaks rustc-check-cfg, let's not do that anymore. This is based on #5075 so that I can test this works with beta/nightly
1 parent 80b8174 commit b935818

File tree

30 files changed

+103
-121
lines changed

30 files changed

+103
-121
lines changed

components/calendar/src/any_calendar.rs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -756,9 +756,8 @@ impl AnyCalendar {
756756

757757
icu_provider::gen_any_buffer_data_constructors!(
758758
(locale) -> error: DataError,
759-
#[cfg(skip)]
760759
functions: [
761-
new_for_locale,
760+
new_for_locale: skip,
762761
try_new_for_locale_with_any_provider,
763762
try_new_for_locale_with_buffer_provider,
764763
try_new_for_locale_unstable,

components/calendar/src/chinese.rs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -160,9 +160,8 @@ impl Chinese {
160160
}
161161

162162
icu_provider::gen_any_buffer_data_constructors!(() -> error: DataError,
163-
#[cfg(skip)]
164163
functions: [
165-
new,
164+
new: skip,
166165
try_new_with_any_provider,
167166
try_new_with_buffer_provider,
168167
try_new_unstable,

components/calendar/src/dangi.rs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -153,9 +153,8 @@ impl Dangi {
153153
}
154154

155155
icu_provider::gen_any_buffer_data_constructors!(() -> error: DataError,
156-
#[cfg(skip)]
157156
functions: [
158-
new,
157+
new: skip,
159158
try_new_with_any_provider,
160159
try_new_with_buffer_provider,
161160
try_new_unstable,

components/calendar/src/islamic.rs

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -128,9 +128,8 @@ impl IslamicObservational {
128128
}
129129

130130
icu_provider::gen_any_buffer_data_constructors!(() -> error: DataError,
131-
#[cfg(skip)]
132131
functions: [
133-
new,
132+
new: skip,
134133
try_new_with_any_provider,
135134
try_new_with_buffer_provider,
136135
try_new_unstable,
@@ -175,9 +174,8 @@ impl IslamicUmmAlQura {
175174
}
176175

177176
icu_provider::gen_any_buffer_data_constructors!(() -> error: DataError,
178-
#[cfg(skip)]
179177
functions: [
180-
new,
178+
new: skip,
181179
try_new_with_any_provider,
182180
try_new_with_buffer_provider,
183181
try_new_unstable,

components/calendar/src/japanese.rs

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -130,9 +130,8 @@ impl Japanese {
130130
}
131131

132132
icu_provider::gen_any_buffer_data_constructors!(() -> error: DataError,
133-
#[cfg(skip)]
134133
functions: [
135-
new,
134+
new: skip,
136135
try_new_with_any_provider,
137136
try_new_with_buffer_provider,
138137
try_new_unstable,
@@ -188,9 +187,8 @@ impl JapaneseExtended {
188187
}
189188

190189
icu_provider::gen_any_buffer_data_constructors!(() -> error: DataError,
191-
#[cfg(skip)]
192190
functions: [
193-
new,
191+
new: skip,
194192
try_new_with_any_provider,
195193
try_new_with_buffer_provider,
196194
try_new_unstable,

components/casemap/src/casemapper.rs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -81,9 +81,8 @@ impl CaseMapper {
8181
}
8282

8383
icu_provider::gen_any_buffer_data_constructors!(() -> error: DataError,
84-
#[cfg(skip)]
8584
functions: [
86-
new,
85+
new: skip,
8786
try_new_with_any_provider,
8887
try_new_with_buffer_provider,
8988
try_new_unstable,

components/casemap/src/closer.rs

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -88,9 +88,8 @@ impl CaseMapCloser<CaseMapper> {
8888
}
8989

9090
icu_provider::gen_any_buffer_data_constructors!(() -> error: DataError,
91-
#[cfg(skip)]
9291
functions: [
93-
new,
92+
new: skip,
9493
try_new_with_any_provider,
9594
try_new_with_buffer_provider,
9695
try_new_unstable,
@@ -111,9 +110,8 @@ impl CaseMapCloser<CaseMapper> {
111110
// We use Borrow, not AsRef, since we want the blanket impl on T
112111
impl<CM: AsRef<CaseMapper>> CaseMapCloser<CM> {
113112
icu_provider::gen_any_buffer_data_constructors!((casemapper: CM) -> error: DataError,
114-
#[cfg(skip)]
115113
functions: [
116-
new_with_mapper,
114+
new_with_mapper: skip,
117115
try_new_with_mapper_with_any_provider,
118116
try_new_with_mapper_with_buffer_provider,
119117
try_new_with_mapper_unstable,

components/casemap/src/titlecase.rs

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -226,9 +226,8 @@ impl TitlecaseMapper<CaseMapper> {
226226
}
227227

228228
icu_provider::gen_any_buffer_data_constructors!(() -> error: DataError,
229-
#[cfg(skip)]
230229
functions: [
231-
new,
230+
new: skip,
232231
try_new_with_any_provider,
233232
try_new_with_buffer_provider,
234233
try_new_unstable,
@@ -249,9 +248,8 @@ impl TitlecaseMapper<CaseMapper> {
249248
// We use Borrow, not AsRef, since we want the blanket impl on T
250249
impl<CM: AsRef<CaseMapper>> TitlecaseMapper<CM> {
251250
icu_provider::gen_any_buffer_data_constructors!((casemapper: CM) -> error: DataError,
252-
#[cfg(skip)]
253251
functions: [
254-
new_with_mapper,
252+
new_with_mapper: skip,
255253
try_new_with_mapper_with_any_provider,
256254
try_new_with_mapper_with_buffer_provider,
257255
try_new_with_mapper_unstable,

components/collator/src/comparison.rs

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,13 @@ impl Collator {
9393

9494
icu_provider::gen_any_buffer_data_constructors!(
9595
(locale, options: CollatorOptions) -> error: DataError,
96-
#[cfg(skip)]
96+
functions: [
97+
try_new: skip,
98+
try_new_with_any_provider,
99+
try_new_with_buffer_provider,
100+
try_new_unstable,
101+
Self
102+
]
97103
);
98104

99105
#[doc = icu_provider::gen_any_buffer_unstable_docs!(UNSTABLE, Self::try_new)]

components/datetime/src/datetime.rs

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -100,9 +100,8 @@ impl TimeFormatter {
100100

101101
icu_provider::gen_any_buffer_data_constructors!(
102102
(locale, length: length::Time) -> error: DateTimeError,
103-
#[cfg(skip)]
104103
functions: [
105-
try_new_with_length,
104+
try_new_with_length: skip,
106105
try_new_with_length_with_any_provider,
107106
try_new_with_length_with_buffer_provider,
108107
try_new_with_length_unstable,
@@ -310,9 +309,8 @@ impl<C: CldrCalendar> TypedDateFormatter<C> {
310309

311310
icu_provider::gen_any_buffer_data_constructors!(
312311
(locale, length: length::Date) -> error: DateTimeError,
313-
#[cfg(skip)]
314312
functions: [
315-
try_new_with_length,
313+
try_new_with_length: skip,
316314
try_new_with_length_with_any_provider,
317315
try_new_with_length_with_buffer_provider,
318316
try_new_with_length_unstable,
@@ -562,9 +560,8 @@ where {
562560

563561
icu_provider::gen_any_buffer_data_constructors!(
564562
(locale, options: DateTimeFormatterOptions) -> error: DateTimeError,
565-
#[cfg(skip)]
566563
functions: [
567-
try_new,
564+
try_new: skip,
568565
try_new_with_any_provider,
569566
try_new_with_buffer_provider,
570567
try_new_unstable,

0 commit comments

Comments
 (0)