Open robrix opened 10 years ago
Would show using Hammer to destructure e.g. a dictionary:
[self addSubview:HMRMatch(petsByName, @[ [HMRPair(HMRAny(), HMRBind(HMRProperty(@"fluffiness", @(ExtremeFluffiness)))) then:^(Pet *pet) { return [PetView petViewWithExtremelyFluffyPet:pet]; }], ])];
Depends on #78 probably.
That pseudocode is illustrating a few things that don’t exist:
HMRBind(…)
Would show using Hammer to destructure e.g. a dictionary:
Depends on #78 probably.