On Mon, 17 May 2021 14:30:20 GMT, Roger Riggs <[email protected]> wrote:
>> Stephen Colebourne has updated the pull request incrementally with one
>> additional commit since the last revision:
>>
>> 8266846: Add java.time.InstantSource
>
> src/java.base/share/classes/java/time/Clock.java line 128:
>
>> 126: * Implementations should implement {@code Serializable} wherever
>> possible and must
>> 127: * document whether or not they do support serialization.
>> 128: *
>
> The ImplSpec needs to say how it is implemented.
> The 'implements InstantSource' can not mandate any particular implementation.
> Its just an interface the real behavior comes from its implementations. In
> this case Clock. Referring to the static methods of InstantSource behavior
> may be sufficient because that behavior is concrete.
There are plenty of examples of interfaces in `java.time` and elsewhere that
apply restrictions to implementations. Nevertheless, for simplicity and
expediency I have reinstated the `implSpec` on `Clock`
-------------
PR: https://git.openjdk.java.net/jdk/pull/4016