Run gofmt

This commit is contained in:
Nigel Tao committed 2022-08-21 21:41:06 +10:00
1 parent 315b2e5262
commit be1f605108
3 files changed
+7 -1

No files matched your search

+3
View File
@@ -1299,8 +1299,11 @@ func init() {
// addXForms modifies table so that, if table[x] == y, then table[y] = y. // addXForms modifies table so that, if table[x] == y, then table[y] = y.
// //
// For example, for the unaryForms table, the explicit entries are like: // For example, for the unaryForms table, the explicit entries are like:
//
// IDPlus: IDXUnaryPlus, // IDPlus: IDXUnaryPlus,
//
// and this function implicitly addes entries like: // and this function implicitly addes entries like:
//
// IDXUnaryPlus: IDXUnaryPlus, // IDXUnaryPlus: IDXUnaryPlus,
func addXForms(table *[nBuiltInSymbolicIDs]ID) { func addXForms(table *[nBuiltInSymbolicIDs]ID) {
implicitEntries := [nBuiltInSymbolicIDs]bool{} implicitEntries := [nBuiltInSymbolicIDs]bool{}
+3
View File
@@ -1057,6 +1057,7 @@ func orOneNegOneNonNeg(neg IntRange, non IntRange) (z IntRange) {
// possible xx in x and yy in y. // possible xx in x and yy in y.
// //
// Algorithm: // Algorithm:
//
// // If the two intervals overlap, the result is the minimum of the two // // If the two intervals overlap, the result is the minimum of the two
// // intervals' maxima. // // intervals' maxima.
// // // //
@@ -1189,11 +1190,13 @@ func (x IntRange) andMax(y IntRange) *big.Int {
// possible xx in x and yy in y. // possible xx in x and yy in y.
// //
// Algorithm: // Algorithm:
//
// droppable = bitFillRight((xMax & ~xMin) | (yMax & ~yMin)) // droppable = bitFillRight((xMax & ~xMin) | (yMax & ~yMin))
// available = xMax & yMax & droppable // available = xMax & yMax & droppable
// return xMax | yMax | (bitFillRight(available) >> 1) // return xMax | yMax | (bitFillRight(available) >> 1)
// //
// If xMin and yMin are both zero, this simplifies to: // If xMin and yMin are both zero, this simplifies to:
//
// available = xMax & yMax // available = xMax & yMax
// return xMax | yMax | (bitFillRight(available) >> 1) // return xMax | yMax | (bitFillRight(available) >> 1)
func (x IntRange) orMax(y IntRange) *big.Int { func (x IntRange) orMax(y IntRange) *big.Int {
+1 -1
View File
@@ -365,7 +365,7 @@ type bitVector []uint8
// zig packs a pair of non-negative integers (i, j) into a single unique // zig packs a pair of non-negative integers (i, j) into a single unique
// non-negative integer, in a zig-zagging pattern: // non-negative integer, in a zig-zagging pattern:
// //
// i=0 i=1 i=2 i=3 i=4 etc // . i=0 i=1 i=2 i=3 i=4 etc
// j=0: 0 1 3 6 10 ... // j=0: 0 1 3 6 10 ...
// j=1: 2 4 7 11 16 ... // j=1: 2 4 7 11 16 ...
// j=2: 5 8 12 17 23 ... // j=2: 5 8 12 17 23 ...