| 76 | |
| 77 | template <typename T, typename U> |
| 78 | T zero_extend_cast( |
| 79 | const U val |
| 80 | ) |
| 81 | /*! |
| 82 | requires |
| 83 | - U and T are integral types |
| 84 | ensures |
| 85 | - let ut be a typedef for unsigned_type<U>::type |
| 86 | - return static_cast<T>(static_cast<ut>(val)); |
| 87 | !*/ |
| 88 | { |
| 89 | typedef typename unsigned_type<U>::type ut; |
| 90 | return static_cast<T>(static_cast<ut>(val)); |
| 91 | } |
| 92 | |
| 93 | } |
| 94 |
nothing calls this directly
no outgoing calls
no test coverage detected