Skip to content
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

Infinite precision integers should be available, and possibly the default #3279

Closed
1 task
pbiggar opened this issue Nov 28, 2021 · 1 comment
Closed
1 task

Comments

@pbiggar
Copy link
Member

pbiggar commented Nov 28, 2021

Problem: Infinite precision integers are far more useful (lowr complexity) than ones limited to a particular size, as users do not have to deal with overflow or underflow.

The F# v1 integers initially used bigint, however since the behaviour of bigint did not extend to the database, it didn't make sense to switch over fully.

To be Evaluated:

We know how to implement this in the Dark engine, but we do not know how to implement this in the database. It's important that Dark values can be used in the database in much the same manner in which they're used in the runtime. This means we need to be able to implement storage and retrieval in the UserDB, as well as queries using the SQLCompiler. We are currently using postgres 9.6, but intend to migrate to a DB supporting live-migrations such as Google Spanner or CockroachDB.

  • look at our next-gen potential DBs (CockroachDB and Google) and determine if either will support infinite-precision integers

Implementation:

  • the field of EInt, PInt, and DInt should use a bigint (See Remove bigint #3186)
  • check any implicit or explicit int conversions (those raise exception in .NET) (see Remove bigint #3186)
  • the editor handles overflow - this can be removed
  • determine how to support infinite precision integers in our DB
@pbiggar pbiggar changed the title Infinite precision Integers should be Infinite precision Nov 28, 2021
@pbiggar pbiggar removed the v-next label Mar 10, 2023
@pbiggar pbiggar changed the title Integers should be Infinite precision Infinite precision integers should be available, and possibly the default Mar 10, 2023
@StachuDotNet
Copy link
Member

folding this into #5243 for now

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants