                 count++
                 if let parent = entry.parent {
                     print("(")
-                    print(Term.Red.wrap("\(pad(parent.index, 3)), \(formatPointer(parent.address))@\(pad(entry.parentOffset, 3, align: .Left))"))
+                    print(entryColor(parent).wrap("\(pad(parent.index, 3)), \(formatPointer(parent.address))@\(pad(entry.parentOffset, 3, align: .Left))"))
                     print(") <- ")
                 } else {
                     print("                                 ")
                 }
                 
-                print(pad(entry.index, 3))
-                print(" ")
-                print(formatPointer(entry.address))
+                print(entryColor(entry).wrap("\(pad(entry.index, 3)) \(formatPointer(entry.address))"))
                 print(": ")
                 let pointersAndOffsets = memory.scanPointers()
                 for pointerAndOffset in pointersAndOffsets {

enum Term: String {
    case Default = "39"
    case Red = "31"
    
    func escapeSequence() -> String {
        return "\x1B[\(self.toRaw())m"

//}

func dumpmem<T>(var x: T) {
    func entryColor(entry: ScanEntry) -> Term {
        let entryColors: Term[] = [ .Red, .Green, .Yellow, .Blue, .Magenta, .Cyan ]
        return entryColors[entry.index % entryColors.count]
    }
    
    var count = 0
    var seen = Dictionary<UInt, Bool>()
