From: Matthew Fernandez Date: Sat, 24 Apr 2021 04:05:37 +0000 (-0700) Subject: squash -Wshadow warning in Import_coord_clusters_from_dot X-Git-Tag: 2.47.2~13^2~12 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=a68f3dc7abd51d355225be16887dc550ea928766;p=graphviz squash -Wshadow warning in Import_coord_clusters_from_dot Similar to a prior change, there was a nested variable also called sz. By removing this sz, we not only squash a compiler warning but make the code more readable. --- diff --git a/lib/sparse/DotIO.c b/lib/sparse/DotIO.c index 3be1df79c..7425b1c20 100644 --- a/lib/sparse/DotIO.c +++ b/lib/sparse/DotIO.c @@ -734,7 +734,6 @@ SparseMatrix Import_coord_clusters_from_dot(Agraph_t* g, int maxcluster, int dim real* val; real v; int type = MATRIX_TYPE_REAL; - size_t sz = sizeof(real); char scluster[100]; float ff; @@ -819,7 +818,8 @@ SparseMatrix Import_coord_clusters_from_dot(Agraph_t* g, int maxcluster, int dim i++; } } - A = SparseMatrix_from_coordinate_arrays(nedges, nnodes, nnodes, I, J, val, type, sz); + A = SparseMatrix_from_coordinate_arrays(nedges, nnodes, nnodes, I, J, val, + type, sizeof(real)); /* get clustering info */ *clusters = MALLOC(sizeof(int)*nnodes);