Ulrich Schuster
01/17/2025, 1:49 PMaccumulate
DSL in Arrow 2, I was surprised to see that `ensureNotNullOrAccumulate`returns Unit
instead of the non-null value. The latter would be consistent with how ensureNotNull
and requireNotNull
works. Is there a reason for this surprising behavior?Youssef Shoaib [MOD]
01/17/2025, 5:13 PMensureNotNullOrAccumulate
doesn't actually raise
, instead it accumulates that error. This means that after that call, your value may still be null. Maybe it should return RaiseAccumulate.Value<T!!>
though