-
Notifications
You must be signed in to change notification settings - Fork 2.5k
Allow access container whose key is string #965
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
Open
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
这是规避lua的语法就没法区分obj.X和obj["X"]的问题的修改。
一个对象有个Print方法(字段也是类似),那obj.Print是要返回obj的Print方法,还是用字符串"Print"去索引呢?
这是规避lua的语法就没法区分obj.X和obj["X"]的问题的修改。
一个对象有个Print方法(字段也是类似),那obj.Print是要返回obj的Print方法,还是用字符串"Print"去索引呢?
我知道,但是我只需要它作为一个容器用,这样很方便,所以要求加属性,表示你自己知道会有什么后果
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
fix #707
我知道这个在FAQ里面有说明,但是有些时候直接访问还是方便很多,所以我加了一个Attribute,有这个Attribute的才生成访问函数