Lines Matching refs:SomeValue
498 class SomeValue {
500 SomeValue(void *ptr) : ptr(ptr) {}
515 struct CastInfo<T, SomeValue>
516 : CastIsPossible<T, SomeValue>, NullableValueCastFailed<T>,
517 DefaultDoCastIfPossible<T, SomeValue, CastInfo<T, SomeValue>> {
518 static T doCast(SomeValue v) {
525 Now given the value above ``SomeValue``, maybe we'd like to be able to cast to
531 struct CastInfo<SomeValue, T *>
532 : NullableValueCastFailed<SomeValue>,
533 DefaultDoCastIfPossible<SomeValue, T *, CastInfo<SomeValue, T *>> {
537 static SomeValue doCast(const T *t) {
538 return SomeValue((void *)t);
542 This would enable us to cast from a ``char *`` to a SomeValue, if we wanted to.
553 struct CastInfo<T, SomeValue> : OptionalValueCast<T, SomeValue> {};
555 That cast trait requires that ``T`` is constructible from ``const SomeValue &``
560 SomeValue someVal = ...;
567 Optional<SomeValue> someVal = ...;