Skip to content

Commit e0e14ed

Browse files
(MAINT) Address copilot feedback
1 parent 41d722c commit e0e14ed

4 files changed

Lines changed: 8 additions & 13 deletions

File tree

lib/dsc-lib-jsonschema-macros/src/derive/dsc_repo_schema.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -192,7 +192,7 @@ fn generate_schema_property_metadata_fn(schema_field: &DscRepoSchemaField) -> pr
192192
}
193193
}
194194

195-
/// Generates a crate-local implementation for the `lookup_translation()` trait function. This is
195+
/// Generates a crate-local implementation for the `schema_i18n()` trait function. This is
196196
/// required to ensure that the translations use the correct locale definitions.
197197
fn generate_schema_i18n_fn() -> proc_macro2::TokenStream {
198198
quote! {

lib/dsc-lib-jsonschema/locales/en-us.toml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -205,12 +205,12 @@ Each item defines a snippet for users that VS Code will surface as part of Intel
205205
206206
Every snippet must define either the `body` or `bodyText` property, which VS Code uses
207207
to insert the snippet into the data file. If you specify both `body` and `bodyText`, the
208-
value for `body` supercedes the value for `bodyText`.
208+
value for `body` supersedes the value for `bodyText`.
209209
210210
The `description`, and `markdownDescription` properties provide documentation for the
211211
snippet and are displayed in the hover text when a user selects the snippet. If you
212212
specify both `description` and `markdownDescription`, the text for
213-
`markdownDescription` supercedes the text for `description`.
213+
`markdownDescription` supersedes the text for `description`.
214214
215215
The `label` property defines a short name for the snippet. If the snippet doesn't define
216216
the `label` property, VS Code shows a stringified representation of the snippet instead.
@@ -430,7 +430,7 @@ keywords and fails those validations.
430430
- When the data includes a property that isn't evaluated by any keywords and the schema
431431
defines `unevaluatedProperties` as `false`.
432432
433-
The value for the `errorMessage` keyword supercedes all default messages for the schema
433+
The value for the `errorMessage` keyword supersedes all default messages for the schema
434434
or subschema where you define the keyword. You can provide per-validation failure
435435
messages by defining the validating keywords in separate entries of the `allOf` keyword
436436
and defining the `errorMessage` keyword for each entry.
@@ -449,7 +449,7 @@ without converting any apparent markup.
449449
450450
You can define the `markdownDescription` keyword to provide descriptive text as markdown,
451451
including links and code blocks. When a schema or subschema defines the
452-
`markdownDescription` keyword, that value supercedes any defined text in the `description`
452+
`markdownDescription` keyword, that value supersedes any defined text in the `description`
453453
keyword.
454454
455455
You can also use the `markdownEnumDescriptions` keyword to document the values defined
@@ -475,7 +475,7 @@ the `enum` keyword, VS Code displays the text from the `description` or
475475
`markdownEnumDescriptions` keyword to define documentation for each enum value.
476476
477477
When a schema or subschema defines the `markdownEnumDescriptions` keyword, that value
478-
supercedes any defined text in the `description`, `markdownDescription`, or
478+
supersedes any defined text in the `description`, `markdownDescription`, or
479479
`enumDescriptions` keywords.
480480
481481
The keyword expects an array of strings. VS Code correlates the items in the

lib/dsc-lib-jsonschema/src/dsc_repo/dsc_repo_schema.rs

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -356,11 +356,6 @@ pub trait DscRepoSchema : JsonSchema {
356356
/// # Errors
357357
///
358358
/// Returns a [`DscRepoSchemaMissingTranslation`] error if the translation key doesn't exist.
359-
///
360-
/// # Example
361-
///
362-
/// ```ignore
363-
/// ```
364359
fn schema_i18n(suffix: &str) -> Result<String, DscRepoSchemaMissingTranslation>;
365360
}
366361

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#[macro_export]
22
macro_rules! schema_i18n {
3-
($dotPath: literal) => {
4-
Self::schema_i18n($dotPath).unwrap()
3+
($dot_path: literal) => {
4+
Self::schema_i18n($dot_path).unwrap()
55
};
66
}

0 commit comments

Comments
 (0)