Dgraph icon indicating copy to clipboard operation
Dgraph copied to clipboard

isEdge and edgeID methods are suboptimal

Open WebDrake opened this issue 12 years ago • 1 comments
trafficstars

The current implementations of isEdge and edgeID use a linear search. This should be replaced by a binary search that takes advantage of the sorting of head and tail indexes.

WebDrake avatar Sep 12 '13 22:09 WebDrake

Probably the best way to fix this is via a solution to https://d.puremagic.com/issues/show_bug.cgi?id=11667 after which it should be possible to use std.algorithm.find.

WebDrake avatar Dec 29 '13 20:12 WebDrake