<--- FIXED ---> -------------------------------------------------------------------------------------------- ./src/sys/tests/linter/testDuplicates.c:10:3: error: Incorrect use of PetscValidIntPointer(), use PetscValidScalarPointer() instead [-fincompatible-function]: 8 : PetscValidIntPointer(a, 1); 9 : /* no remove */ > 10: PetscValidIntPointer(b, 5); ^^^^^^^^^^^^^^^^^^^^^^^^^^ 11: /* ~should~ be removed but won't be */ 12: PetscValidScalarPointer(b, 7); ./src/sys/tests/linter/testDuplicates.c:10:24 Note: Due to 'b' of type 'PetscScalar *' (a.k.a. 'double *') 8 : PetscValidIntPointer(a, 1); 9 : /* no remove */ > 10: PetscValidIntPointer(b, 5); ^ 11: /* ~should~ be removed but won't be */ 12: PetscValidScalarPointer(b, 7); ./src/sys/tests/linter/testDuplicates.c:10:27: error: Argument number doesn't match for 'b'. Expected '2', found '5' [-fmatching-arg-num]: 8 : PetscValidIntPointer(a, 1); 9 : /* no remove */ > 10: PetscValidIntPointer(b, 5); ^ 11: /* ~should~ be removed but won't be */ 12: PetscValidScalarPointer(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:30: error: Argument number doesn't match for 'b'. Expected '2', found '7' [-fmatching-arg-num]: 10: PetscValidIntPointer(b, 5); 11: /* ~should~ be removed but won't be */ > 12: PetscValidScalarPointer(b, 7); ^ 13: PetscValidScalarPointer(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:30: error: Argument number doesn't match for 'b'. Expected '2', found '3' [-fmatching-arg-num]: 11: /* ~should~ be removed but won't be */ 12: PetscValidScalarPointer(b, 7); > 13: PetscValidScalarPointer(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:8:3: error: Duplicate function found previous identical usage [-fduplicate-function]: 4: { 5: /* no remove */ > 6: PetscValidIntPointer(a, 1); ^^^^^^^^^^^^^^^^^^^^^^^^^^ 7: /* remove */ 8: PetscValidIntPointer(a, 1); ./src/sys/tests/linter/testDuplicates.c:23:3: error: Duplicate function found previous identical usage [-fduplicate-function]: 18: { 19: /* no remove */ > 20: PetscValidIntPointer(a, 1); ^^^^^^^^^^^^^^^^^^^^^^^^^^ 21: PetscValidScalarPointer(b, 2); 22: /* remove */ 23: PetscValidIntPointer(a, 1); ./src/sys/tests/linter/testDuplicates.c:24:3: error: Duplicate function found previous identical usage [-fduplicate-function]: 19: /* no remove */ 20: PetscValidIntPointer(a, 1); > 21: PetscValidScalarPointer(b, 2); ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 22: /* remove */ 23: PetscValidIntPointer(a, 1); 24: PetscValidScalarPointer(b, 2); ./src/sys/tests/linter/testDuplicates.c:27:5: error: Duplicate function found previous identical usage [-fduplicate-function]: 18: { 19: /* no remove */ > 20: PetscValidIntPointer(a, 1); ^^^^^^^^^^^^^^^^^^^^^^^^^^ 21: PetscValidScalarPointer(b, 2); 22: /* remove */ 23: PetscValidIntPointer(a, 1); 24: PetscValidScalarPointer(b, 2); 25: { 26: /* remove */ 27: PetscValidIntPointer(a, 1); ./src/sys/tests/linter/testDuplicates.c:28:5: error: Duplicate function found previous identical usage [-fduplicate-function]: 19: /* no remove */ 20: PetscValidIntPointer(a, 1); > 21: PetscValidScalarPointer(b, 2); ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 22: /* remove */ 23: PetscValidIntPointer(a, 1); 24: PetscValidScalarPointer(b, 2); 25: { 26: /* remove */ 27: PetscValidIntPointer(a, 1); 28: PetscValidScalarPointer(b, 2); ./src/sys/tests/linter/testDuplicates.c:39:3: error: Duplicate function found previous identical usage [-fduplicate-function]: 34: { 35: /* no remove */ > 36: PetscValidIntPointer(a, 1); ^^^^^^^^^^^^^^^^^^^^^^^^^^ 37: PetscValidScalarPointer(b, 2); 38: /* remove */ 39: PetscValidIntPointer(a, 1); ./src/sys/tests/linter/testDuplicates.c:40:3: error: Duplicate function found previous identical usage [-fduplicate-function]: 35: /* no remove */ 36: PetscValidIntPointer(a, 1); > 37: PetscValidScalarPointer(b, 2); ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 38: /* remove */ 39: PetscValidIntPointer(a, 1); 40: PetscValidScalarPointer(b, 2); ./src/sys/tests/linter/testDuplicates.c:43:5: error: Duplicate function found previous identical usage [-fduplicate-function]: 34: { 35: /* no remove */ > 36: PetscValidIntPointer(a, 1); ^^^^^^^^^^^^^^^^^^^^^^^^^^ 37: PetscValidScalarPointer(b, 2); 38: /* remove */ 39: PetscValidIntPointer(a, 1); 40: PetscValidScalarPointer(b, 2); 41: { 42: /* remove */ 43: PetscValidIntPointer(a, 1); ./src/sys/tests/linter/testDuplicates.c:44:5: error: Duplicate function found previous identical usage [-fduplicate-function]: 35: /* no remove */ 36: PetscValidIntPointer(a, 1); > 37: PetscValidScalarPointer(b, 2); ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 38: /* remove */ 39: PetscValidIntPointer(a, 1); 40: PetscValidScalarPointer(b, 2); 41: { 42: /* remove */ 43: PetscValidIntPointer(a, 1); 44: PetscValidScalarPointer(b, 2); ./src/sys/tests/linter/testDuplicates.c:48:5: error: Duplicate function found previous identical usage [-fduplicate-function]: 34: { 35: /* no remove */ > 36: PetscValidIntPointer(a, 1); ^^^^^^^^^^^^^^^^^^^^^^^^^^ 37: PetscValidScalarPointer(b, 2); 38: /* remove */ 39: PetscValidIntPointer(a, 1); 40: PetscValidScalarPointer(b, 2); 41: { 42: /* remove */ 43: PetscValidIntPointer(a, 1); 44: PetscValidScalarPointer(b, 2); 45: } 46: { 47: /* remove */ 48: PetscValidIntPointer(a, 1); ./src/sys/tests/linter/testDuplicates.c:49:5: error: Duplicate function found previous identical usage [-fduplicate-function]: 35: /* no remove */ 36: PetscValidIntPointer(a, 1); > 37: PetscValidScalarPointer(b, 2); ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 38: /* remove */ 39: PetscValidIntPointer(a, 1); 40: PetscValidScalarPointer(b, 2); 41: { 42: /* remove */ 43: PetscValidIntPointer(a, 1); 44: PetscValidScalarPointer(b, 2); 45: } 46: { 47: /* remove */ 48: PetscValidIntPointer(a, 1); 49: PetscValidScalarPointer(b, 2); ./src/sys/tests/linter/testDuplicates.c:79:5: error: Duplicate function found previous identical usage [-fduplicate-function]: 72: { 73: /* no remove */ > 74: PetscValidIntPointer(a, 1); ^^^^^^^^^^^^^^^^^^^^^^^^^^ 75: PetscValidScalarPointer(b, 2); 76: switch (cond) { 77: case PETSC_TRUE: 78: /* remove */ 79: PetscValidIntPointer(a, 1); ./src/sys/tests/linter/testDuplicates.c:80:5: error: Duplicate function found previous identical usage [-fduplicate-function]: 73: /* no remove */ 74: PetscValidIntPointer(a, 1); > 75: PetscValidScalarPointer(b, 2); ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 76: switch (cond) { 77: case PETSC_TRUE: 78: /* remove */ 79: PetscValidIntPointer(a, 1); 80: PetscValidScalarPointer(b, 2); ./src/sys/tests/linter/testDuplicates.c:84:5: error: Duplicate function found previous identical usage [-fduplicate-function]: 72: { 73: /* no remove */ > 74: PetscValidIntPointer(a, 1); ^^^^^^^^^^^^^^^^^^^^^^^^^^ 75: PetscValidScalarPointer(b, 2); 76: switch (cond) { 77: case PETSC_TRUE: 78: /* remove */ 79: PetscValidIntPointer(a, 1); 80: PetscValidScalarPointer(b, 2); 81: break; 82: case PETSC_FALSE: 83: /* remove */ 84: PetscValidIntPointer(a, 1); ./src/sys/tests/linter/testDuplicates.c:85:5: error: Duplicate function found previous identical usage [-fduplicate-function]: 73: /* no remove */ 74: PetscValidIntPointer(a, 1); > 75: PetscValidScalarPointer(b, 2); ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 76: switch (cond) { 77: case PETSC_TRUE: 78: /* remove */ 79: PetscValidIntPointer(a, 1); 80: PetscValidScalarPointer(b, 2); 81: break; 82: case PETSC_FALSE: 83: /* remove */ 84: PetscValidIntPointer(a, 1); 85: PetscValidScalarPointer(b, 2); ./src/sys/tests/linter/testDuplicates.c:112:5: error: Duplicate function found previous identical usage [-fduplicate-function]: 106: { 107: /* no remove */ > 108: PetscValidIntPointer(a, 1); ^^^^^^^^^^^^^^^^^^^^^^^^^^ 109: PetscValidScalarPointer(b, 2); 110: if (cond) { 111: /* remove */ 112: PetscValidIntPointer(a, 1); ./src/sys/tests/linter/testDuplicates.c:113:5: error: Duplicate function found previous identical usage [-fduplicate-function]: 107: /* no remove */ 108: PetscValidIntPointer(a, 1); > 109: PetscValidScalarPointer(b, 2); ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 110: if (cond) { 111: /* remove */ 112: PetscValidIntPointer(a, 1); 113: PetscValidScalarPointer(b, 2); ./src/sys/tests/linter/testDuplicates.c:116:5: error: Duplicate function found previous identical usage [-fduplicate-function]: 106: { 107: /* no remove */ > 108: PetscValidIntPointer(a, 1); ^^^^^^^^^^^^^^^^^^^^^^^^^^ 109: PetscValidScalarPointer(b, 2); 110: if (cond) { 111: /* remove */ 112: PetscValidIntPointer(a, 1); 113: PetscValidScalarPointer(b, 2); 114: } else { 115: /* remove */ 116: PetscValidIntPointer(a, 1); ./src/sys/tests/linter/testDuplicates.c:117:5: error: Duplicate function found previous identical usage [-fduplicate-function]: 107: /* no remove */ 108: PetscValidIntPointer(a, 1); > 109: PetscValidScalarPointer(b, 2); ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 110: if (cond) { 111: /* remove */ 112: PetscValidIntPointer(a, 1); 113: PetscValidScalarPointer(b, 2); 114: } else { 115: /* remove */ 116: PetscValidIntPointer(a, 1); 117: PetscValidScalarPointer(b, 2); -------------------------------------------------------------------------------------------- <--- LEFT --->