File tree Expand file tree Collapse file tree 1 file changed +3
-0
lines changed Expand file tree Collapse file tree 1 file changed +3
-0
lines changed Original file line number Diff line number Diff line change @@ -54,6 +54,7 @@ pub fn (attrs []Attr) contains(str string) bool {
54
54
return attrs.any (it .name == str)
55
55
}
56
56
57
+ [direct_array_access ]
57
58
pub fn (attrs []Attr) find_first (aname string ) ? Attr {
58
59
for a in attrs {
59
60
if a.name == aname {
@@ -63,6 +64,7 @@ pub fn (attrs []Attr) find_first(aname string) ?Attr {
63
64
return none
64
65
}
65
66
67
+ [direct_array_access ]
66
68
pub fn (attrs []Attr) find_last (aname string ) ? Attr {
67
69
for idx := attrs.len - 1 ; idx > - 1 ; idx-- {
68
70
a := attrs[idx]
@@ -73,6 +75,7 @@ pub fn (attrs []Attr) find_last(aname string) ?Attr {
73
75
return none
74
76
}
75
77
78
+ [direct_array_access ]
76
79
pub fn (attrs []Attr) find_comptime_define () ? int {
77
80
for idx in 0 .. attrs.len {
78
81
if attrs[idx].kind == .comptime_define {
You can’t perform that action at this time.
0 commit comments