using System.Collections.Generic;
_ = val.AsNullable()!.Value;
public static T? AsNullable<T>(this T t) where T : struct => (T?) t;
public static IEnumerable<T> WhereNotNull<T>(this IEnumerable<T?> ts) where T : struct => ts.Where(t => t.HasValue).Select(x => x!.Value);