Skip to content

Commit

Permalink
Graph
Browse files Browse the repository at this point in the history
- Documented helper methods
  • Loading branch information
deavmi committed May 4, 2024
1 parent c8eacc7 commit b83cadc
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions source/niknaks/containers.d
Original file line number Diff line number Diff line change
Expand Up @@ -813,11 +813,26 @@ public class Graph(T)
return false;
}

/**
* Checks if the given type is
* that of a graph node
*
* Returns: `true` if so, `false`
* otherwise
*/
private static bool isGraphNodeType(E)()
{
return __traits(isSame, E, Graph!(T));
}

/**
* Checks if the given type is
* that of a graph node's value
* type
*
* Returns: `true` if so, `false`
* otherwise
*/
private static bool isGraphValueType(E)()
{
return __traits(isSame, E, T);
Expand Down

0 comments on commit b83cadc

Please sign in to comment.