Closed amigalemming closed 1 month ago
Sure. Can you implement and submit a PR please; that way it'll get done a lot quicker.
If you can't spare the time, I'll get to this sometime next week, most likely.
@amigalemming
I went for a low-tech solution, adding wrappers directly within SBV. This should simplify the end-user experience, and is definitely the lowest cost:
Let me know if this handles your use case and needs.
I guess you lost interest in this, and looks like the additional API takes care of this problem. Feel free to file another ticket if you run into further issues.
Currently
OptimizeResult
has three constructors that correspond to the three constructors ofOptimizeStyle
. This means, I have to perform a complete case analysis on theOptimizeResult
constructors after anoptmize
although there can be only one constructor.I suggest that instead
optimize
gets a type with a Style record or GADT or TypeFamily, in order to make the result dependent on the Style option, like so: