Skip to content
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

No NullReferenceException when passing null to Table.Set #179

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

bplu4t2f
Copy link
Contributor

@bplu4t2f bplu4t2f commented Feb 3, 2017

Passing null as value parameter in any of the Table.Set overloads causes a NullReferenceException in Table.PerformTableSet. I propose either a proper ArgumentNullException, or giving null a reasonable meaning. Considering the similarity to setting the value to nil (instead of null) it might be reasonable to assume that the intent of the user in this case is to remove the value from the table.

Copy link
Contributor

@LimpingNinja LimpingNinja left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's a little late, not certain if we should be checkin IsNil() here as well to be clear on the assumed intent. I may be wrong though, I probably should sleep. We do need an appropriate test case added to this PR as well if you can.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants