>//positionの値が同じ要素はsetに登録しない
>bool same = (a->position == b->position);
>if( same ) return false;
仕様誤解してたサーセンgrz、、