-
Notifications
You must be signed in to change notification settings - Fork 897
Ensure lack of optional parameters #1031
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
😍 😍 😍 😍 😍 @nulltoken did you want an extra pair of hands to help with cleaning this up? otherwise I'm happy to help with reviewing... |
|
||
foreach (var method in mis.Distinct()) | ||
{ | ||
sb.AppendFormat("At least one overload of method '{0}' accepts an optional paramater.{1}", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
typo: parameter
@shiftkey Any help is welcome killing those optional parameters! 🙏 |
@nulltoken I'll start from the bottom of the list then. Shall I PR into this PR, or just add commits directly? |
@shiftkey Please push directly on top of this branch. ❤️ for the help |
from t in Assembly.GetAssembly(typeof(IRepository)) | ||
.GetExportedTypes() | ||
from m in t.GetMethods() | ||
where !m.IsObsolete() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There's a couple of methods which have optional parameters but are marked as obsolete. I figure we don't care about migrating those. Let me know if that's not the case.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good call! They'll be dropped before stabilization (post v0.22)
/// <param name="xdgConfigurationFileLocation">Path to a XDG configuration file. If null, the default path for a XDG configuration file will be probed.</param> | ||
/// <param name="systemConfigurationFileLocation">Path to a System configuration file. If null, the default path for a system configuration file will be probed.</param> | ||
public Configuration(string globalConfigurationFileLocation = null, string xdgConfigurationFileLocation = null, string systemConfigurationFileLocation = null) | ||
public Configuration(string globalConfigurationFileLocation, string xdgConfigurationFileLocation, string systemConfigurationFileLocation) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not sure if we wanted to overload everything here - I just went with the overloads for global and global/xdg. Would love some guidance.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
How you did it makes sense to me.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍
Pausing here because I'm concerned about wrestling with the mocks for |
😍 |
@nulltoken thoughts on what I'm doing wrong with that leaked |
@shiftkey see this line - In order to trigger this, you need to have
|
@shiftkey - I am not completely familiar with this yet, but it looks like the |
Okay, that should be the fix. I'll try and give it thorough review to ensure the optional combinations are maintained wherever appropriate, but any extra help would be 💖 |
@@ -10,6 +10,7 @@ | |||
<s:Boolean x:Key="/Default/CodeStyle/CodeFormatting/CSharpFormat/SPACE_AFTER_TYPECAST_PARENTHESES/@EntryValue">False</s:Boolean> | |||
<s:Boolean x:Key="/Default/CodeStyle/CodeFormatting/CSharpFormat/SPACE_WITHING_EMPTY_BRACES/@EntryValue">True</s:Boolean> | |||
<s:Boolean x:Key="/Default/CodeStyle/CodeFormatting/CSharpFormat/SPACE_WITHIN_SINGLE_LINE_ARRAY_INITIALIZER_BRACES/@EntryValue">True</s:Boolean> | |||
<s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/PredefinedNamingRules/=PrivateInstanceFields/@EntryIndexedValue"><Policy Inspect="True" Prefix="" Suffix="" Style="aaBb" /></s:String> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What does this change do? (asking for a friend)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think I found myself dropping the default _
when R# was bugging me during the refactoring. I'll check.
Pushed some fixups |
Anyone opposing to see this pulled in? |
|
Ensure lack of optional parameters
@shiftkey AWE. SOME! 💯 🎱 |
Fix #952