@@ -263,8 +263,7 @@ namespace REL
263
263
264
264
template <class ... Args>
265
265
std::invoke_result_t <const value_type&, Args...> operator ()(Args&&... a_args) const
266
- noexcept (std::is_nothrow_invocable_v<const value_type&, Args...>)
267
- requires(std::invocable<const value_type&, Args...>)
266
+ noexcept (std::is_nothrow_invocable_v<const value_type&, Args...>) requires(std::invocable<const value_type&, Args...>)
268
267
{
269
268
return REL::invoke (get (), std::forward<Args>(a_args)...);
270
269
}
@@ -279,58 +278,49 @@ namespace REL
279
278
return stl::unrestricted_cast<value_type>(_impl);
280
279
}
281
280
282
-
283
281
template <std::integral U>
284
- void write (const U& a_data)
285
- requires(std::same_as<value_type, std::uintptr_t >)
282
+ void write (const U& a_data) requires(std::same_as<value_type, std::uintptr_t >)
286
283
{
287
284
safe_write (address (), std::addressof (a_data), sizeof (T));
288
285
}
289
286
290
287
template <class U >
291
- void write (const std::span<U> a_data)
292
- requires(std::same_as<value_type, std::uintptr_t >)
288
+ void write (const std::span<U> a_data) requires(std::same_as<value_type, std::uintptr_t >)
293
289
{
294
290
safe_write (address (), a_data.data (), a_data.size_bytes ());
295
291
}
296
292
297
293
template <std::size_t N>
298
- std::uintptr_t write_branch (const std::uintptr_t a_dst)
299
- requires(std::same_as<value_type, std::uintptr_t >)
294
+ std::uintptr_t write_branch (const std::uintptr_t a_dst) requires(std::same_as<value_type, std::uintptr_t >)
300
295
{
301
296
return F4SE::GetTrampoline ().write_branch <N>(address (), a_dst);
302
297
}
303
298
304
299
template <std::size_t N, class F >
305
- std::uintptr_t write_branch (const F a_dst)
306
- requires(std::same_as<value_type, std::uintptr_t >)
300
+ std::uintptr_t write_branch (const F a_dst) requires(std::same_as<value_type, std::uintptr_t >)
307
301
{
308
302
return F4SE::GetTrampoline ().write_branch <N>(address (), stl::unrestricted_cast<std::uintptr_t >(a_dst));
309
303
}
310
304
311
305
template <std::size_t N>
312
- std::uintptr_t write_call (const std::uintptr_t a_dst)
313
- requires(std::same_as<value_type, std::uintptr_t >)
306
+ std::uintptr_t write_call (const std::uintptr_t a_dst) requires(std::same_as<value_type, std::uintptr_t >)
314
307
{
315
308
return F4SE::GetTrampoline ().write_call <N>(address (), a_dst);
316
309
}
317
310
318
311
template <std::size_t N, class F >
319
- std::uintptr_t write_call (const F a_dst)
320
- requires(std::same_as<value_type, std::uintptr_t >)
312
+ std::uintptr_t write_call (const F a_dst) requires(std::same_as<value_type, std::uintptr_t >)
321
313
{
322
314
return F4SE::GetTrampoline ().write_call <N>(address (), stl::unrestricted_cast<std::uintptr_t >(a_dst));
323
315
}
324
316
325
- void write_fill (const std::uint8_t a_value, const std::size_t a_count)
326
- requires(std::same_as<value_type, std::uintptr_t >)
317
+ void write_fill (const std::uint8_t a_value, const std::size_t a_count) requires(std::same_as<value_type, std::uintptr_t >)
327
318
{
328
319
safe_fill (address (), a_value, a_count);
329
320
}
330
321
331
322
template <class U = value_type>
332
- std::uintptr_t write_vfunc (std::size_t a_idx, std::uintptr_t a_newFunc)
333
- requires(std::same_as<U, std::uintptr_t >)
323
+ std::uintptr_t write_vfunc (std::size_t a_idx, std::uintptr_t a_newFunc) requires(std::same_as<U, std::uintptr_t >)
334
324
{
335
325
const auto addr = address () + (sizeof (void *) * a_idx);
336
326
const auto result = *reinterpret_cast <std::uintptr_t *>(addr);
@@ -339,8 +329,7 @@ namespace REL
339
329
}
340
330
341
331
template <class F >
342
- std::uintptr_t write_vfunc (std::size_t a_idx, F a_newFunc)
343
- requires(std::same_as<value_type, std::uintptr_t >)
332
+ std::uintptr_t write_vfunc (std::size_t a_idx, F a_newFunc) requires(std::same_as<value_type, std::uintptr_t >)
344
333
{
345
334
return write_vfunc (a_idx, stl::unrestricted_cast<std::uintptr_t >(a_newFunc));
346
335
}
0 commit comments