<--- FIXED ---> ./src/sys/tests/linter/testDuplicates.c:3:1: error: Function 'testDuplicatesWithChanges()' does not appear to be used anywhere outside of testDuplicates.c, and can be made static [-fstatic-function-candidate]: 1: #include 2: > 3: PetscErrorCode testDuplicatesWithChanges(PetscInt *a, PetscScalar *b) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 4: { 5: /* no remove */ ./src/sys/tests/linter/testDuplicates.c:10:25: error: Argument number doesn't match for 'b'. Expected '2', found '5' [-fmatching-arg-num]: 8 : PetscAssertPointer(a, 1); 9 : /* no remove */ > 10: PetscAssertPointer(b, 5); ^ 11: /* ~should~ be removed but won't be */ 12: PetscAssertPointer(b, 7); ./src/sys/tests/linter/testDuplicates.c:3:55 Note: 'b' is traceable to argument #2 'b' in enclosing function here: 1: #include 2: > 3: PetscErrorCode testDuplicatesWithChanges(PetscInt *a, PetscScalar *b) ^^^^^^^^^^^^^^ 4: { 5: /* no remove */ ./src/sys/tests/linter/testDuplicates.c:12:25: error: Argument number doesn't match for 'b'. Expected '2', found '7' [-fmatching-arg-num]: 10: PetscAssertPointer(b, 5); 11: /* ~should~ be removed but won't be */ > 12: PetscAssertPointer(b, 7); ^ 13: PetscAssertPointer(b, 3); 14: return 0; ./src/sys/tests/linter/testDuplicates.c:3:55 Note: 'b' is traceable to argument #2 'b' in enclosing function here: 1: #include 2: > 3: PetscErrorCode testDuplicatesWithChanges(PetscInt *a, PetscScalar *b) ^^^^^^^^^^^^^^ 4: { 5: /* no remove */ ./src/sys/tests/linter/testDuplicates.c:13:25: error: Argument number doesn't match for 'b'. Expected '2', found '3' [-fmatching-arg-num]: 11: /* ~should~ be removed but won't be */ 12: PetscAssertPointer(b, 7); > 13: PetscAssertPointer(b, 3); ^ 14: return 0; 15: } ./src/sys/tests/linter/testDuplicates.c:3:55 Note: 'b' is traceable to argument #2 'b' in enclosing function here: 1: #include 2: > 3: PetscErrorCode testDuplicatesWithChanges(PetscInt *a, PetscScalar *b) ^^^^^^^^^^^^^^ 4: { 5: /* no remove */ ./src/sys/tests/linter/testDuplicates.c:17:1: error: Function 'testDuplicatesScoped()' does not appear to be used anywhere outside of testDuplicates.c, and can be made static [-fstatic-function-candidate]: 15: } 16: > 17: PetscErrorCode testDuplicatesScoped(PetscInt *a, PetscScalar *b) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 18: { 19: /* no remove */ ./src/sys/tests/linter/testDuplicates.c:33:1: error: Function 'testDuplicatesDoubleScoped()' does not appear to be used anywhere outside of testDuplicates.c, and can be made static [-fstatic-function-candidate]: 31: } 32: > 33: PetscErrorCode testDuplicatesDoubleScoped(PetscInt *a, PetscScalar *b) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 34: { 35: /* no remove */ ./src/sys/tests/linter/testDuplicates.c:54:1: error: Function 'testNoDuplicatesSwitch()' does not appear to be used anywhere outside of testDuplicates.c, and can be made static [-fstatic-function-candidate]: 52: } 53: > 54: PetscErrorCode testNoDuplicatesSwitch(PetscInt *a, PetscScalar *b, PetscBool cond) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 55: { 56: switch (cond) { ./src/sys/tests/linter/testDuplicates.c:71:1: error: Function 'testDuplicatesNoChangesSwitch()' does not appear to be used anywhere outside of testDuplicates.c, and can be made static [-fstatic-function-candidate]: 69: } 70: > 71: PetscErrorCode testDuplicatesNoChangesSwitch(PetscInt *a, PetscScalar *b, PetscBool cond) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 72: { 73: /* no remove */ ./src/sys/tests/linter/testDuplicates.c:91:1: error: Function 'testNoDuplicatesIfElse()' does not appear to be used anywhere outside of testDuplicates.c, and can be made static [-fstatic-function-candidate]: 89: } 90: > 91: PetscErrorCode testNoDuplicatesIfElse(PetscInt *a, PetscScalar *b, PetscBool cond) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 92: { 93: if (cond) { ./src/sys/tests/linter/testDuplicates.c:105:1: error: Function 'testDuplicatesIfElse()' does not appear to be used anywhere outside of testDuplicates.c, and can be made static [-fstatic-function-candidate]: 103: } 104: > 105: PetscErrorCode testDuplicatesIfElse(PetscInt *a, PetscScalar *b, PetscBool cond) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 106: { 107: /* no remove */ ./src/sys/tests/linter/testDuplicates.c:122:1: error: Function 'testNoDuplicatesIfElseIfElse()' does not appear to be used anywhere outside of testDuplicates.c, and can be made static [-fstatic-function-candidate]: 120: } 121: > 122: PetscErrorCode testNoDuplicatesIfElseIfElse(PetscInt *a, PetscScalar *b, PetscBool cond) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 123: { 124: if (cond) { ./src/sys/tests/linter/testDuplicates.c:8:3: error: Duplicate function found previous identical usage [-fduplicate-function]: 4: { 5: /* no remove */ > 6: PetscAssertPointer(a, 1); ^^^^^^^^^^^^^^^^^^^^^^^^ 7: /* remove */ 8: PetscAssertPointer(a, 1); ./src/sys/tests/linter/testDuplicates.c:23:3: error: Duplicate function found previous identical usage [-fduplicate-function]: 18: { 19: /* no remove */ > 20: PetscAssertPointer(a, 1); ^^^^^^^^^^^^^^^^^^^^^^^^ 21: PetscAssertPointer(b, 2); 22: /* remove */ 23: PetscAssertPointer(a, 1); ./src/sys/tests/linter/testDuplicates.c:24:3: error: Duplicate function found previous identical usage [-fduplicate-function]: 19: /* no remove */ 20: PetscAssertPointer(a, 1); > 21: PetscAssertPointer(b, 2); ^^^^^^^^^^^^^^^^^^^^^^^^ 22: /* remove */ 23: PetscAssertPointer(a, 1); 24: PetscAssertPointer(b, 2); ./src/sys/tests/linter/testDuplicates.c:27:5: error: Duplicate function found previous identical usage [-fduplicate-function]: 18: { 19: /* no remove */ > 20: PetscAssertPointer(a, 1); ^^^^^^^^^^^^^^^^^^^^^^^^ 21: PetscAssertPointer(b, 2); 22: /* remove */ 23: PetscAssertPointer(a, 1); 24: PetscAssertPointer(b, 2); 25: { 26: /* remove */ 27: PetscAssertPointer(a, 1); ./src/sys/tests/linter/testDuplicates.c:28:5: error: Duplicate function found previous identical usage [-fduplicate-function]: 19: /* no remove */ 20: PetscAssertPointer(a, 1); > 21: PetscAssertPointer(b, 2); ^^^^^^^^^^^^^^^^^^^^^^^^ 22: /* remove */ 23: PetscAssertPointer(a, 1); 24: PetscAssertPointer(b, 2); 25: { 26: /* remove */ 27: PetscAssertPointer(a, 1); 28: PetscAssertPointer(b, 2); ./src/sys/tests/linter/testDuplicates.c:39:3: error: Duplicate function found previous identical usage [-fduplicate-function]: 34: { 35: /* no remove */ > 36: PetscAssertPointer(a, 1); ^^^^^^^^^^^^^^^^^^^^^^^^ 37: PetscAssertPointer(b, 2); 38: /* remove */ 39: PetscAssertPointer(a, 1); ./src/sys/tests/linter/testDuplicates.c:40:3: error: Duplicate function found previous identical usage [-fduplicate-function]: 35: /* no remove */ 36: PetscAssertPointer(a, 1); > 37: PetscAssertPointer(b, 2); ^^^^^^^^^^^^^^^^^^^^^^^^ 38: /* remove */ 39: PetscAssertPointer(a, 1); 40: PetscAssertPointer(b, 2); ./src/sys/tests/linter/testDuplicates.c:43:5: error: Duplicate function found previous identical usage [-fduplicate-function]: 34: { 35: /* no remove */ > 36: PetscAssertPointer(a, 1); ^^^^^^^^^^^^^^^^^^^^^^^^ 37: PetscAssertPointer(b, 2); 38: /* remove */ 39: PetscAssertPointer(a, 1); 40: PetscAssertPointer(b, 2); 41: { 42: /* remove */ 43: PetscAssertPointer(a, 1); ./src/sys/tests/linter/testDuplicates.c:44:5: error: Duplicate function found previous identical usage [-fduplicate-function]: 35: /* no remove */ 36: PetscAssertPointer(a, 1); > 37: PetscAssertPointer(b, 2); ^^^^^^^^^^^^^^^^^^^^^^^^ 38: /* remove */ 39: PetscAssertPointer(a, 1); 40: PetscAssertPointer(b, 2); 41: { 42: /* remove */ 43: PetscAssertPointer(a, 1); 44: PetscAssertPointer(b, 2); ./src/sys/tests/linter/testDuplicates.c:48:5: error: Duplicate function found previous identical usage [-fduplicate-function]: 34: { 35: /* no remove */ > 36: PetscAssertPointer(a, 1); ^^^^^^^^^^^^^^^^^^^^^^^^ 37: PetscAssertPointer(b, 2); 38: /* remove */ 39: PetscAssertPointer(a, 1); 40: PetscAssertPointer(b, 2); 41: { 42: /* remove */ 43: PetscAssertPointer(a, 1); 44: PetscAssertPointer(b, 2); 45: } 46: { 47: /* remove */ 48: PetscAssertPointer(a, 1); ./src/sys/tests/linter/testDuplicates.c:49:5: error: Duplicate function found previous identical usage [-fduplicate-function]: 35: /* no remove */ 36: PetscAssertPointer(a, 1); > 37: PetscAssertPointer(b, 2); ^^^^^^^^^^^^^^^^^^^^^^^^ 38: /* remove */ 39: PetscAssertPointer(a, 1); 40: PetscAssertPointer(b, 2); 41: { 42: /* remove */ 43: PetscAssertPointer(a, 1); 44: PetscAssertPointer(b, 2); 45: } 46: { 47: /* remove */ 48: PetscAssertPointer(a, 1); 49: PetscAssertPointer(b, 2); ./src/sys/tests/linter/testDuplicates.c:79:5: error: Duplicate function found previous identical usage [-fduplicate-function]: 72: { 73: /* no remove */ > 74: PetscAssertPointer(a, 1); ^^^^^^^^^^^^^^^^^^^^^^^^ 75: PetscAssertPointer(b, 2); 76: switch (cond) { 77: case PETSC_TRUE: 78: /* remove */ 79: PetscAssertPointer(a, 1); ./src/sys/tests/linter/testDuplicates.c:80:5: error: Duplicate function found previous identical usage [-fduplicate-function]: 73: /* no remove */ 74: PetscAssertPointer(a, 1); > 75: PetscAssertPointer(b, 2); ^^^^^^^^^^^^^^^^^^^^^^^^ 76: switch (cond) { 77: case PETSC_TRUE: 78: /* remove */ 79: PetscAssertPointer(a, 1); 80: PetscAssertPointer(b, 2); ./src/sys/tests/linter/testDuplicates.c:84:5: error: Duplicate function found previous identical usage [-fduplicate-function]: 72: { 73: /* no remove */ > 74: PetscAssertPointer(a, 1); ^^^^^^^^^^^^^^^^^^^^^^^^ 75: PetscAssertPointer(b, 2); 76: switch (cond) { 77: case PETSC_TRUE: 78: /* remove */ 79: PetscAssertPointer(a, 1); 80: PetscAssertPointer(b, 2); 81: break; 82: case PETSC_FALSE: 83: /* remove */ 84: PetscAssertPointer(a, 1); ./src/sys/tests/linter/testDuplicates.c:85:5: error: Duplicate function found previous identical usage [-fduplicate-function]: 73: /* no remove */ 74: PetscAssertPointer(a, 1); > 75: PetscAssertPointer(b, 2); ^^^^^^^^^^^^^^^^^^^^^^^^ 76: switch (cond) { 77: case PETSC_TRUE: 78: /* remove */ 79: PetscAssertPointer(a, 1); 80: PetscAssertPointer(b, 2); 81: break; 82: case PETSC_FALSE: 83: /* remove */ 84: PetscAssertPointer(a, 1); 85: PetscAssertPointer(b, 2); ./src/sys/tests/linter/testDuplicates.c:112:5: error: Duplicate function found previous identical usage [-fduplicate-function]: 106: { 107: /* no remove */ > 108: PetscAssertPointer(a, 1); ^^^^^^^^^^^^^^^^^^^^^^^^ 109: PetscAssertPointer(b, 2); 110: if (cond) { 111: /* remove */ 112: PetscAssertPointer(a, 1); ./src/sys/tests/linter/testDuplicates.c:113:5: error: Duplicate function found previous identical usage [-fduplicate-function]: 107: /* no remove */ 108: PetscAssertPointer(a, 1); > 109: PetscAssertPointer(b, 2); ^^^^^^^^^^^^^^^^^^^^^^^^ 110: if (cond) { 111: /* remove */ 112: PetscAssertPointer(a, 1); 113: PetscAssertPointer(b, 2); ./src/sys/tests/linter/testDuplicates.c:116:5: error: Duplicate function found previous identical usage [-fduplicate-function]: 106: { 107: /* no remove */ > 108: PetscAssertPointer(a, 1); ^^^^^^^^^^^^^^^^^^^^^^^^ 109: PetscAssertPointer(b, 2); 110: if (cond) { 111: /* remove */ 112: PetscAssertPointer(a, 1); 113: PetscAssertPointer(b, 2); 114: } else { 115: /* remove */ 116: PetscAssertPointer(a, 1); ./src/sys/tests/linter/testDuplicates.c:117:5: error: Duplicate function found previous identical usage [-fduplicate-function]: 107: /* no remove */ 108: PetscAssertPointer(a, 1); > 109: PetscAssertPointer(b, 2); ^^^^^^^^^^^^^^^^^^^^^^^^ 110: if (cond) { 111: /* remove */ 112: PetscAssertPointer(a, 1); 113: PetscAssertPointer(b, 2); 114: } else { 115: /* remove */ 116: PetscAssertPointer(a, 1); 117: PetscAssertPointer(b, 2); <--- LEFT --->