Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Comments

Close side panel

dont abstract type for private fields#1409

Merged
baywet merged 1 commit intomicrosoft:vnextmicrosoft/OpenAPI.NET:vnextfrom
SimonCropp:dont-abstract-type-for-private-fieldsCopy head branch name to clipboard
Oct 6, 2023
Merged

dont abstract type for private fields#1409
baywet merged 1 commit intomicrosoft:vnextmicrosoft/OpenAPI.NET:vnextfrom
SimonCropp:dont-abstract-type-for-private-fieldsCopy head branch name to clipboard

Conversation

@SimonCropp
Copy link
Contributor

No description provided.

@baywet baywet enabled auto-merge October 6, 2023 11:48
public sealed class ValidationRuleSet : IEnumerable<ValidationRule>
{
private IDictionary<Type, IList<ValidationRule>> _rules = new Dictionary<Type, IList<ValidationRule>>();
private Dictionary<Type, IList<ValidationRule>> _rules = new();

Check notice

Code scanning / CodeQL

Missed 'readonly' opportunity

Field '_rules' can be 'readonly'.
private static ValidationRuleSet _defaultRuleSet;

private IList<ValidationRule> _emptyRules = new List<ValidationRule>();
private List<ValidationRule> _emptyRules = new();

Check notice

Code scanning / CodeQL

Missed 'readonly' opportunity

Field '_emptyRules' can be 'readonly'.
}

private IDictionary<Type, Func<ParseNode, object>> _loaders = new Dictionary<Type, Func<ParseNode, object>>
private Dictionary<Type, Func<ParseNode, object>> _loaders = new()

Check notice

Code scanning / CodeQL

Missed 'readonly' opportunity

Field '_loaders' can be 'readonly'.
}

private IDictionary<Type, Func<ParseNode, object>> _loaders = new Dictionary<Type, Func<ParseNode, object>>
private Dictionary<Type, Func<ParseNode, object>> _loaders = new()

Check notice

Code scanning / CodeQL

Missed 'readonly' opportunity

Field '_loaders' can be 'readonly'.
@baywet baywet merged commit 62999e8 into microsoft:vnext Oct 6, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants

Morty Proxy This is a proxified and sanitized view of the page, visit original site.