Skip to content
Snippets Groups Projects
Commit a955fe9b authored by Rafael Ravedutti's avatar Rafael Ravedutti
Browse files

Fix minor problem with cell reference


Signed-off-by: default avatarRafael Ravedutti <rafaelravedutti@gmail.com>
parent 52189ace
Branches
Tags
No related merge requests found
...@@ -66,10 +66,10 @@ class NeighborFor: ...@@ -66,10 +66,10 @@ class NeighborFor:
cell_neighbors = self.cell_lists.cell_neighbors cell_neighbors = self.cell_lists.cell_neighbors
for shape in self.shapes: for shape in self.shapes:
start = sum([cell_nneighs[cell][s] for s in range(shape)], 0)
# FIXME: Without the inline, the 'cell' expression is being generated after # FIXME: Without the inline, the 'cell' expression is being generated after
# its usage in the loop upper limit # its usage in the loop upper limit
cell = ScalarOp.inline(particle_cell[self.particle]) cell = ScalarOp.inline(particle_cell[self.particle])
start = sum([cell_nneighs[cell][s] for s in range(shape)], 0)
for k in For(self.sim, start, start + cell_nneighs[cell][shape]): for k in For(self.sim, start, start + cell_nneighs[cell][shape]):
particle_id = cell_neighbors[cell][k] particle_id = cell_neighbors[cell][k]
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment