]> granicus.if.org Git - graphviz/commitdiff
osage layout: remove unnecessary casts
authorMatthew Fernandez <matthew.fernandez@gmail.com>
Sun, 4 Dec 2022 22:25:31 +0000 (14:25 -0800)
committerMatthew Fernandez <matthew.fernandez@gmail.com>
Thu, 8 Dec 2022 01:12:41 +0000 (17:12 -0800)
lib/osage/osageinit.c

index 0c3ef059153e4e2201c9358c31bd998e3116089a..db9f36d9c304092affab66227dd797f0de652636 100644 (file)
@@ -152,7 +152,7 @@ layout (Agraph_t* g, int depth)
        bb.UR.y += p.y;
        EXPANDBB(rootbb, bb);
        if (j < GD_n_cluster(g)) {
-           subg = (Agraph_t*)children[j];
+           subg = children[j];
            GD_bb(subg) = bb;
            if (Verbose > 1) {
                indent (depth);
@@ -160,7 +160,7 @@ layout (Agraph_t* g, int depth)
            }
        }
        else {
-           n = (Agnode_t*)children[j];
+           n = children[j];
            ND_coord(n) = mid_pointf (bb.LL, bb.UR);
            if (Verbose > 1) {
                indent (depth);
@@ -208,7 +208,7 @@ layout (Agraph_t* g, int depth)
      */
     for (j = 0; j < total; j++) {
        if (j < GD_n_cluster(g)) {
-           subg = (Agraph_t*)children[j];
+           subg = children[j];
            bb = GD_bb(subg);
            bb.LL = sub_pointf(bb.LL, rootbb.LL);
            bb.UR = sub_pointf(bb.UR, rootbb.LL);
@@ -219,7 +219,7 @@ layout (Agraph_t* g, int depth)
            }
        }
        else {
-           n = (Agnode_t*)children[j];
+           n = children[j];
            ND_coord(n) = sub_pointf (ND_coord(n), rootbb.LL);
            if (Verbose > 1) {
                indent (depth);