-
Notifications
You must be signed in to change notification settings - Fork 281
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
Problem when using ifelse #1542
Comments
Have you tried using |
Actually, my element_buffer is a list, and the return value of if_else seems to be a cint, and I can't access the list with that cint |
I meant within the |
I've shrunk it down a bit, but to make sure you're operating the same way I am, I'm still constructing them as a class.
|
You cannot use Python lists in this way because they will be populated at compile-time rather than at run-time. You have to use |
I tried replacing the |
Yes. Python lists are not a problem if you don't use them both in- and outside run-time branching constructions like |
I'm trying to implement a priority queue and I'm having problems, I'm trying to use the depth bit of the hash value to select which child node to distribute the element to, but when I complete the insertion using ifelse, my output finds that this one element exists in both child nodes.
Whereas when I don't use ifelse, but fix one byte distribution there is no problem, the element is correctly placed in the corresponding position, could this be due to some data structure effect?
The text was updated successfully, but these errors were encountered: