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

Resolve error[E0277]: cannot multiply <P as ModelParameters>::BaseField by <T as AffineCurve>::BaseField` #2

Closed
drskalman opened this issue Aug 31, 2021 · 0 comments
Assignees

Comments

@drskalman
Copy link
Collaborator

SWU_Params is defined as SWModelParameters
MapToCurve depends on AffineCurve

I need to generate the AffineCurve which MapToCurves dependes on out of SWU_param. I might not
need to actually generate the curve but I need the type at least. I don't need to generate the curve,
because Daira's code doesn't require curve operation and it is all in term of elementary algebaric operation
or FiniteField operation.

At least one way, that ArkWork does it is through GroupAffine. AffineCurve has been implemented for GroupAffine<P: SWModelParameters>

impl<P: Parameters> AffineCurve for GroupAffine<P> {

so it makes sense to talk about GroupAffine

as AffineCurve but GroupAffine is a struct. I'd have prefered something like

trait <P: SWModelParameters> SWAffineCurve<P> : AffineCurve

then I could have had

impl <P: SWAffineCurve> MapToCurve<SWAffineCurve<P> as AffineCurve> for SW_hasher<{

Maybe still I can do that with GroupAffine

because struct can be regarded as trait

@drskalman drskalman self-assigned this Aug 31, 2021
drskalman added a commit that referenced this issue Aug 31, 2021
Pratyush pushed a commit that referenced this issue Jun 19, 2024
…rkworks-rs#835)

* revert a9b2dea

* fix the missing feature flag

* add the rayon dependency

---------

Co-authored-by: weikengchen <w.k@berkeley.edu>
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