[SERVER-38572] Allow c++ expressions in default/implicit/validator IDL attributes Created: 12/Dec/18 Updated: 29/Oct/23 Resolved: 14/Dec/18 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | 4.1.7 |
| Type: | Improvement | Priority: | Major - P3 |
| Reporter: | Sara Golemon | Assignee: | Sara Golemon |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||||||
| Backwards Compatibility: | Fully Compatible | ||||||||
| Sprint: | Security 2018-12-17 | ||||||||
| Participants: | |||||||||
| Description |
|
Exapand the definitions of default, implicit, and validator.{gt,lt,gte,lte} to accept either a literal scalar (as they do now), or a dictionary containing "expr: string" and optionally "is_constexpr: bool" If a literal scalar, non-numerics will be encapsulated as needed (current behavior). if a dictionary containing 'expr', that expression will be used without encapsulation. is_constexpr (default true) will also enforce that the expression provided must be evaluable as a constexpr, failing to do so will result in a compile error. |
| Comments |
| Comment by Githook User [ 14/Dec/18 ] |
|
Author: {'username': 'sgolemon', 'email': 'sara.golemon@mongodb.com', 'name': 'Sara Golemon'}Message: |