bigbang icon indicating copy to clipboard operation
bigbang copied to clipboard

Housekeeping and code cleaning

Open sezna opened this issue 6 years ago • 0 comments

entity.rs needs a refactor. The branching on the right and the left is no bueno. Some alternatives:

  • Keep the node structure but make a function do the stuff that's duplicated. Thread-spawn it (bench this) on big recursive calls and do both sides at once.
  • Change left, right to [Node; 2]
  • Node could be an enum of leaf or internal, getting rid of some options
  • The tree should be an iter so we don't have to process the entire vec beforehand
  • There might be better (unsafe?) ways to represent the tree in memory...maybe.

sezna avatar Dec 08 '19 19:12 sezna