Normalize daw_register guards across all Lua files #49
Labels
No labels
coordination/cross-repo
coordination/needed
effort
large
effort
medium
effort
small
meta/duplicate
meta/planning
meta/wontfix
priority
high
priority
low
priority
medium
session
blocker
session
handover
session
next
status
blocked
status
done
status
in-progress
status
review
status
to-go
type
admin
type
bug
type
config
type
deployment
type
docs
type
enhancement
type
feature
type
handover
type
infrastructure
type
installation
type
maintenance
type
migration
type
research
type
security
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
DAW/daw-lua-common#49
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Problem
While migrating
daw-lua-commontodaw_i18n/v1, review repeatedlyencounters older self-registration guards at the end of Lua files:
The accepted DAW runtime rule is the simpler truthy guard:
This has already been identified for individual files, but checking it
opportunistically during unrelated migrations creates repeated review
noise and risks mixing unrelated changes into other issues.
Goal
Review all Lua source files in
daw-lua-commononce and align everyself-registration guard with the accepted DAW pattern.
This is a repository-wide cleanup pass, separate from the ongoing
daw_i18n/v1migration.Scope
For every Lua source file in the repository:
_G.daw_registeris used,applicable,
_NAME, registration arguments, module return values, andall unrelated behavior,
register themselves,
Accepted form:
Verification
The pass should also confirm that no alternative registration guard
remains, such as:
or other equivalent variants.
Acceptance criteria
daw-lua-commonhas been inspected._G.daw_registerguard.type(_G.daw_register) == "function"guard remains.not previously register themselves.
fragjan code .passes.make testpasses under Lua 5.1 and Lua 5.4.Related
DAW/daw-lua-common#45DAW/daw-lua-common#48DAW/daw-docs#18Done
Verified on main:
and all 21 use the truthy 'if _G.daw_register then' guard.
and lib/).
fs/query, fs/temp, yaml/dump, yaml/parse) did not register before
either, so no new self-registration was introduced.
The base64.lua outlier was fixed as described in
DAW/daw-lua-common#44.