I've begun to notice at times when I'm making method calls in C# that the names of the parameters for the method I'm calling will show up in the intellisense list appended with a colon, and that I can then format the method call thusly:
MethodCall(parameter1:value1, parameter2:value2);
Is this a new language feature? It reminds me of the way you can call stored procedures in SQL and specify parameter names like so:
spDoSomeStuff @param1 = 1, @param2 = 'other param'
Is this a similar feature? If so, to what end? If not, what is it and what is it to be used for.
question from:
https://stackoverflow.com/questions/5262634/c-sharp-method-call-with-parameter-name-and-colon 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…