index.html 7.9 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970
  1. <!DOCTYPE html><html lang="en"><head><meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1.0"><meta name="generator" content="rustdoc"><meta name="description" content="API documentation for the Rust `checked` mod in crate `num`."><meta name="keywords" content="rust, rustlang, rust-lang, checked"><title>num::traits::ops::checked - Rust</title><link rel="stylesheet" type="text/css" href="../../../../normalize.css"><link rel="stylesheet" type="text/css" href="../../../../rustdoc.css" id="mainThemeStyle"><link rel="stylesheet" type="text/css" href="../../../../dark.css"><link rel="stylesheet" type="text/css" href="../../../../light.css" id="themeStyle"><script src="../../../../storage.js"></script></head><body class="rustdoc mod"><!--[if lte IE 8]><div class="warning">This old browser is unsupported and will most likely display funky things.</div><![endif]--><nav class="sidebar"><div class="sidebar-menu">&#9776;</div><p class='location'>Module checked</p><div class="sidebar-elems"><div class="block items"><ul><li><a href="#traits">Traits</a></li></ul></div><p class='location'><a href='../../../index.html'>num</a>::<wbr><a href='../../index.html'>traits</a>::<wbr><a href='../index.html'>ops</a></p><script>window.sidebarCurrent = {name: 'checked', ty: 'mod', relpath: '../'};</script><script defer src="../sidebar-items.js"></script></div></nav><div class="theme-picker"><button id="theme-picker" aria-label="Pick another theme!"><img src="../../../../brush.svg" width="18" alt="Pick another theme!"></button><div id="theme-choices"></div></div><script src="../../../../theme.js"></script><nav class="sub"><form class="search-form js-only"><div class="search-container"><input class="search-input" name="search" autocomplete="off" placeholder="Click or press ‘S’ to search, ‘?’ for more options…" type="search"><a id="settings-menu" href="../../../../settings.html"><img src="../../../../wheel.svg" width="18" alt="Change settings"></a></div></form></nav><section id="main" class="content"><h1 class='fqn'><span class='in-band'>Module <a href='../../../index.html'>num</a>::<wbr><a href='../../index.html'>traits</a>::<wbr><a href='../index.html'>ops</a>::<wbr><a class="mod" href=''>checked</a></span><span class='out-of-band'><span id='render-detail'><a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class='inner'>&#x2212;</span>]</a></span><a class='srclink' href='../../../../src/num_traits/ops/mod.rs.html#2' title='goto source code'>[src]</a></span></h1><h2 id='traits' class='section-header'><a href="#traits">Traits</a></h2>
  2. <table>
  3. <tr class=' module-item'>
  4. <td><a class="trait" href="trait.CheckedAdd.html"
  5. title='trait num::traits::ops::checked::CheckedAdd'>CheckedAdd</a></td>
  6. <td class='docblock-short'>
  7. <p>Performs addition that returns <code>None</code> instead of wrapping around on
  8. overflow.</p>
  9. </td>
  10. </tr>
  11. <tr class=' module-item'>
  12. <td><a class="trait" href="trait.CheckedDiv.html"
  13. title='trait num::traits::ops::checked::CheckedDiv'>CheckedDiv</a></td>
  14. <td class='docblock-short'>
  15. <p>Performs division that returns <code>None</code> instead of panicking on division by zero and instead of
  16. wrapping around on underflow and overflow.</p>
  17. </td>
  18. </tr>
  19. <tr class=' module-item'>
  20. <td><a class="trait" href="trait.CheckedMul.html"
  21. title='trait num::traits::ops::checked::CheckedMul'>CheckedMul</a></td>
  22. <td class='docblock-short'>
  23. <p>Performs multiplication that returns <code>None</code> instead of wrapping around on underflow or
  24. overflow.</p>
  25. </td>
  26. </tr>
  27. <tr class=' module-item'>
  28. <td><a class="trait" href="trait.CheckedNeg.html"
  29. title='trait num::traits::ops::checked::CheckedNeg'>CheckedNeg</a></td>
  30. <td class='docblock-short'>
  31. <p>Performs negation that returns <code>None</code> if the result can't be represented.</p>
  32. </td>
  33. </tr>
  34. <tr class=' module-item'>
  35. <td><a class="trait" href="trait.CheckedRem.html"
  36. title='trait num::traits::ops::checked::CheckedRem'>CheckedRem</a></td>
  37. <td class='docblock-short'>
  38. <p>Performs an integral remainder that returns <code>None</code> instead of panicking on division by zero and
  39. instead of wrapping around on underflow and overflow.</p>
  40. </td>
  41. </tr>
  42. <tr class=' module-item'>
  43. <td><a class="trait" href="trait.CheckedShl.html"
  44. title='trait num::traits::ops::checked::CheckedShl'>CheckedShl</a></td>
  45. <td class='docblock-short'>
  46. <p>Performs a left shift that returns <code>None</code> on overflow.</p>
  47. </td>
  48. </tr>
  49. <tr class=' module-item'>
  50. <td><a class="trait" href="trait.CheckedShr.html"
  51. title='trait num::traits::ops::checked::CheckedShr'>CheckedShr</a></td>
  52. <td class='docblock-short'>
  53. <p>Performs a right shift that returns <code>None</code> on overflow.</p>
  54. </td>
  55. </tr>
  56. <tr class=' module-item'>
  57. <td><a class="trait" href="trait.CheckedSub.html"
  58. title='trait num::traits::ops::checked::CheckedSub'>CheckedSub</a></td>
  59. <td class='docblock-short'>
  60. <p>Performs subtraction that returns <code>None</code> instead of wrapping around on underflow.</p>
  61. </td>
  62. </tr></table></section><section id="search" class="content hidden"></section><section class="footer"></section><aside id="help" class="hidden"><div><h1 class="hidden">Help</h1><div class="shortcuts"><h2>Keyboard Shortcuts</h2><dl><dt><kbd>?</kbd></dt><dd>Show this help dialog</dd><dt><kbd>S</kbd></dt><dd>Focus the search field</dd><dt><kbd>↑</kbd></dt><dd>Move up in search results</dd><dt><kbd>↓</kbd></dt><dd>Move down in search results</dd><dt><kbd>↹</kbd></dt><dd>Switch tab</dd><dt><kbd>&#9166;</kbd></dt><dd>Go to active search result</dd><dt><kbd>+</kbd></dt><dd>Expand all sections</dd><dt><kbd>-</kbd></dt><dd>Collapse all sections</dd></dl></div><div class="infos"><h2>Search Tricks</h2><p>Prefix searches with a type followed by a colon (e.g. <code>fn:</code>) to restrict the search to a given type.</p><p>Accepted types are: <code>fn</code>, <code>mod</code>, <code>struct</code>, <code>enum</code>, <code>trait</code>, <code>type</code>, <code>macro</code>, and <code>const</code>.</p><p>Search functions by type signature (e.g. <code>vec -> usize</code> or <code>* -> vec</code>)</p><p>Search multiple things at once by splitting your query with comma (e.g. <code>str,u8</code> or <code>String,struct:Vec,test</code>)</p></div></div></aside><script>window.rootPath = "../../../../";window.currentCrate = "num";</script><script src="../../../../aliases.js"></script><script src="../../../../main.js"></script><script defer src="../../../../search-index.js"></script></body></html>