-
Notifications
You must be signed in to change notification settings - Fork 117
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Define AbstractQuantity #204
Conversation
Codecov Report
@@ Coverage Diff @@
## master #204 +/- ##
==========================================
+ Coverage 78.94% 79.95% +1.01%
==========================================
Files 14 14
Lines 964 983 +19
==========================================
+ Hits 761 786 +25
+ Misses 203 197 -6
Continue to review full report at Codecov.
|
1 similar comment
Codecov Report
@@ Coverage Diff @@
## master #204 +/- ##
==========================================
+ Coverage 78.94% 79.95% +1.01%
==========================================
Files 14 14
Lines 964 983 +19
==========================================
+ Hits 761 786 +25
+ Misses 203 197 -6
Continue to review full report at Codecov.
|
I've played with this branch in The only thing I would recommend doing is to define an API function ( |
Just wondering - is this just |
Ustrip is defined as @inline ustrip(x::Quantity) = ustrip(x.val) So strictly speaking it doesn't simply access to the val field. However, I'm having difficulties to find a case where the result would be different (maybe a quantity of quantity, whatever it is?) |
Yes I haven't read enough of the internals to know why it's recursive, but it seems like it might have the meaning you want. |
Yeah, anyway I'm not too concerned about that, for me it's sufficient this PR is merged |
I'm late on the explanation but |
Start addressing #186 by defining an
AbstractQuantity
type.I've marked this PR as work-in-progress because I'm not sure I've used the new abstract type wherever it's needed, at least tests pass locally.