Browse Source

Delete dump.sol

Benjamin Lannon 5 years ago
parent
commit
49028ad55d
1 changed files with 0 additions and 42 deletions
  1. 0
    42
      dump.sol

+ 0
- 42
dump.sol View File

@@ -1,42 +0,0 @@
1
-func dump(obj, indent)
2
-	if None == indent then
3
-		indent = 0
4
-		seen = {}
5
-	end
6
-	io.stdout:write(" "*indent)
7
-	if type(obj) == "list" then
8
-		buf = buffer.fromobject(obj)
9
-		addr = buf:address()
10
-		if None != seen[obj] then
11
-			print("...("+addr+")")
12
-			return
13
-		end
14
-		seen[obj] = 1
15
-		print("[")
16
-		for elem in obj do
17
-			dump(elem, indent+2)
18
-		end
19
-		print(" "*indent+"] =("+addr+")")
20
-		return
21
-	end
22
-	if type(obj) == "map" then
23
-		buf = buffer.fromobject(obj)
24
-		addr = buf:address()
25
-		if None != seen[obj] then
26
-			print("...("+addr+")")
27
-			return
28
-		end
29
-		seen[obj] = 1
30
-		print("{")
31
-		for key in obj do
32
-			io.stdout:write(" "*(indent+2))
33
-			prepr(key, ":")
34
-			dump(obj[key], indent+4)
35
-		end
36
-		print(" "*indent+"} =("+addr+")")
37
-		return
38
-	end
39
-	prepr(obj)
40
-end
41
-
42
-dump.closure.seen = {}

Loading…
Cancel
Save