Sha256: 08d86dbe34ad89852637207d4ae2091a5346b9e62ff2002cd844570f1980fcdf
Contents?: true
Size: 552 Bytes
Versions: 387
Compression:
Stored size: 552 Bytes
Contents
import scala.util.parsing.combinator.RegexParsers object Sgf extends RegexParsers { type Tree[A] = Node[A] // to separate the type from the constructor, cf. Haskell's Data.Tree type Forest[A] = List[Tree[A]] case class Node[A](rootLabel: A, subForest: Forest[A] = List()) // A tree of nodes. type SgfTree = Tree[SgfNode] // A node is a property list, each key can only occur once. // Keys may have multiple values associated with them. type SgfNode = Map[String, List[String]] def parseSgf(text: String): Option[SgfTree] = ??? }
Version data entries
387 entries across 387 versions & 1 rubygems