Skip to content

Commit 85f0f03

Browse files
authored
Implement manual fixes for all of the remaining clippy errors (#1082)
1 parent f1b7c4d commit 85f0f03

File tree

7 files changed

+77
-76
lines changed

7 files changed

+77
-76
lines changed

alan_compiler/src/lntojs/function.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ use crate::lntojs::typen;
88
use crate::parse::{booln, integer, real};
99
use crate::program::{ArgKind, CType, FnKind, Function, Microstatement, Program, Scope};
1010

11+
#[allow(clippy::type_complexity)]
1112
pub fn from_microstatement(
1213
microstatement: &Microstatement,
1314
scope: &Scope,
@@ -1397,6 +1398,7 @@ pub fn from_microstatement(
13971398
}
13981399
}
13991400

1401+
#[allow(clippy::type_complexity)]
14001402
pub fn generate(
14011403
jsname: String,
14021404
function: &Function,

alan_compiler/src/lntojs/typen.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -266,6 +266,7 @@ pub fn ctype_to_jtype(
266266
}
267267
}
268268

269+
#[allow(clippy::type_complexity)]
269270
pub fn generate(
270271
typen: Arc<CType>,
271272
mut out: OrderedHashMap<String, String>,

alan_compiler/src/lntors/function.rs

Lines changed: 2 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ use ordered_hash_map::OrderedHashMap;
77
use crate::lntors::typen;
88
use crate::program::{ArgKind, CType, FnKind, Function, Microstatement, Program, Scope};
99

10+
#[allow(clippy::type_complexity)]
1011
pub fn from_microstatement(
1112
microstatement: &Microstatement,
1213
parent_fn: &Function,
@@ -845,14 +846,12 @@ pub fn from_microstatement(
845846
let (okrustname, d) =
846847
typen::ctype_to_rtype(
847848
ts[0].clone(),
848-
true,
849849
deps,
850850
)?;
851851
deps = d;
852852
let (errrustname, d) =
853853
typen::ctype_to_rtype(
854854
ts[1].clone(),
855-
true,
856855
deps,
857856
)?;
858857
deps = d;
@@ -967,14 +966,12 @@ pub fn from_microstatement(
967966
let (okrustname, d) =
968967
typen::ctype_to_rtype(
969968
ts[0].clone(),
970-
true,
971969
deps,
972970
)?;
973971
deps = d;
974972
let (errrustname, d) =
975973
typen::ctype_to_rtype(
976974
ts[1].clone(),
977-
true,
978975
deps,
979976
)?;
980977
deps = d;
@@ -1159,14 +1156,12 @@ pub fn from_microstatement(
11591156
let (okrustname, d) =
11601157
typen::ctype_to_rtype(
11611158
ts[0].clone(),
1162-
true,
11631159
deps,
11641160
)?;
11651161
deps = d;
11661162
let (errrustname, d) =
11671163
typen::ctype_to_rtype(
11681164
ts[1].clone(),
1169-
true,
11701165
deps,
11711166
)?;
11721167
deps = d;
@@ -1247,14 +1242,12 @@ pub fn from_microstatement(
12471242
let (okrustname, d) =
12481243
typen::ctype_to_rtype(
12491244
ts[0].clone(),
1250-
true,
12511245
deps,
12521246
)?;
12531247
deps = d;
12541248
let (errrustname, d) =
12551249
typen::ctype_to_rtype(
12561250
ts[1].clone(),
1257-
true,
12581251
deps,
12591252
)?;
12601253
deps = d;
@@ -1340,14 +1333,12 @@ pub fn from_microstatement(
13401333
let (okrustname, d) =
13411334
typen::ctype_to_rtype(
13421335
ts[0].clone(),
1343-
true,
13441336
deps,
13451337
)?;
13461338
deps = d;
13471339
let (errrustname, d) =
13481340
typen::ctype_to_rtype(
13491341
ts[1].clone(),
1350-
true,
13511342
deps,
13521343
)?;
13531344
deps = d;
@@ -1468,14 +1459,12 @@ pub fn from_microstatement(
14681459
let (okrustname, d) =
14691460
typen::ctype_to_rtype(
14701461
ts[0].clone(),
1471-
true,
14721462
deps,
14731463
)?;
14741464
deps = d;
14751465
let (errrustname, d) =
14761466
typen::ctype_to_rtype(
14771467
ts[1].clone(),
1478-
true,
14791468
deps,
14801469
)?;
14811470
deps = d;
@@ -1560,14 +1549,12 @@ pub fn from_microstatement(
15601549
let (okrustname, d) =
15611550
typen::ctype_to_rtype(
15621551
ts[0].clone(),
1563-
true,
15641552
deps,
15651553
)?;
15661554
deps = d;
15671555
let (errrustname, d) =
15681556
typen::ctype_to_rtype(
15691557
ts[1].clone(),
1570-
true,
15711558
deps,
15721559
)?;
15731560
deps = d;
@@ -1764,6 +1751,7 @@ pub fn from_microstatement(
17641751
}
17651752
}
17661753

1754+
#[allow(clippy::type_complexity)]
17671755
pub fn generate(
17681756
rustname: String,
17691757
function: &Function,

0 commit comments

Comments
 (0)