replace leading _ for private symbols with keyword hide

This commit is contained in:
2026-07-14 20:19:01 +02:00
parent 5157cf3bcc
commit 267947e79d
31 changed files with 125220 additions and 122709 deletions
+30 -8
View File
@@ -1,14 +1,27 @@
_Thing :: struct {
hide helper func() i32 {
thing Thing = Thing { value = value }
return thing.value
}
hide Thing :: struct {
value i32
}
_value :: 1
_helper func() i32 {
thing _Thing = _Thing { value = _value }
return thing.value
hide Local_Union :: union {
value i32
}
hide Local_Enum :: enum {
value
}
hide Local_Opaque :: opaque
hide Local_Distinct :: distinct i32
hide Local_Alias :: alias i32
hide value :: 1
hide mutable_value i32 = 1
_foreign c_func() i32 {
return 1
}
@@ -17,6 +30,15 @@ _C_Record :: c_struct {
value c_int
}
from_a func() i32 {
return _helper()
hide local_foreign c_func() i32 {
return 1
}
hide Local_C_Record :: c_struct {
value c_int
}
from_a func() i32 {
record Local_C_Record = Local_C_Record { value = 0 }
return helper() + local_foreign() + i32(record.value)
}