Hacker News new | ask | show | jobs
by aithrowawaycomm 599 days ago
I am working on an SDL project (not in Rust) and this example made the molehill seem slightly larger:

  // whoops, accidentally commented out or deleted this import
  // use crate::{SOME_GL_CONSTANT, OTHER_THING}

  // uh oh!
  match value {
   SOME_GL_CONSTANT => ..,
   OTHER_THING => ..,
   _ => ..,
  }
Specifically, I think FFI stuff or an initial Rust rewrite can be a strong incentive to (locally) disable compiler/linter warnings around capitalization because you are more interested in consistency with an existing C API. This turns the molehill into at least a real hill (though not a mountain).