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
Crystal just had this commit which adds in an HTTP::Status enum. Lucky has this defined, but it's missing my favorite status 418. I think we should just use the built in crystal one after crystal 0.28.0 is released.
The cool thing too, is the next version of crystal will give us compile time deprecation notices. I haven't tried this, but I think we could do something like:
@[Deprecated("Lucky::Action::Status deprecated, please use HTTP::Status instead")]
aliasStatus=HTTP::Status
The text was updated successfully, but these errors were encountered:
Ok, so this one might be a little tricky. It's not as simple as just doing an alias because of the casing, and crystal enums treat different casing as different values.
Also, apparently the @[Deprecated] annotation only works on methods. As far as I know, there's not a way to log out a deprecation warning when calling individual enums.
So my suggestion is to hard flip these over. It would be a complete breaking change; however, we changed the mime type thing that was also a breaking change anyway.
Crystal just had this commit which adds in an
HTTP::Status
enum. Lucky has this defined, but it's missing my favorite status 418. I think we should just use the built in crystal one after crystal 0.28.0 is released.The cool thing too, is the next version of crystal will give us compile time deprecation notices. I haven't tried this, but I think we could do something like:
The text was updated successfully, but these errors were encountered: