Skip to content

Commit 0fe958e

Browse files
authored
add Tact language (#600)
* add Tact language * fix complexitychecks
1 parent 787e82d commit 0fe958e

File tree

5 files changed

+57
-4
lines changed

5 files changed

+57
-4
lines changed

LANGUAGES.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -280,6 +280,7 @@ Swift (swift)
280280
Swig (i)
281281
Systemd (automount,device,link,mount,path,scope,service,slice,socket,swap,target,timer)
282282
SystemVerilog (sv,svh)
283+
Tact (tact)
283284
TaskPaper (taskpaper)
284285
TCL (tcl)
285286
Teal (teal)

SCC-OUTPUT-REPORT.html

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
<th>431</th>
1919
<th>7551</th>
2020
<th>1384</th>
21-
<th>253787</th>
21+
<th>253871</th>
2222
<th>4065</th>
2323
</tr><tr>
2424
<td>processor/workers_test.go</td>
@@ -268,7 +268,7 @@
268268
<td>1</td>
269269
<td>4</td>
270270
<td>0</td>
271-
<td>23755</td>
271+
<td>23839</td>
272272
<td>6</td>
273273
</tr></tbody>
274274
<tfoot><tr>
@@ -279,7 +279,7 @@
279279
<th>431</th>
280280
<th>7551</th>
281281
<th>1384</th>
282-
<th>253787</th>
282+
<th>253871</th>
283283
<th>4065</th>
284284
</tr>
285285
<tr>

examples/language/tact.tact

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
// 20 lines 12 code 4 comments 4 blanks
2+
3+
import "@stdlib/ownable"; // comment
4+
5+
/* comment */
6+
fun global() {
7+
let str: String = "\n \r \t \u1234 \xFF // /* ... */";
8+
9+
// comment
10+
while (true) { // comment
11+
if /* comment */ (true) { /* comment */ }
12+
}
13+
}
14+
15+
// "quoted"
16+
struct St { /* " */
17+
field1: Int; // /*
18+
field2: Int as uint128;
19+
field3: Int; // */
20+
}

languages.json

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6523,6 +6523,38 @@
65236523
}
65246524
]
65256525
},
6526+
"Tact": {
6527+
"complexitychecks": [
6528+
"if ",
6529+
"if(",
6530+
"else ",
6531+
"try ",
6532+
"catch ",
6533+
"catch(",
6534+
"repeat ",
6535+
"repeat(",
6536+
"while ",
6537+
"while(",
6538+
"do ",
6539+
"until ",
6540+
"until(",
6541+
"foreach ",
6542+
"foreach(",
6543+
"|| ",
6544+
"&& ",
6545+
"!= ",
6546+
"== "
6547+
],
6548+
"extensions": ["tact"],
6549+
"line_comment": ["//", "///"],
6550+
"multi_line": [["/*", "*/"]],
6551+
"quotes": [
6552+
{
6553+
"end": "\"",
6554+
"start": "\""
6555+
}
6556+
]
6557+
},
65266558
"TaskPaper": {
65276559
"complexitychecks": [],
65286560
"extensions": ["taskpaper"],

0 commit comments

Comments
 (0)