Changeset e752e4e for libcfa/src/vec
- Timestamp:
- Dec 12, 2019, 11:09:31 AM (5 years ago)
- Branches:
- ADT, arm-eh, ast-experimental, enum, forall-pointer-decay, jacob/cs343-translation, master, new-ast-unique-expr, pthread-emulation, qualifiedEnum
- Children:
- 99905f4
- Parents:
- 2fa5bd2
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
libcfa/src/vec/vec2.hfa
r2fa5bd2 re752e4e 1 1 #pragma once 2 2 3 #include <iostream.hfa> 3 4 #include "vec.hfa" 4 5 … … 54 55 55 56 forall(| negate(T)) { 56 vec2(T) -?(vec2(T) &v) with (v) {57 vec2(T) -?(vec2(T) v) with (v) { 57 58 return [-x, -y]; 58 59 } … … 113 114 } // static inline 114 115 } 116 117 forall(dtype ostype, otype T | writeable(T, ostype)) { 118 ostype & ?|?(ostype & os, vec2(T) v) with (v) { 119 return os | '<' | x | ',' | y | '>'; 120 } 121 void ?|?(ostype & os, vec2(T) v ) with (v) { 122 (ostype &)(os | v); ends(os); 123 } 124 } 125
Note: See TracChangeset
for help on using the changeset viewer.