@@ -141,24 +141,24 @@ _**Note:** Order descending chronologically._
141
141
142
142
There are different reasons why this interface does not enforce a specific timezone.
143
143
144
- A purely technical reason is that the interface itself provides an explicit contract. Part of this contract
145
- is the value returned by the ` now() ` method. At the language level, the only thing we can enforce is that
144
+ A purely _ technical _ reason is that the interface itself provides an explicit contract. Part of this contract
145
+ is the value returned by the ` now() ` method. At the _ language _ level, the only thing we can enforce is that
146
146
the returned value is of type ` \DateTimeImmutable ` . There is no way to enforce a certain timezone at the
147
147
language level.
148
148
149
- A logical reason is that the explicit contract should be usable in all situations where one needs a way to
150
- retrieve the current time. We should not make an assumption at the contract level about what the caller
149
+ A _ logical _ reason is that the explicit contract should be usable in all situations where one needs a way to
150
+ retrieve the current time. We should not make an assumption at the _ contract _ level about what the caller
151
151
needs. If the contract did define that only ` UTC ` is returned, then use cases that require something else
152
- will have to explicitly work around the returned ` UTC ` timezone. This is different from issues such as
153
- immutability, which also cannot be enforced on the language level, but which is still necessary to
154
- adhere to other calls on the contract. For this ` ClockInterface ` , there will be no other calls.
152
+ would have to explicitly work around the returned ` UTC ` timezone. This is different from issues such as
153
+ immutability, which also cannot be enforced on the language level, but which is still necessary to adhere
154
+ to other calls on the contract. For this ` ClockInterface ` , there will be no other calls.
155
155
156
- Most importantly, the explicit contract provided by this interface does not prevent a user from using
156
+ Most importantly, the explicit contract provided by this interface does not _ prevent _ a user from using
157
157
an implicit contract alongside logic to return a ` \DateTimeImmutable ` with a specific timezone. Whether
158
- that is ` UTC ` or ` Antarctica/Troll ` , it is the user who is in control of this.
158
+ that is ` UTC ` or ` Antarctica/Troll ` , it is the _ user _ who is in control of this.
159
159
160
160
The explicit contract defined by the interface does not limit a user in what they are doing. It tries to
161
161
solve the problem of getting the current time in a reliable way. Whatever view on the current time that is,
162
162
it is not part of the explicit contract.
163
163
164
- Thus, this interface tries to be as open as possible , while at the same time, being as strict as necessary .
164
+ Thus, this interface tries to be as _ open as possible _ , while at the same time, being as _ strict as necessary _ .
0 commit comments