File tree Expand file tree Collapse file tree 1 file changed +12
-6
lines changed Expand file tree Collapse file tree 1 file changed +12
-6
lines changed Original file line number Diff line number Diff line change @@ -181,16 +181,22 @@ public CFGExtractor(ASTExtractor astExtractor) {
181
181
this .metrics = astExtractor .getMetrics ();
182
182
}
183
183
184
+ /**
185
+ * Creates an `Iterable<Node>` from the one-or-more nodes contained in `nodes`.
186
+ */
184
187
@ SuppressWarnings ("unchecked" )
185
- private static Iterable <Node > createIterable (Object nd ) {
186
- if (nd == null ) return Collections .<Node >emptySet ();
187
- if (nd instanceof Node ) return CollectionUtil .singletonIterable ((Node ) nd );
188
- return (Iterable <Node >) nd ;
188
+ private static Iterable <Node > createIterable (Object nodes ) {
189
+ if (nodes == null ) return Collections .<Node >emptySet ();
190
+ if (nodes instanceof Node ) return CollectionUtil .singletonIterable ((Node ) nodes );
191
+ return (Iterable <Node >) nodes ;
189
192
}
190
193
191
- private Iterable <Node > createReversedIterable (final Object nd ) {
194
+ /**
195
+ * Creates an `Iterable<Node>` that iterates the nodes in reverse order from the one-or-more nodes contained in `nodes`.
196
+ */
197
+ private Iterable <Node > createReversedIterable (final Object nodes ) {
192
198
List <Node > list = new ArrayList <>();
193
- createIterable (nd ).forEach (list ::add );
199
+ createIterable (nodes ).forEach (list ::add );
194
200
Collections .reverse (list );
195
201
return list ;
196
202
}
You can’t perform that action at this time.
0 commit comments