null == "" is true?
Antonio
antonio at abrevia.net
Mon Jul 18 21:23:32 UTC 2022
On Monday, 18 July 2022 at 17:20:04 UTC, Kagamin wrote:
> ... If you want such difference, use the Nullable wrapper or
> Algebraic.
I do :-) In fact, I use algebraic types supporting Null and
Undefined for DTOs representation (and REST APIs). But I
discovered some "rare" side effects in libraries like vibe.d and
structs where, sometimes, am empty string is deserialized as null
(value is null) and I have to assume that null in an string is
always "" for avoiding this weird effects
I'm under pressure to meet deadlines and a team that is telling
me "Why D instead typescript, Antonio?"... One month ago I
reported some questions in forums or git repos... but I have to
finish my work and 2 hours stoppers are not acceptable now.
I will study it in detail and report (if required). May be, I
will write the DTO problem with D article if I find time in
august.
More information about the Digitalmars-d-learn
mailing list