Revision 4048
Added by Aaron Marcuse-Kubitza over 12 years ago
bin/map | ||
---|---|---|
258 | 258 |
default = util.NamedTuple(count=1, first=i) |
259 | 259 |
idxs = outputs_idxs.setdefault(out, default) |
260 | 260 |
if idxs is not default: # key existed, so there was a collision |
261 |
if idxs.count == 1: # first key does not yet have /_alt/#
|
|
261 |
if idxs.count == 1: # first key does not yet have suffix
|
|
262 | 262 |
mappings[idxs.first][1] += collision_suffix+'0' |
263 | 263 |
mappings[i][1] += collision_suffix+str(idxs.count) |
264 | 264 |
idxs.count += 1 |
Also available in: Unified diff
bin/map: Preventing collisions if multiple inputs mapping to same output: Made collision suffix configurable so it can easily be changed