vibe.d 0.7.24 released
Adam D. Ruppe via Digitalmars-d-announce
digitalmars-d-announce at puremagic.com
Tue Aug 11 06:48:51 PDT 2015
On Monday, 10 August 2015 at 18:23:25 UTC, Sönke Ludwig wrote:
> The main technical reason was CT reflections issues (the
> particular case was that they had always been erroneously
> recognized as input ranges) and the fact that any API change
> involving the Json struct would potentially be a silently
> breaking change. Another thing that I personally always felt
> was that the syntax had the effect of unconsciously hiding
> bugs, because it *looks* like static field access, so your
> brain thinks that the compiler checks for things like spelling
> mistakes.
Aye, good points.
Ideally, I'd love to see statically defined structs for
everything with easy to/from serialization. The serialization
part is easy - the trickier part is getting the right struct
definition.
I started working on an analyzer thing that takes a real world
data sample and creates a struct from it. Actually, my main
reason for doing that was reverse engineering a third party API -
reading a struct definition is easier than reading json IMO - but
it'd have nice benefits for these too.
Most "dynamic" types really are static, you just don't always
know the layout at compile time. But with a bit of ahead-of-time
analyzers of the data, we can basically bridge that without
needing a whole lot of extra work.
More information about the Digitalmars-d-announce
mailing list