CNORXZ
Container with Native Operation Routines and Expressions
Loading...
Searching...
No Matches
pos_type.cc.h
Go to the documentation of this file.
1// -*- C++ -*-
12#ifndef __cxz_pos_type_cc_h__
13#define __cxz_pos_type_cc_h__
14
15#include "pos_type.h"
16#include "vpos_type.h"
17
18namespace CNORXZ
19{
20
21 /*==========+
22 | SPos |
23 +==========*/
24
25 template <SizeT N>
26 constexpr SizeT SPos<N>::size() const
27 {
28 return 1;
29 }
30
31 template <SizeT N>
32 constexpr SizeT SPos<N>::val() const
33 {
34 return N;
35 }
36
37 template <SizeT N>
38 template <SizeT N1>
39 constexpr auto SPos<N>::operator+(const SPos<N1>& a) const
40 {
41 return SPos<N+N1>();
42 }
43
44 template <SizeT N>
45 template <SizeT N1>
46 constexpr auto SPos<N>::operator-(const SPos<N1>& a) const
47 {
48 return SPos<N-N1>();
49 }
50
51 template <SizeT N>
52 template <SizeT N1>
53 constexpr auto SPos<N>::operator*(const SPos<N1>& a) const
54 {
55 return SPos<N*N1>();
56 }
57
58 template <SizeT N>
59 template <SizeT N1>
60 constexpr auto SPos<N>::operator()(const SPos<N1>& a) const
61 {
62 return SPos<N*N1>();
63 }
64
65 template <SizeT N>
66 constexpr auto SPos<N>::operator+(const UPos& a) const
67 {
68 return UPos(N+a.val());
69 }
70
71 template <SizeT N>
72 constexpr auto SPos<N>::operator*(const UPos& a) const
73 {
74 if constexpr(N == 0){
75 return SPos<0>();
76 }
77 else {
78 return UPos(N*a.val());
79 }
80 }
81
82 template <SizeT N>
83 constexpr auto SPos<N>::operator()(const UPos& a) const
84 {
85 if constexpr(N == 0){
86 return SPos<0>();
87 }
88 else {
89 return UPos(N*a.val());
90 }
91 }
92
93 template <SizeT N>
94 template <class PosT>
95 constexpr decltype(auto) SPos<N>::extend(const PosT& a) const
96 {
97 return MPos<SPos<N>,PosT>(*this,a);
98 }
99
100 template <SizeT N>
101 template <class PosT>
102 constexpr decltype(auto) SPos<N>::operator<<(const PosT& a) const
103 {
104 return extend(a);
105 }
106
107 template <SizeT N>
108 constexpr SPos<N>::operator UPos() const
109 {
110 return UPos(N);
111 }
112
113 template <SizeT N>
114 constexpr SPos<N>::operator SizeT() const
115 {
116 return val();
117 }
118
119 /*==========+
120 | UPos |
121 +==========*/
122
123 constexpr UPos::UPos(SizeT ext) : mExt(ext) {}
124
125 constexpr SizeT UPos::size() const
126 {
127 return 1;
128 }
129
130 constexpr const SizeT& UPos::val() const
131 {
132 return mExt;
133 }
134
135 template <class PosT>
136 constexpr UPos UPos::operator+(const PosT& in) const
137 {
138 return UPos(mExt + in.val());
139 }
140
141 template <class PosT>
142 constexpr UPos UPos::operator-(const PosT& in) const
143 {
144 return UPos(mExt - in.val());
145 }
146
147 constexpr SPos<0> UPos::operator*(const SPos<0>& a) const
148 {
149 return SPos<0>();
150 }
151
152 template <class PosT>
153 constexpr UPos UPos::operator*(const PosT& in) const
154 {
155 return UPos(mExt * in.val());
156 }
157
158 constexpr SPos<0> UPos::operator()(const SPos<0>& a) const
159 {
160 return SPos<0>();
161 }
163 template <class PosT>
164 constexpr UPos UPos::operator()(const PosT& in) const
165 {
166 return UPos(mExt * in.val());
168
169 template <class PosT>
170 constexpr decltype(auto) UPos::extend(const PosT& p1) const
171 {
172 return MPos<UPos,PosT>(*this, p1);
174
175 template <class PosT>
176 constexpr decltype(auto) UPos::operator<<(const PosT& a) const
177 {
178 return extend(a);
180
181 constexpr UPos::operator SizeT() const
182 {
183 return val();
184 }
185
186 /*==========+
187 | FPos |
188 +==========*/
189
190 inline FPos::FPos(SizeT ext, const SizeT* map) : mExt(ext), mMap(map) {}
191
192 constexpr SizeT FPos::size() const
193 {
194 return 1;
195 }
196
197 constexpr const SizeT& FPos::val() const
198 {
199 return mExt;
200 }
201
202 template <class PosT1>
203 constexpr UPos FPos::operator+(const PosT1& a) const
204 {
205 return UPos(mExt + a.val());
206 }
207
208 template <class PosT>
209 constexpr FPos FPos::operator*(const PosT& in) const
210 {
211 return FPos(mExt * in.val(), mMap);
212 }
213
214 template <class PosT1>
215 constexpr UPos FPos::operator()(const PosT1& a) const
216 {
217 return UPos(mExt * mMap[a.val()]);
218 }
219
220 template <class PosT>
221 constexpr decltype(auto) FPos::extend(const PosT& a) const
222 {
223 return MPos<FPos,PosT>(*this,a);
224 }
225
226 template <class PosT>
227 constexpr decltype(auto) FPos::operator<<(const PosT& a) const
228 {
229 return extend(a);
230 }
231
232 constexpr FPos::operator SizeT() const
233 {
234 return val();
235 }
236
237 /*===========+
238 | SFPos |
239 +===========*/
240
241 template <SizeT N, SizeT... Ms>
242 Arr<SizeT,sizeof...(Ms)> SFPos<N,Ms...>::sMs = { Ms... };
243
244 template <SizeT N, SizeT... Ms>
245 constexpr SizeT SFPos<N,Ms...>::size() const
246 {
247 return 1;
248 }
249
250 template <SizeT N, SizeT... Ms>
251 constexpr SizeT SFPos<N,Ms...>::val() const
252 {
253 return N;
254 }
255
256 template <SizeT N, SizeT... Ms>
257 template <SizeT N1>
258 constexpr auto SFPos<N,Ms...>::operator+(const SPos<N1>& a) const
259 {
260 return SPos<N+N1>();
261 }
262
263 template <SizeT N, SizeT... Ms>
264 template <SizeT N1>
265 constexpr auto SFPos<N,Ms...>::operator*(const SPos<N1>& a) const
266 {
267 return SFPos<N*N1,Ms...>();
268 }
269
270 template <SizeT N, SizeT... Ms>
271 template <SizeT N1>
272 constexpr auto SFPos<N,Ms...>::operator()(const SPos<N1>& a) const
273 {
274 constexpr Arr<SizeT,sizeof...(Ms)> ms({ Ms... });
275 return SPos<N*std::get<a.val()>(ms)>();
276 }
277
278 template <SizeT N, SizeT... Ms>
279 constexpr auto SFPos<N,Ms...>::operator+(const UPos& a) const
280 {
281 return UPos(N + a.val());
282 }
283
284 template <SizeT N, SizeT... Ms>
285 constexpr auto SFPos<N,Ms...>::operator*(const UPos& a) const
286 {
287 return FPos(N * a.val(), &sMs[0]);
288 }
289
290 template <SizeT N, SizeT... Ms>
291 constexpr auto SFPos<N,Ms...>::operator()(const UPos& a) const
292 {
293 constexpr Arr<SizeT,sizeof...(Ms)> ms({ Ms... });
294 return UPos(N * ms[a.val()]);
295 }
296
297 template <SizeT N, SizeT... Ms>
298 template <class PosT>
299 constexpr decltype(auto) SFPos<N,Ms...>::extend(const PosT& a) const
300 {
301 return MPos<SFPos<N,Ms...>,PosT>(*this,a);
302 }
303
304 template <SizeT N, SizeT... Ms>
305 template <class PosT>
306 constexpr decltype(auto) SFPos<N,Ms...>::operator<<(const PosT& a) const
307 {
308 return extend(a);
309 }
310
311 template <SizeT N, SizeT... Ms>
312 constexpr SFPos<N,Ms...>::operator FPos() const
313 {
314 return FPos(N, &sMs[0]);
315 }
316
317 template <SizeT N, SizeT... Ms>
318 constexpr SFPos<N,Ms...>::operator SizeT() const
319 {
320 return val();
321 }
322
323 /*==========+
324 | MPos |
325 +==========*/
326
327 template <class BPosT, class NPosT>
329 {
331 "MPos has to be derived from scalar pos type");
332 }
333
334 template <class BPosT, class NPosT>
335 constexpr MPos<BPosT,NPosT>::MPos(const BPosT& b, const NPosT& n) :
336 BPosT(b), mNext(n)
337 {
339 "MPos has to be derived from scalar pos type");
340 }
341
342 template <class BPosT, class NPosT>
343 template <typename... Args>
344 constexpr MPos<BPosT,NPosT>::MPos(Args&&... args, const NPosT& next) :
345 BPosT(args...), mNext(next)
346 {
348 "MPos has to be derived from scalar pos type");
349 }
350
351 template <class BPosT, class NPosT>
352 template <typename... Args>
353 constexpr MPos<BPosT,NPosT>::MPos(Args&&... args, NPosT&& next) :
354 BPosT(args...), mNext(next)
355 {
357 "MPos has to be derived from scalar pos type");
358 }
359
360 template <class BPosT, class NPosT>
362 {
363 return BPosT::size() + mNext.size();
364 }
365
366 template <class BPosT, class NPosT>
367 constexpr const NPosT& MPos<BPosT,NPosT>::next() const
368 {
369 return mNext;
370 }
371
372 template <class BPosT, class NPosT>
373 template <class PosT>
374 constexpr auto MPos<BPosT,NPosT>::operator+(const PosT& a) const
375 {
376 typedef decltype(BPosT::operator+(a)) OBPosT;
377 typedef decltype(mNext + a.next()) ONPosT;
378 return MPos<OBPosT,ONPosT>( BPosT::operator+(a), mNext + a.next() );
379 }
380
381 template <class BPosT, class NPosT>
382 template <class PosT>
383 constexpr auto MPos<BPosT,NPosT>::operator*(const PosT& a) const
384 {
385 typedef decltype(BPosT::operator*(a)) OBPosT;
386 typedef decltype(mNext * a) ONPosT;
387 return MPos<OBPosT,ONPosT>( BPosT::operator*(a), mNext * a );
388 }
389
390 template <class BPosT, class NPosT>
391 template <class PosT>
392 constexpr auto MPos<BPosT,NPosT>::operator()(const PosT& a) const
393 {
394 typedef decltype(BPosT::operator()(a)) OBPosT;
395 typedef decltype(mNext(a)) ONPosT;
396 return MPos<OBPosT,ONPosT>( BPosT::operator()(a), mNext(a) );
397 }
398
399 template <class BPosT, class NPosT>
400 template <class PosT>
401 constexpr decltype(auto) MPos<BPosT,NPosT>::extend(const PosT& a) const
402 {
403 typedef decltype(mNext.extend(a)) ONPosT;
404 return MPos<BPosT,ONPosT>(*this, mNext.extend(a));
405 }
406
407 template <class BPosT, class NPosT>
408 template <class PosT>
409 constexpr decltype(auto) MPos<BPosT,NPosT>::operator<<(const PosT& a) const
410 {
411 return extend(a);
412 }
413
414 /*==========+
415 | DPos |
416 +==========*/
417
420 {}
421
422 inline DPos::DPos(const DPosRef& a) :
423 ObjHandle<VPosBase>(std::forward<Uptr<VPosBase>>(a.vpos()->copy()))
424 {}
425
426 template <class PosT>
427 inline DPos::DPos(const PosT& a) :
429 (std::make_unique<VPos<typename std::remove_reference<PosT>::type>>(a))
430 {
432 "DPos can only be constructed from pos types");
433 }
434
435 template <class PosT>
436 inline DPos::DPos(PosT&& a) :
438 (std::make_unique<VPos<typename std::remove_reference<PosT>::type>>(a))
439 {
441 "DPos can only be constructed from pos types");
442 }
443
444 inline const VPosBase* DPos::get() const
445 {
446 return mC->vget();
447 }
448
449 inline const VPosBase* DPos::vpos() const
450 {
451 return mC.get();
452 }
453
454 inline SizeT DPos::size() const
455 {
456 return mC->vsize();
457 }
458
459 inline SizeT DPos::val() const
460 {
461 return mC->vval();
462 }
463
464 //inline DPosRef DPos::next() const
465 inline DPosRef DPos::sub() const
466 {
467 return DPosRef(mC->vnext());
468 }
469
470 template <class PosT>
471 inline DPos DPos::operator+(const PosT& a) const
472 {
473 if constexpr(std::is_same<PosT,DPos>::value or std::is_same<PosT,DPosRef>::value){
474 return DPos(mC->vplus( a.vpos() ));
475 }
476 else {
477 VPosRef<PosT> b(&a);
478 return DPos(mC->vplus( &b ));
479 }
480 }
481
482 template <class PosT>
483 inline DPos DPos::operator*(const PosT& a) const
484 {
485 if constexpr(std::is_same<PosT,DPos>::value or std::is_same<PosT,DPosRef>::value){
486 return DPos(mC->vtimes( a.vpos() ));
487 }
488 else {
489 VPosRef<PosT> b(&a);
490 return DPos(mC->vtimes( &b ));
491 }
492 }
493
494 // same as operator*, except for FPos/SFPos, where map is executed
495 template <class PosT>
496 inline DPos DPos::operator()(const PosT& a) const
497 {
498 if constexpr(std::is_same<PosT,DPos>::value or std::is_same<PosT,DPosRef>::value){
499 return DPos(mC->vexec( a.vpos() ));
500 }
501 else {
502 VPosRef<PosT> b(&a);
503 return DPos(mC->vexec( &b ));
504 }
505 }
506
507 template <class PosT>
508 inline decltype(auto) DPos::extend(const PosT& a) const
509 {
510 //return DPos(mC->vextend( a ));
511 return MPos<DPos,PosT>(*this,a);
512 }
513
514 inline DPos::operator SizeT() const
515 {
516 return val();
517 }
518
519 /*=============+
520 | DPosRef |
521 +=============*/
522
523 inline DPosRef::DPosRef(const VPosBase* p) : mP(p) {}
524
525 inline const VPosBase* DPosRef::get() const
526 {
527 return mP->vget();
528 }
529
530 inline const VPosBase* DPosRef::vpos() const
531 {
532 return mP;
533 }
534
535 inline SizeT DPosRef::size() const
536 {
537 return mP->vsize();
538 }
539
540 inline SizeT DPosRef::val() const
541 {
542 return mP->vval();
543 }
544
545 //inline DPosRef DPosRef::next() const
546 inline DPosRef DPosRef::sub() const
547 {
548 return DPosRef(mP->vnext());
549 }
550
551 template <class PosT>
552 inline DPos DPosRef::operator+(const PosT& a) const
553 {
554 if constexpr(std::is_same<PosT,DPos>::value or std::is_same<PosT,DPosRef>::value){
555 return DPos(mP->vplus( a.vpos() ));
556 }
557 else {
558 VPosRef<PosT> b(&a);
559 return DPos(mP->vplus( &b ));
560 }
561 }
562
563 template <class PosT>
564 inline DPos DPosRef::operator*(const PosT& a) const
565 {
566 if constexpr(std::is_same<PosT,DPos>::value or std::is_same<PosT,DPosRef>::value){
567 return DPos(mP->vtimes( a.vpos() ));
568 }
569 else {
570 VPosRef<PosT> b(&a);
571 return DPos(mP->vtimes( &b ));
572 }
573 }
574
575 // same as operator*, except for FPos/SFPos, where map is executed
576 template <class PosT>
577 inline DPos DPosRef::operator()(const PosT& a) const
578 {
579 if constexpr(std::is_same<PosT,DPos>::value or std::is_same<PosT,DPosRef>::value){
580 return DPos(mP->vexec( a.vpos() ));
581 }
582 else {
583 VPosRef<PosT> b(&a);
584 return DPos(mP->vexec( &b ));
585 }
586 }
587
588 template <class PosT>
589 inline decltype(auto) DPosRef::extend(const PosT& a) const
590 {
591 //return DPos(mP->vextend( a ));
592 return MPos<DPos,PosT>(*this,a);
593 }
594
595 inline DPosRef::operator SizeT() const
596 {
597 return val();
598 }
599
600 /*==========+
601 | EPos |
602 +==========*/
603
604 template <class BPosT, class... OPosTs>
605 constexpr EPos<BPosT,OPosTs...>::EPos(const BPosT& b, const OPosTs&... os) :
606 BPosT(b),
607 mP(os...)
608 {}
609
610 template <class BPosT, class... OPosTs>
611 constexpr EPos<BPosT,OPosTs...>::EPos(BPosT&& b, OPosTs&&... os) :
612 BPosT(b),
613 mP(os...)
614 {}
615
616 template <class BPosT, class... OPosTs>
617 template <class PosT>
618 constexpr decltype(auto) EPos<BPosT,OPosTs...>::operator+(const PosT& a) const
619 {
620 return iter<0,sizeof...(OPosTs)>
621 ( [&](auto i) { return std::get<i>(mP); },
622 [&](const auto&... e) { return EPos<decltype(BPosT::operator+(a)),OPosTs...>
623 (BPosT::operator+(a),e...); } );
624 }
625
626 template <class BPosT, class... OPosTs>
627 template <class PosT>
628 constexpr decltype(auto) EPos<BPosT,OPosTs...>::operator*(const PosT& a) const
629 {
630 return iter<0,sizeof...(OPosTs)>
631 ( [&](auto i) { return std::get<i>(mP); },
632 [&](const auto&... e) { return EPos<decltype(BPosT::operator*(a)),OPosTs...>
633 (BPosT::operator*(a),e*a...); } );
634 }
635
636 template <class BPosT, class... OPosTs>
637 template <class PosT>
638 constexpr decltype(auto) EPos<BPosT,OPosTs...>::operator()(const PosT& a) const
639 {
640 return iter<0,sizeof...(OPosTs)>
641 ( [&](auto i) { return std::get<i>(mP); },
642 [&](const auto&... e) { return EPos<decltype(BPosT::operator()(a)),OPosTs...>
643 (BPosT::operator()(a),e*a...); } );
644 }
645
646
647 template <class BPosT, class... OPosTs>
648 constexpr decltype(auto) EPos<BPosT,OPosTs...>::val() const
649 {
650 return ival(std::index_sequence_for<OPosTs...>{});
651 }
652
653 template <class BPosT, class... OPosTs>
654 constexpr decltype(auto) EPos<BPosT,OPosTs...>::next() const
655 {
656 return inext(std::index_sequence_for<OPosTs...>{});
657 }
658
659 template <class BPosT, class... OPosTs>
660 constexpr decltype(auto) EPos<BPosT,OPosTs...>::scal() const
661 {
662 return static_cast<const BPosT&>(*this);
663 }
664
665 template <class BPosT, class... OPosTs>
666 template <SizeT I>
667 constexpr decltype(auto) EPos<BPosT,OPosTs...>::get() const
668 {
669 return scal()+std::get<I>(mP);
670 }
671
672 template <class BPosT, class... OPosTs>
673 template <SizeT... Is>
674 constexpr decltype(auto) EPos<BPosT,OPosTs...>::ival(std::index_sequence<Is...> is) const
675 {
676 if constexpr(is_static_pos_type<EPos<BPosT,OPosTs...>>::value){
677 return std::index_sequence<std::get<Is>(mP).val()...>{};
678 }
679 else {
680 return Arr<SizeT,is.size()> { (BPosT::val()+std::get<Is>(mP).val())... };
681 }
682 }
683
684 template <class BPosT, class... OPosTs>
685 template <SizeT... Is>
686 constexpr decltype(auto) EPos<BPosT,OPosTs...>::inext(std::index_sequence<Is...> is) const
687 {
689 return OEPosT(BPosT::next(), std::get<Is>(mP).next()...);
690 }
691
692 /*===============================+
693 | Traits and Helper-Classes |
694 +===============================*/
695
696 template <class BPosT, class OPosT, SizeT N>
697 decltype(auto) MkEPos<BPosT,OPosT,N>::mk(const BPosT& a, const OPosT& b)
698 {
699 return mkiEPos(a, b, std::make_index_sequence<N>{});
700 }
701
702 template <class BPosT, class NPosT, class OPosT, class ONPosT, SizeT N>
704 {
705 const BPosT& ax = static_cast<const BPosT&>(a);
706 const OPosT& bx = static_cast<const OPosT&>(b);
707 return MPos<decltype(mkEPos<N>(ax,bx)),decltype(mkEPos<N>(a.next(),b.next()))>
708 (mkEPos<N>(ax,bx), mkEPos<N>(a.next(),b.next()));
709 }
710
711 template <SizeT N, class BPosT, class OPosT>
712 decltype(auto) mkEPos(const BPosT& a, const OPosT& b)
713 {
715 }
716
717 template <class BPosT, class OPosT, SizeT... Is>
718 decltype(auto) mkiEPos(const BPosT& a, const OPosT& b, std::index_sequence<Is...> is)
719 {
720 return EPos<BPosT,decltype(b*SPos<Is>())...>(a, b*SPos<Is>()...);
721 }
722
723 template <class OPosT1, class OPosT2, class... OPosTs>
724 constexpr bool pos_types_consecutive_2<OPosT1,OPosT2,OPosTs...>::eval()
725 {
726 if constexpr(is_static_pos_type<OPosT1>::value and is_static_pos_type<OPosT2>::value){
727 if constexpr(sizeof...(OPosTs) != 0){
728 return OPosT1().val()+1 == OPosT2().val() and pos_types_consecutive<OPosT2,OPosTs...>::value;
729 }
730 else {
731 return OPosT1().val()+1 == OPosT2().val();
732 }
733 }
734 return false;
735 }
736
737 template <class OPosT1, class... OPosTs>
738 constexpr bool pos_type_same<OPosT1,OPosTs...>::eval()
739 {
740 if constexpr(is_static_pos_type<OPosT1>::value){
741 if constexpr(sizeof...(OPosTs) != 0){
742 return OPosT1().val() == 0 and pos_type_same<OPosTs...>::value;
743 }
744 else {
745 return OPosT1().val() == 0;
746 }
747 }
748 else {
749 return false;
750 }
751 }
752}
753
754#endif
const VPosBase * vpos() const
const VPosBase * get() const
SizeT val() const
DPosRef sub() const
DPos operator()(const PosT &a) const
decltype(auto) extend(const PosT &a) const
SizeT size() const
DPos operator+(const PosT &a) const
DPos operator*(const PosT &a) const
DPosRef(const VPosBase *p)
DPos(Uptr< VPosBase > &&a)
SizeT val() const
DPos operator+(const PosT &a) const
SizeT size() const
const VPosBase * get() const
DPosRef sub() const
DPos operator()(const PosT &a) const
const VPosBase * vpos() const
decltype(auto) extend(const PosT &a) const
constexpr decltype(auto) val() const
constexpr decltype(auto) next() const
constexpr EPos(const BPosT &b, const OPosTs &... os)
FPos(SizeT ext, const SizeT *map)
constexpr FPos operator*(const PosT1 &a) const
constexpr const SizeT & val() const
constexpr UPos operator()(const PosT &a) const
constexpr UPos operator+(const PosT1 &a) const
constexpr decltype(auto) extend(const PosT &a) const
constexpr SizeT size() const
constexpr const NPosT & next() const
constexpr auto operator()(const PosT &a) const
constexpr auto operator+(const PosT &a) const
constexpr SizeT size() const
constexpr MPos()
constexpr auto operator*(const PosT &a) const
constexpr SizeT val() const
constexpr auto operator*(const SPos< N1 > &a) const
constexpr SizeT size() const
constexpr auto operator+(const SPos< N1 > &a) const
constexpr auto operator()(const SPos< N1 > &a) const
constexpr auto operator*(const SPos< N1 > &a) const
Definition pos_type.cc.h:53
constexpr SizeT val() const
Definition pos_type.cc.h:32
constexpr SizeT size() const
Definition pos_type.cc.h:26
constexpr auto operator+(const SPos< N1 > &a) const
Definition pos_type.cc.h:39
constexpr auto operator-(const SPos< N1 > &a) const
Definition pos_type.cc.h:46
constexpr auto operator()(const SPos< N1 > &a) const
Definition pos_type.cc.h:60
constexpr UPos(SizeT ext)
constexpr UPos operator+(const PosT &a) const
constexpr SPos< 0 > operator()(const SPos< 0 > &a) const
constexpr SPos< 0 > operator*(const SPos< 0 > &a) const
constexpr SizeT size() const
constexpr const SizeT & val() const
constexpr decltype(auto) extend(const PosT &a) const
constexpr UPos operator-(const PosT &a) const
virtual Uptr< VPosBase > vtimes(const VPosBase *a) const =0
virtual Uptr< VPosBase > vplus(const VPosBase *a) const =0
virtual Uptr< VPosBase > vexec(const VPosBase *a) const =0
virtual SizeT vsize() const =0
virtual SizeT vval() const =0
virtual const VPosBase * vget() const =0
virtual const VPosBase * vnext() const =0
decltype(auto) mkiEPos(const BPosT &a, const OPosT &b, std::index_sequence< Is... > is)
decltype(auto) mkEPos(const BPosT &a, const OPosT &b)
uint64_t SizeT
Definition types.h:38
std::unique_ptr< T > Uptr
Definition types.h:54
Sptr< Range > rangeCast(const RangePtr r)
std::array< T, N > Arr
Definition types.h:45
constexpr decltype(auto) iter(const G &g, const F &f)
Definition iter.cc.h:34
Position types declarations.
static decltype(auto) mk(const BPosT &a, const OPosT &b)
Dynamic position types declarations.