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

why not return error when setting parents if there is a circle error #19

Open
nullne opened this issue Jul 4, 2017 · 2 comments
Open
Assignees

Comments

@nullne
Copy link

nullne commented Jul 4, 2017

Several advices:

  • SetParent, if you set 1 to a, then a == 1, but SetParent is more like AddParent
  • If there are some potential circle errors, they should be thrown immediately rather than at runtime
@mikespook
Copy link
Owner

mikespook commented Jul 5, 2017

I would agree with the first point and it will be improved.

The second one, if we put circle detecting to the function it will reduce the performance significantly.

I suggest using InherCircle manually and adding it to each SetParent call if detecting circle errors is the key step to you.

Thank you!

@mikespook mikespook self-assigned this Jul 5, 2017
@nullne
Copy link
Author

nullne commented Jul 5, 2017

By the way, thank you for your work

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

No branches or pull requests

2 participants