gnetlist -g check-duplicates other-gnetlist-arguments
This gnetlist back end finds duplicated refdes-pinnumber pairs. It emits a list of the duplicates to the standard error output. It yields an exit code of 1 if it has found any duplicates. Duplicates generally cause trouble for netlist generators, so this is a good check to run before you generate a netlist. Common causes of duplicates include erroneously duplicated refdes attributes, erroneously duplicated pinnumber attributes on a symbol, duplicate slots, and other errors in constructing composite devices from split symbols.
You can also use this code from within another back end. Load the code using
Then, the expression:
will yield the list of duplicates.