Ticket #1112 (closed enhancement: fixed)

Opened 6 years ago

Last modified 6 years ago

[with patch] Integer.__pow__

Reported by: malb Owned by: somebody
Priority: minor Milestone: sage-2.8.12
Component: basic arithmetic Keywords:
Cc: Work issues:
Report Upstream: Reviewers:
Authors: Merged in:
Dependencies: Stopgaps:

Description

the attached patch makes this work:

sage: pow(10,20,17)
4
sage: pow?
    pow(x, y[, z]) -> number

    With two arguments, equivalent to x**y.  With three arguments,
    equivalent to (x**y) % z, but may be more efficient (e.g. for longs).

this is required such that e.g. the Crypto.RSA module works with SAGE integers.

Attachments

pow.patch Download (1.2 KB) - added by malb 6 years ago.

Change History

Changed 6 years ago by malb

comment:1 Changed 6 years ago by mhansen

  • Summary changed from Integer.__pow__ to [with patch] Integer.__pow__

comment:2 Changed 6 years ago by mabshoff

  • Status changed from new to closed
  • Resolution set to fixed

applied to 2.8.12.rc0

Note: See TracTickets for help on using tickets.