MCPcopy Index your code
hub / github.com/clips/pattern / uniq

Function uniq

pattern/web/pdf/utils.py:36–43  ·  view source on GitHub ↗

Eliminates duplicated elements.

(objs)

Source from the content-addressed store, hash-verified

34
35# uniq
36def uniq(objs):
37 """Eliminates duplicated elements."""
38 done = set()
39 for obj in objs:
40 if obj in done: continue
41 done.add(obj)
42 yield obj
43 return
44
45# csort
46def csort(objs, key=lambda x:x):

Callers 1

get_textboxesMethod · 0.90

Calls 1

addMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…