-
Notifications
You must be signed in to change notification settings - Fork 694
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
Consider some suggestions for modifications and additions on 'Numbers in Dart' page #5758
Comments
@munificent , @lrhn or @leafpetersen : Do these changes appear consistent with what we should express in the docs? If so, I'll make these changes. |
What changes are being proposed? This seems more like some kind of general commentary, I'm not sure what is actionable here. |
The change tries to be more precise, but it's probably too cumbersome and detailed to be a good lead-in sentence.
I honestly don't get the point of the original either. Dart has two built-in number types, I'd stop at that.
I'd be vary about pointing to specific third-party packages as if they are specially endorsed by the Dart team.
These are Dart-team provided. Not sure they fit in here, depending on what the goal of the page is. |
Page URL
https://dart.dev/guides/language/numbers/
Page source
https://github.com/dart-lang/site-www/tree/main/src/content/guides/language/numbers.md
Describe the problem
At https://dart.dev/guides/language/numbers, "Numbers in Dart", we read:
I'm not sure this is really right. It seems rather that
We continue:
Suggesting the following, but it may be too complicated. (also, is "fractional values" really a correct term?):
Additional numeric types
At the very end of the page the
BigInt
class andfixnum
package are mentioned:However, it might be of use to refer the reader to other libraries and packages providing numeric types of interest. I have found the following:
BigDecimal
There is no
BigDecimal
in Dart proper, but there is an add-on package for it:"A bugless implementation of BigDecimal in Dart based on Java's BigDecimal."
Rational
There is no
Rational
in Dart proper, but there is an add-on package for it:"This project enable to make computations on rational numbers."
Complex
There is no
Complex
in Dart proper, but there is an add-on package for it:"A representation of a complex number, i.e. a number which has both a real and an imaginary part."
Translated from The Apache Commons Mathematics Library into Dart.
Quaternion
An implementation can be found in
three_dart
, the "Dart 3D library. an easy to use, lightweight, cross-platform, general purpose 3D library."There is another implementation of quaternions in Flutter:
SIMD numeric types
Additionally, there is:
Typed Data
Dart provides the declaration for a library that is meant to provide efficient implementations for certain common datastructures of the form "List" (called "SIMD numeric types")
import 'dart:typed_data';
Expected fix
No response
Additional context
No response
I would like to fix this problem.
The text was updated successfully, but these errors were encountered: