相关疑难解决方法(0)

C#结构"this = ...."

我刚刚在反射器中浏览文件,并在结构构造函数中看到了这个:

this = new Binder.SyntaxNodeOrToken();
Run Code Online (Sandbox Code Playgroud)

我以前没见过那个术语.有人可以解释这个赋值在C#中意味着什么.谷歌很难.

c# struct

35
推荐指数
2
解决办法
5179
查看次数

Go,为什么不应该使用"this"作为方法接收者名称

我使用VS Code Go扩展.

这是我的代码

func (this *MyClass) Xxx() error {}
Run Code Online (Sandbox Code Playgroud)

它提到了我

导出的方法MyClass.Xxx应该有注释或未导出

接收者名称应该反映其身份; 不要使用通用名称,如" me"," this"或" self";

reflection go visual-studio-code

3
推荐指数
1
解决办法
2521
查看次数

标签 统计

c# ×1

go ×1

reflection ×1

struct ×1

visual-studio-code ×1