jump to:all–mastodon–bluesky–lemmy–lobsters–dev–stack–wiki–rss–hn
wwebbit
view: | | |

Tech / Stack Overflow · hot matching “best-practices”

2 shown · updated 5m ago · read only
  1. Ad-hoc, temporary print-based debugging Rust code without new type constraints (stackoverflow.com)stack

    28 points by gspr in stackoverflow.com · 41m ago · stack comments

    Suppose I have some Rust code like fn foo<T>(x: T) { // Complicated function. } that is called from a gazillion places all over my codebase. Suppose, then, that I realize that something is wrong deep within foo . Sometimes, I might want to do some quick print-based debugging wit…
  2. Replace consequential if statements with for loop & switch in C (stackoverflow.com)stack

    20 points by p_a321 in stackoverflow.com · 23h ago · stack comments

    I am trying to refactor code in the most efficient ( and readable ) way. The code will run on an embedded target (ARM Cortex-M4), so code size is important. I have a variable where each bit represents a true/false value, lets say : uint64_t my_boolean_values = 0b1001101110101 Fo…