File tree 13 files changed +13
-29
lines changed
13 files changed +13
-29
lines changed Original file line number Diff line number Diff line change @@ -27,19 +27,18 @@ jobs:
27
27
- 'build.zig'
28
28
- 'build.zig.zon'
29
29
- '.github/workflows/ci_zig.yml'
30
- - 'ci/zig-lints .sh'
30
+ - 'ci/zig_lints .sh'
31
31
- uses : dorny/paths-filter@v3
32
32
id : other_filter
33
33
with :
34
- predicate-quantifier : ' every'
35
34
filters : |
36
35
other_than_zig:
37
36
- '**/*'
38
37
- '!src/**'
39
38
- '!build.zig'
40
39
- '!build.zig.zon'
41
40
- '!.github/workflows/ci_zig.yml'
42
- - '!ci/zig-lints .sh'
41
+ - '!ci/zig_lints .sh'
43
42
44
43
call-zig-workflow :
45
44
needs : check-changes
Original file line number Diff line number Diff line change @@ -12,7 +12,12 @@ while read -r file; do
12
12
errors=$( awk '
13
13
/^pub / {
14
14
if (prev !~ /^\/\/\//) {
15
- print FILENAME ":" FNR ": pub declaration without doc comment `///`"
15
+ # Skip doc comment requirements for init, deinit, and @import
16
+ if ($0 !~ /pub.*fn init\(/ &&
17
+ $0 !~ /pub.*fn deinit/ &&
18
+ $0 !~ /pub.*@import/) {
19
+ print FILENAME ":" FNR ": pub declaration without doc comment `///`"
20
+ }
16
21
}
17
22
}
18
23
{ prev = $0 }
Original file line number Diff line number Diff line change @@ -4,20 +4,14 @@ const std = @import("std");
4
4
const parse = @import ("check/parse.zig" );
5
5
const module_work = @import ("base/module_work.zig" );
6
6
7
- /// re-export the S-expression helpers
8
7
pub const sexpr = @import ("base/sexpr.zig" );
9
- /// re-export Ident
10
8
pub const Ident = @import ("base/Ident.zig" );
11
- /// re-export Region
12
9
pub const Region = @import ("base/Region.zig" );
13
- /// re-export Package
14
10
pub const Package = @import ("base/Package.zig" );
15
- /// re-export ModuleEnv
16
11
pub const ModuleEnv = @import ("base/ModuleEnv.zig" );
17
- /// re-export ModuleImport
18
12
pub const ModuleImport = @import ("base/ModuleImport.zig" );
19
- /// re-export StringLiteral
20
13
pub const StringLiteral = @import ("base/StringLiteral.zig" );
14
+
21
15
/// re-export ModuleWork
22
16
pub const ModuleWork = module_work .ModuleWork ;
23
17
/// re-export ModuleWorkIdx
Original file line number Diff line number Diff line change @@ -21,7 +21,6 @@ typed_patterns: Pattern.Typed.List,
21
21
typed_idents : TypedIdent.List ,
22
22
when_branches : WhenBranch.List ,
23
23
24
- /// todo
25
24
pub fn init (env : * base.ModuleEnv ) Self {
26
25
return Self {
27
26
.env = env ,
Original file line number Diff line number Diff line change @@ -18,7 +18,6 @@ stmts: Stmt.List,
18
18
idents_with_layouts : IdentWithLayout.List ,
19
19
list_literal_elems : ListLiteralElem.List ,
20
20
21
- /// todo
22
21
pub fn init (env : * base.ModuleEnv ) Self {
23
22
return Self {
24
23
.env = env ,
@@ -32,7 +31,6 @@ pub fn init(env: *base.ModuleEnv) Self {
32
31
};
33
32
}
34
33
35
- /// todo
36
34
pub fn deinit (self : * Self ) void {
37
35
self .procedures .deinit (self .env .gpa );
38
36
self .constants .deinit (self .env .gpa );
Original file line number Diff line number Diff line change @@ -18,7 +18,6 @@ stmts: Stmt.List,
18
18
idents_with_layouts : IdentWithLayout.List ,
19
19
list_literal_elems : ListLiteralElem.List ,
20
20
21
- /// todo
22
21
pub fn init (env : * base.ModuleEnv ) Self {
23
22
return Self {
24
23
.env = env ,
@@ -32,7 +31,6 @@ pub fn init(env: *base.ModuleEnv) Self {
32
31
};
33
32
}
34
33
35
- /// todo
36
34
pub fn deinit (self : * Self ) void {
37
35
self .procedures .deinit (self .env .gpa );
38
36
self .constants .deinit (self .env .gpa );
Original file line number Diff line number Diff line change @@ -25,14 +25,14 @@ pub const FunctionSet = struct {
25
25
pub const IR = struct {
26
26
env : * base.ModuleEnv ,
27
27
function_sets : FunctionSet.List ,
28
- /// todo
28
+
29
29
pub fn init (env : * base.ModuleEnv ) IR {
30
30
return IR {
31
31
.env = env ,
32
32
.function_sets = .{},
33
33
};
34
34
}
35
- /// todo
35
+
36
36
pub fn deinit (self : * IR ) void {
37
37
self .function_sets .deinit (self .env .gpa );
38
38
}
Original file line number Diff line number Diff line change @@ -21,7 +21,6 @@ typed_patterns: Pattern.Typed.List,
21
21
typed_idents : TypedIdent.List ,
22
22
when_branches : WhenBranch.List ,
23
23
24
- /// todo
25
24
pub fn init (env : * base.ModuleEnv ) Self {
26
25
return Self {
27
26
.env = env ,
@@ -37,7 +36,6 @@ pub fn init(env: *base.ModuleEnv) Self {
37
36
};
38
37
}
39
38
40
- /// todo
41
39
pub fn deinit (self : * Self ) void {
42
40
self .exposed_values .deinit (self .env .gpa );
43
41
self .exposed_functions .deinit (self .env .gpa );
Original file line number Diff line number Diff line change @@ -21,7 +21,6 @@ typed_patterns: Pattern.Typed.List,
21
21
typed_idents : TypedIdent.List ,
22
22
when_branches : WhenBranch.List ,
23
23
24
- /// todo
25
24
pub fn init (env : * base.ModuleEnv ) Self {
26
25
return Self {
27
26
.env = env ,
@@ -37,7 +36,6 @@ pub fn init(env: *base.ModuleEnv) Self {
37
36
};
38
37
}
39
38
40
- /// todo
41
39
pub fn deinit (self : * Self ) void {
42
40
self .exposed_values .deinit (self .env .gpa );
43
41
self .exposed_functions .deinit (self .env .gpa );
Original file line number Diff line number Diff line change @@ -35,7 +35,6 @@ pub fn init(tokens: TokenizedBuffer) Parser {
35
35
};
36
36
}
37
37
38
- /// deninit the parser memory
39
38
pub fn deinit (parser : * Parser ) void {
40
39
parser .scratch_nodes .deinit (parser .gpa );
41
40
parser .diagnostics .deinit (parser .gpa );
Original file line number Diff line number Diff line change @@ -41,7 +41,6 @@ pub fn init(env: *base.ModuleEnv) Self {
41
41
};
42
42
}
43
43
44
- /// deinitialise the IR's memory
45
44
pub fn deinit (self : * Self ) void {
46
45
self .regions .deinit (self .env .gpa );
47
46
self .exprs .deinit (self .env .gpa );
Original file line number Diff line number Diff line change 1
1
/// Utilities for managing collections.
2
2
pub const utils = @import ("collections/utils.zig" );
3
3
4
- /// re-export the SafeList
5
4
pub const SafeList = @import ("collections/safe_list.zig" ).SafeList ;
6
- /// re-export the SafeMultiList
5
+
7
6
pub const SafeMultiList = @import ("collections/safe_list.zig" ).SafeMultiList ;
8
- /// re-export the SmallStringInterner
7
+
9
8
pub const SmallStringInterner = @import ("collections/SmallStringInterner.zig" );
Original file line number Diff line number Diff line change 1
- /// re-export the number primitive types
2
1
pub const num = @import ("types/num.zig" );
3
2
4
- /// re-export the Type primitive
5
3
pub const Type = @import ("types/type.zig" ).Type ;
6
4
7
5
// todo -- we probably don't need this anymmore.. remove in follow-up PR
You can’t perform that action at this time.
0 commit comments