forked from wspace/corpus
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathproject.json
145 lines (145 loc) · 4.89 KB
/
project.json
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
{
"id": "python/smithers888-bluespace",
"name": "BlueSpace",
"authors": ["Christopher Smith"],
"license": "X11",
"languages": ["Python"],
"tags": ["interpreter", "compiler", "assembler", "optimizer", "mapping", "programs"],
"date": "2014-07-10 19:59:10 +0100",
"spec_version": "0.3",
"source": [
"https://github.com/wspace/smithers888-bluespace",
"https://github.com/Smithers888/BlueSpace",
"https://cpjsmith.uk/whitespace",
"https://github.com/thaliaarchi/repo-archival/blob/main/scripts/wspace/smithers888-bluespace.sh"
],
"whitespace": { "extension": "ws" },
"assembly": {
"mnemonics": {
"push": ["Push"],
"dup": ["Duplicate"],
"copy": ["Copy"],
"swap": ["Swap"],
"drop": ["Discard"],
"slide": ["Slide"],
"add": ["Add"],
"sub": ["Subtract"],
"mul": ["Multiply"],
"div": ["Divide"],
"mod": ["Modulo"],
"store": ["Store"],
"retrieve": ["Retrieve"],
"label": ["Label"],
"call": ["Call"],
"jmp": ["Jump"],
"jz": ["JumpZero"],
"jn": ["JumpNegative"],
"ret": ["Return"],
"end": ["End"],
"printc": ["OutputChar"],
"printi": ["OutputNum"],
"readc": ["ReadChar"],
"readi": ["ReadNum"]
},
"case_sensitive_mnemonics": false,
"line_comments": ["#"],
"indentation": "",
"label_indentation": "",
"usage": ["assembler", "programs"],
"extension": "wsa"
},
"mappings": [{ "space": "s", "tab": "t", "lf": "n", "extension": "wsp" }],
"programs": [
{ "path": "programs/99.wsp" },
{ "path": "programs/quine-cs-3.wsa", "generated": "programs/quine-cs-3.ws", "spec_version": "0.3" },
{ "path": "programs/quine-cs.wsa", "generated": "programs/quine-cs.ws", "spec_version": "0.2" },
{ "path": "test/calc.ws", "equivalent": "calc.ws", "spec_version": "0.2" },
{
"path": "test/count.wsp",
"generated": "test/count.ws",
"outputs": ["test/count.out"],
"equivalent": "count.ws",
"spec_version": "0.2"
},
{ "path": "test/fact.ws", "equivalent": "fact.ws", "spec_version": "0.2" },
{
"path": "test/hanoi.wsa",
"generated": "test/hanoi.ws",
"outputs": ["test/hanoi.out"],
"aux": ["test/hanoi.wsp"],
"equivalent": "hanoi.ws",
"spec_version": "0.2"
},
{
"path": "test/hworld.ws",
"outputs": ["test/hworld.out"],
"equivalent": "hworld.ws",
"spec_version": "0.2"
},
{
"path": "test/loctest.wsa",
"generated": "test/loctest.ws",
"outputs": ["test/loctest.out"],
"equivalent": "loctest.ws",
"spec_version": "0.3"
},
{
"path": "test/name.ws",
"outputs": ["test/name.out"],
"equivalent": "name.ws",
"spec_version": "0.2"
}
],
"commands": [
{
"type": "interpreter",
"bin": "bspace.py",
"usage": "<file>",
"options": [
{ "short": "h", "long": "help", "desc": "show this help message and exit" },
{ "short": "v", "long": "version", "desc": "print version information and exit" },
{
"short": "i",
"long": "input",
"arg": "SYNTAX",
"type": "enum",
"desc": "choose the input syntax",
"values": [
{ "values": ["whitespace"], "desc": "Whitespace syntax (default)" },
{ "values": ["printable"], "desc": "printable syntax" },
{ "values": ["assembly"], "desc": "Whitespace assembly syntax" }
]
},
{
"short": "c",
"long": "convertto",
"arg": "TARGET",
"type": "enum",
"desc": "choose the target format",
"values": [
{ "values": ["whitespace"], "desc": "convert to Whitespace syntax" },
{ "values": ["printable"], "desc": "convert to printable syntax" },
{ "values": ["assembly"], "desc": "convert to Whitespace assembly syntax" },
{ "values": ["python"], "desc": "compile to Python 3 source" },
{ "values": ["optimised"], "desc": "compile to Python 3 source with optimizations" }
]
},
{
"short": "r",
"long": "run",
"arg": "MODE",
"type": "enum",
"desc": "interpret program",
"values": [
{ "values": ["interpret"], "desc": "interpret Whitespace code directly (default)" },
{ "values": ["python"], "desc": "compile to Python 3 source and evaluate" },
{ "values": ["optimised"], "desc": "compile to Python 3 source with optimizations and evaluate" }
]
}
],
"option_parse": "Python argparse",
"notes": "Reads program from stdin if <file> is -"
}
],
"notes": "Mapping has spaces between opcode and param and each instruction is on a separate line. Assembly string parameters are written with s/t/l. Date is from quine-cs.ws Last-Modified, in BST to match commits."
}