@CanIgnoreReturnValue
  public Replacements add(Replacement replacement) {
    return add(replacement, CoalescePolicy.REJECT);
  }
@Test
  public void duplicate() {
    Replacements replacements = new Replacements();
    replacements.add(Replacement.create(42, 43, "hello"));
    try {
      replacements.add(Replacement.create(42, 43, "goodbye"));
      fail();
    } catch (IllegalArgumentException expected) {
      assertThat(expected).hasMessageThat().contains("conflicts with existing replacement");
    }
  }