lazy<T> function

Lazy<T> lazy<T>({
  1. required LazyThreadSafetyMode mode,
  2. required T initializer(),
})

Creates a new instance of the Lazy that uses the specified initialization function initializer and the default thread-safety mode LazyThreadSafetyMode.SYNCHRONIZED.

Implementation

Lazy<T> lazy<T>({
  required LazyThreadSafetyMode mode,
  required T Function() initializer,
}) {
  throw Exception();
}