-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: disable "unused" warning for placeholders whose name starts wit…
…h an underscore (#1155) Closes #1154 ### Summary of Changes Don't show a warning anymore that a placeholder is unused, if its name starts with an underscore.
- Loading branch information
1 parent
b469779
commit 25781a8
Showing
5 changed files
with
82 additions
and
30 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
31 changes: 21 additions & 10 deletions
31
packages/safe-ds-lang/tests/resources/validation/names/casing/placeholders.sdsdev
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,25 @@ | ||
package tests.validation.names.casing | ||
|
||
pipeline myPipeline2 { | ||
// $TEST$ warning "Names of placeholders should be lowerCamelCase." | ||
val »PlaceholderUppercase« = 1; | ||
// $TEST$ no warning "Names of placeholders should be lowerCamelCase." | ||
val »placeholderLowercase1« = 1; | ||
// $TEST$ no warning "Names of placeholders should be lowerCamelCase." | ||
val »`placeholderLowercase2`« = 1; | ||
// $TEST$ warning "Names of placeholders should be lowerCamelCase." | ||
val »_placeholderUnderscore« = 1; | ||
// $TEST$ warning "Names of placeholders should be lowerCamelCase." | ||
val »placeholder_snake_case« = 1; | ||
// $TEST$ warning "Names of used placeholders should be lowerCamelCase." | ||
val »UsedPlaceholderUppercase« = 1; | ||
// $TEST$ no warning "Names of used placeholders should be lowerCamelCase."" | ||
val »usedPlaceholderLowercase1« = 1; | ||
// $TEST$ no warning "Names of used placeholders should be lowerCamelCase."" | ||
val »`usedPlaceholderLowercase2`« = 1; | ||
// $TEST$ warning "Names of used placeholders should be lowerCamelCase." | ||
val »_usedPlaceholderUnderscore« = 1; | ||
// $TEST$ warning "Names of used placeholders should be lowerCamelCase." | ||
val »used_placeholder_snake_case« = 1; | ||
|
||
// $TEST$ warning "Names of unused placeholders should be lowerCamelCase with an optional leading underscore." | ||
val »UnusedPlaceholderUppercase« = UsedPlaceholderUppercase + 1; | ||
// $TEST$ no warning "Names of unused placeholders should be lowerCamelCase. with an optional leading underscore." | ||
val »unusedPlaceholderLowercase1« = usedPlaceholderLowercase1 + 1; | ||
// $TEST$ no warning "Names of unused placeholders should be lowerCamelCase. with an optional leading underscore." | ||
val »`unusedPlaceholderLowercase2`« = usedPlaceholderLowercase2 + 1; | ||
// $TEST$ no warning "Names of unused placeholders should be lowerCamelCase with an optional leading underscore." | ||
val »_unusedPlaceholderUnderscore« = _usedPlaceholderUnderscore + 1; | ||
// $TEST$ warning "Names of unused placeholders should be lowerCamelCase with an optional leading underscore." | ||
val »unused_placeholder_snake_case« = used_placeholder_snake_case + 1; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters