Hacker News
new
|
past
|
comments
|
ask
|
show
|
jobs
|
submit
|
jackieooh's comments
login
jackieooh
on Oct 30, 2023
|
parent
|
context
|
next
[–]
| on:
DigiSpark (ATTiny85) – Arduino, C, Rust, build sys...
Problem is that some registers have non-zero default values (swd debug pin functions for example) so the set() function would still need to do a read modify write operation which isn't the theoretically optimal code gen.
GrumpySloth
on Oct 30, 2023
|
parent
|
next
[–]
Then it’s a question of annotating this function with ALWAYS_INLINE and letting the compiler optimise it.
jackieooh
on Sept 30, 2023
|
parent
|
context
|
prev
[–]
| on:
How to convert an enum to string in C++
I'd probably write a quick python script to generate a function/string table in that case (or I could even do it with a vim macro).
signa11
on Sept 30, 2023
|
parent
[–]
and then check that vim-macro in your code-base somewhere ? sure ^^ ... that will work.
Consider applying for YC's Spring batch! Applications are open till Feb 11.
Guidelines
|
FAQ
|
Lists
|
API
|
Security
|
Legal
|
Apply to YC
|
Contact
Search: