2d-inc/Flare-Flutter

deprecate mat2d.sign - folks should use double.sign instead

kevmoo opened this issue · 7 comments

double sign(double value) {
return value > 0.0 ? 1.0 : -1.0;
}

https://api.dartlang.org/stable/2.1.0/dart-core/double/sign.html

Nice, I hadn't seen this was a property. Much cleaner. Thanks!

I've done similar before. "Oh, we have that..."

It's always nice when you do figure it out though, "oh that's smart, and of course I should've seen that..." :D

I referenced the wrong issue (too many issue trackers): 7d646bf

It shouldn't be, but it could be if someone really went out of there way to use that function :) It was intended to be used internally (this was one of the first dart things I wrote). It was one of the first libs I wrote in dart, so yes it shouldn't have been exposed

Oh that’s great, more new things :) thanks