MCPcopy Create free account
hub / github.com/boostorg/build / topological_sort

Function topological_sort

v2/engine/modules/order.c:73–85  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

71
72
73void topological_sort( int * * graph, int num_vertices, int * result )
74{
75 int i;
76 int * colors = ( int * )BJAM_CALLOC( num_vertices, sizeof( int ) );
77 for ( i = 0; i < num_vertices; ++i )
78 colors[ i ] = white;
79
80 for ( i = 0; i < num_vertices; ++i )
81 if ( colors[ i ] == white )
82 do_ts( graph, i, colors, &result );
83
84 BJAM_FREE( colors );
85}
86
87
88LIST * order( FRAME * frame, int flags )

Callers 1

orderFunction · 0.85

Calls 1

do_tsFunction · 0.85

Tested by

no test coverage detected