setDefaultImpl aborts on a second call

The actual problem is that default implementation is set globally.
setDefaultImpl might not work as expected when it is called twice with
different instances.

Because we don't have a proper solution for the problem, we prevent
calling setDefaultImpl() twice by aborting.

Bug: 140139809
Test: ./runtests.sh
Change-Id: I910ef474fc87d8c818552df99a79703fc101229d
4 files changed