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

py3 do not call cmp() in code of real_mpfi #22258

Closed
fchapoton opened this issue Jan 25, 2017 · 13 comments
Closed

py3 do not call cmp() in code of real_mpfi #22258

fchapoton opened this issue Jan 25, 2017 · 13 comments

Comments

@fchapoton
Copy link
Contributor

as a step to python3

BEWARE: this file will need later a much deeper treatment, because the current behaviour is not possible in python3 (cmp is not the same order as rich comparison)

the current ticket only aims at removing calls to cmp in the code, so that it compiles with cython/python3

CC: @tscrim @jdemeyer @a-andre

Component: python3

Author: Frédéric Chapoton

Branch/Commit: 759ae16

Reviewer: Travis Scrimshaw

Issue created by migration from https://trac.sagemath.org/ticket/22258

@fchapoton fchapoton added this to the sage-7.6 milestone Jan 25, 2017
@fchapoton
Copy link
Contributor Author

Commit: 759ae16

@fchapoton

This comment has been minimized.

@fchapoton
Copy link
Contributor Author

Branch: u/chapoton/22258

@fchapoton
Copy link
Contributor Author

New commits:

759ae16first try of cmp removal in mpfi

@fchapoton

This comment has been minimized.

@fchapoton
Copy link
Contributor Author

comment:3

waiting for the bots

@fchapoton
Copy link
Contributor Author

comment:4

green bot, please review

@tscrim
Copy link
Collaborator

tscrim commented Jan 27, 2017

comment:5

I'm slightly worried about the richcmp(left.__prec, right.__prec, op) doing more precise comparisons than before and would cause a subtle behavior change. Nor am I not completely convinced the doctests cover all the behavior. I won't have time today to add such tests and verify, but I will try to get to this tomorrow (unless someone who is more familiar with interval comparisons verifies this is okay).

@jdemeyer
Copy link

comment:6

Replying to @tscrim:

I'm slightly worried about the richcmp(left.__prec, right.__prec, op) doing more precise comparisons than before and would cause a subtle behavior change.

In this case, the behaviour looks meaningful so it's a change in the good sense.

@fchapoton
Copy link
Contributor Author

comment:7

ping ?

@tscrim
Copy link
Collaborator

tscrim commented Jan 30, 2017

Reviewer: Travis Scrimshaw

@tscrim
Copy link
Collaborator

tscrim commented Jan 30, 2017

comment:8

Okay, then good to go.

@vbraun
Copy link
Member

vbraun commented Feb 2, 2017

Changed branch from u/chapoton/22258 to 759ae16

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

No branches or pull requests

4 participants