standalone: Add output_bool in demo library #331

Merged
sb10q merged 2 commits from enhance/add-output-bool-to-demo-lib into master 2023-10-06 10:38:30 +08:00
Collaborator
There is no content yet.
derppening added 1 commit 2023-10-05 12:24:43 +08:00
sb10q reviewed 2023-10-05 16:52:44 +08:00
@ -11,6 +12,10 @@
#error "Unsupported platform - Platform is not 32-bit or 64-bit"
#endif
void output_bool(const bool x) {

const?

const?
Poster
Collaborator

It's just to enforce an immutable-by-default design, similar to how objects in Rust are immutable unless mut is specified.

It's just to enforce an immutable-by-default design, similar to how objects in Rust are immutable unless `mut` is specified.

Sounds like very idiosyncratic and probably ineffective C programming style.

Sounds like very idiosyncratic and probably ineffective C programming style.
Poster
Collaborator

Should I remove it then? It's just stylistic and doesn't change the ABI.

Should I remove it then? It's just stylistic and doesn't change the ABI.

Yes, everywhere.

Yes, everywhere.
derppening added 1 commit 2023-10-06 10:21:48 +08:00
Poster
Collaborator

v2: Rebased against master

v2: Rebased against master
derppening added 1 commit 2023-10-06 10:33:22 +08:00
Poster
Collaborator

v3: Removed most usages of const in demo library, except in some pointer-to-const cases.

v3: Removed most usages of `const` in demo library, except in some pointer-to-const cases.
sb10q merged commit c5629d4eb5 into master 2023-10-06 10:38:30 +08:00
Sign in to join this conversation.
No reviewers
No Milestone
No Assignees
2 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: M-Labs/nac3#331
There is no content yet.