If `basicFactory` is non-null, it and `factory` are the same object. I could add an assertion to make this clear.