fix some bugs w.r.t. duplicate definitions
fix some bugs w.r.t. duplicate definitions

stefanseefeld/synopsis,stefanseefeld/synopsis,stefanseefeld/synopsis,stefanseefeld/synopsis,stefanseefeld/synopsis,stefanseefeld/synopsis