-
Notifications
You must be signed in to change notification settings - Fork 21
Add code_for #7
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
Add code_for #7
Conversation
Codecov Report
@@ Coverage Diff @@
## master #7 +/- ##
=========================================
Coverage 100.00% 100.00%
=========================================
Files 5 5
Lines 191 193 +2
=========================================
+ Hits 191 193 +2
Continue to review full report at Codecov.
|
julia> meta[:a] = nothing | ||
|
||
julia> code_for(meta, :a) | ||
1 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't understand what this is supposed to do. Why does this return 1
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Because vertex :a
is at vertex number 1. Does that make sense? Could I update the docs to make it more clear?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Where did you add the vertex? Did it automatically get added on the setindex
call on L338?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ok, well I guess I'll merge this. Let me know if I should add anything to the docs to clarify that vertices get automatically added.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think it's best if it were documented. Implicit mutation of a graph is a footgun.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ref edd0b91
Thought this might be useful to have. Similar to the CameronBieganek's
V
function.