Fix default valeu for reference types and non-reference types (#34)
* . * ok * sw * . * .
This commit is contained in:
+9
-1
@@ -30,6 +30,14 @@ namespace ProxyInterfaceSourceGeneratorTests.Source
|
||||
|
||||
string HelloWorld(string name);
|
||||
|
||||
string HelloWorld2(string? name = "x");
|
||||
|
||||
string HelloWorld3(char? ch = 'c');
|
||||
|
||||
string HelloWorld4(char ch);
|
||||
|
||||
string HelloWorld5(char? ch);
|
||||
|
||||
void WithParams(params string[] values);
|
||||
|
||||
string Add(string s, string @string);
|
||||
@@ -46,7 +54,7 @@ namespace ProxyInterfaceSourceGeneratorTests.Source
|
||||
|
||||
System.Threading.Tasks.Task<string?> Method3Async();
|
||||
|
||||
void CreateInvokeHttpClient(int i = 5, string? appId = null, System.Threading.CancellationToken token = default);
|
||||
void CreateInvokeHttpClient(int i = 5, string? appId = null, System.Collections.Generic.IReadOnlyDictionary<string, string> metadata = null, System.Threading.CancellationToken token = default(System.Threading.CancellationToken));
|
||||
|
||||
|
||||
|
||||
|
||||
+31
-2
@@ -48,6 +48,34 @@ namespace ProxyInterfaceSourceGeneratorTests.Source
|
||||
return result_282270798;
|
||||
}
|
||||
|
||||
public string HelloWorld2(string? name = "x")
|
||||
{
|
||||
string? name_ = name;
|
||||
var result__1104421408 = _Instance.HelloWorld2(name_);
|
||||
return result__1104421408;
|
||||
}
|
||||
|
||||
public string HelloWorld3(char? ch = 'c')
|
||||
{
|
||||
char? ch_ = ch;
|
||||
var result__1104421409 = _Instance.HelloWorld3(ch_);
|
||||
return result__1104421409;
|
||||
}
|
||||
|
||||
public string HelloWorld4(char ch)
|
||||
{
|
||||
char ch_ = ch;
|
||||
var result__1104421414 = _Instance.HelloWorld4(ch_);
|
||||
return result__1104421414;
|
||||
}
|
||||
|
||||
public string HelloWorld5(char? ch)
|
||||
{
|
||||
char? ch_ = ch;
|
||||
var result__1104421415 = _Instance.HelloWorld5(ch_);
|
||||
return result__1104421415;
|
||||
}
|
||||
|
||||
public void WithParams(params string[] values)
|
||||
{
|
||||
string[] values_ = values;
|
||||
@@ -105,12 +133,13 @@ namespace ProxyInterfaceSourceGeneratorTests.Source
|
||||
return result__57684656;
|
||||
}
|
||||
|
||||
public void CreateInvokeHttpClient(int i = 5, string? appId = null, System.Threading.CancellationToken token = default)
|
||||
public void CreateInvokeHttpClient(int i = 5, string? appId = null, System.Collections.Generic.IReadOnlyDictionary<string, string> metadata = null, System.Threading.CancellationToken token = default(System.Threading.CancellationToken))
|
||||
{
|
||||
int i_ = i;
|
||||
string? appId_ = appId;
|
||||
System.Collections.Generic.IReadOnlyDictionary<string, string> metadata_ = metadata;
|
||||
System.Threading.CancellationToken token_ = token;
|
||||
_Instance.CreateInvokeHttpClient(i_, appId_, token_);
|
||||
_Instance.CreateInvokeHttpClient(i_, appId_, metadata_, token_);
|
||||
}
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user