You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
One of the biggest blockers for the "optimal" syntax ?. is the optional chain call ?.(. I hate it, and a few other delegates agree.
I don't, however, share the requirement that all three operators share the same base (the whole ??. operators). I think ?.[ is ugly, but it still means property access to me. Even in deep chaining sequences, it still makes sense to parse (compare this with my rant against?.(:
It's obviously not great, but it's not a total deal breaker for me.
So this leads to my proposal. Why not just drop the optional call entirely (to be clear, not the short-circuiting of method calls, just the ?.( optional call)? I don't have any major use cases for it.
One of the biggest blockers for the "optimal" syntax
?.is the optional chain call?.(. I hate it, and a few other delegates agree.I don't, however, share the requirement that all three operators share the same base (the whole
??.operators). I think?.[is ugly, but it still means property access to me. Even in deep chaining sequences, it still makes sense to parse (compare this with my rant against?.(:It's obviously not great, but it's not a total deal breaker for me.
So this leads to my proposal. Why not just drop the optional call entirely (to be clear, not the short-circuiting of method calls, just the
?.(optional call)? I don't have any major use cases for it.