diff --git a/README.md b/README.md index 0f5f2fb6..1fa38b14 100644 --- a/README.md +++ b/README.md @@ -145,7 +145,7 @@ https://consensys.github.io/smart-contract-best-practices/recommendations/) | **func-param-name-mixedcase** | Function param name must be in mixedCase | | **var-name-mixedcase** | Variable name must be in mixedCase | | **event-name-camelcase** | Event name must be in CamelCase | - | **const-name-snakecase** | Constant name must be in SCREAMING_SNAKE_CASE | + | **const-name-snakecase** | Constant name must be in capitalized SNAKE_CASE | | **modifier-name-mixedcase** | Modifier name must be in mixedCase | | **contract-name-camelcase** | Contract name must be in CamelCase | | **use-forbidden-name** | Avoid to use letters 'I', 'l', 'O' as identifiers | diff --git a/docs/rules.md b/docs/rules.md index eb67d8c0..3c3295f9 100644 --- a/docs/rules.md +++ b/docs/rules.md @@ -51,7 +51,7 @@ description: List of validation rules for Solhint - Solidity security, style gui | **func-param-name-mixedcase** | Function param name must be in mixedCase | *[default](#options)* | | **var-name-mixedcase** | Variable name must be in mixedCase | *[default](#options)* | | **event-name-camelcase** | Event name must be in CamelCase | *[default](#options)* | - | **const-name-snakecase** | Constant name must be in SCREAMING_SNAKE_CASE | *[default](#options)* | + | **const-name-snakecase** | Constant name must be in capitalized SNAKE_CASE | *[default](#options)* | | **modifier-name-mixedcase** | Modifier name must be in mixedCase | *[default](#options)* | | **contract-name-camelcase** | Contract name must be in CamelCase | *[default](#options)* | | **use-forbidden-name** | Avoid to use letters 'I', 'l', 'O' as identifiers | *[default](#options)* | diff --git a/lib/rules/naming/var-name-style.js b/lib/rules/naming/var-name-style.js index 209b65f7..08336375 100644 --- a/lib/rules/naming/var-name-style.js +++ b/lib/rules/naming/var-name-style.js @@ -43,7 +43,7 @@ class VarNameStyleChecker extends BaseChecker { validateConstantName(ctx) { this._forEachIdentifier(ctx, (curId, text) => { if (naming.isNotUpperSnakeCase(text)) { - this.error(curId, 'const-name-snakecase', 'Constant name must be in SCREAMING_SNAKE_CASE'); + this.error(curId, 'const-name-snakecase', 'Constant name must be in capitalized SNAKE_CASE'); } }); }