avoid non-ASCII chars
Karel Miko
8 years ago
8 | 8 | * guarantee it works. |
9 | 9 | */ |
10 | 10 | |
11 | /* Tonelli–Shanks algorithm | |
11 | /* Tonelli-Shanks algorithm | |
12 | 12 | * https://en.wikipedia.org/wiki/Tonelli%E2%80%93Shanks_algorithm |
13 | 13 | * https://gmplib.org/list-archives/gmp-discuss/2013-April/005300.html |
14 | 14 | * |
45 | 45 | goto cleanup; |
46 | 46 | } |
47 | 47 | |
48 | /* NOW: Tonelli–Shanks algorithm */ | |
48 | /* NOW: Tonelli-Shanks algorithm */ | |
49 | 49 | |
50 | 50 | /* factor out powers of 2 from prime-1, defining Q and S as: prime-1 = Q*2^S */ |
51 | 51 | if ((res = mp_copy(prime, &Q)) != MP_OKAY) goto cleanup; |