<commit_before>/* sbt -- Simple Build Tool
 * Copyright 2008 <NAME>
 */
package sbt;

import scala.collection.mutable;

trait Dag[Node <: Dag[Node]]{
	self : Node =>

	def dependencies : Iterable[Node]

	def topologicalSort = {
		val discovered = new mutable.HashSet[Node];
		val finished = new wrap.MutableSetWrapper(new java.util.LinkedHashSet[Node]);

		def visit(dag : Node){
			if (!discovered(dag)) {
				discovered(dag) = true; 
				dag.dependencies.foreach(visit);
				finished += dag;
			}
		}

		visit(self);
	
		finished.toList;
	}
}
<commit_msg>Temporarily revert to using jcl in Dag.<commit_after>/* sbt -- Simple Build Tool
 * Copyright 2008 <NAME>
 */
package sbt;

import scala.collection.mutable;

trait Dag[Node <: Dag[Node]]{
	self : Node =>

	def dependencies : Iterable[Node]

	def topologicalSort = {
		val discovered = new mutable.HashSet[Node];
		val finished = new scala.collection.jcl.LinkedHashSet[Node]//new wrap.MutableSetWrapper(new java.util.LinkedHashSet[Node]);

		def visit(dag : Node){
			if (!discovered(dag)) {
				discovered(dag) = true; 
				dag.dependencies.foreach(visit);
				finished += dag;
			}
		}

		visit(self);
	
		finished.toList;
	}
}

{'fraction_non_alphanumeric': 0.13490725126475547, 'fraction_numerical': 0.006745362563237774, 'mean_word_length': 3.673228346456693, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 7, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7561726', 'n_tokens_mistral': 462, 'n_tokens_neox': 397, 'n_words': 93}