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

Field initialization from strings #62

Open
dtebbs opened this issue Sep 17, 2021 · 0 comments
Open

Field initialization from strings #62

dtebbs opened this issue Sep 17, 2021 · 0 comments

Comments

@dtebbs
Copy link
Contributor

dtebbs commented Sep 17, 2021

Initialization of the form libff::Fr<ppT>("-1") does not behave as expected. It implicitly constructs a bigint("-1") and constructs an Fp_model from this, which obviously does not yield -1 in the prime field.
This can be confusing and time-consuming to track down.

One easy temporary option (which avoids parsing the string) may be to mark all the constructors as explicit, although the implicit conversion may already be used in many places.

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

1 participant