[SERVER-22361] Add Fixed width user defined integer literals Created: 29/Jan/16 Updated: 08/Jan/24 Resolved: 10/Jul/19 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | Portability |
| Affects Version/s: | 3.3.1 |
| Fix Version/s: | None |
| Type: | Improvement | Priority: | Minor - P4 |
| Reporter: | Mira Carey | Assignee: | Andrew Morrow (Inactive) |
| Resolution: | Won't Fix | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Sprint: | Dev Tools 2019-07-01, Dev Tools 2019-07-15 |
| Participants: |
| Description |
|
A number of our internal api's, such as safenum, require fixed width integer types. I'd like to consider what adding user defined fixed width integer types might look like. The idea being that one could: 42i64 == static_cast<int64_t>(42LL) 1234u32 == static_cast<uint32_t>(1234UL) etc. Mostly a quality of life issue This is probably blocked on the upgrade to msvc 2015, as vc12 lacks support for user defined literals |
| Comments |
| Comment by Andrew Morrow (Inactive) [ 10/Jul/19 ] |
|
Note that we may get this in the future anyway per http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2018/p1280r0.html |
| Comment by Andrew Morrow (Inactive) [ 10/Jul/19 ] |
|
Per discussion with mira.carey@mongodb.com, we are deciding against doing this. |