| 1989 | } |
| 1990 | |
| 1991 | Type TypeDecl::getVectorBaseType() const { |
| 1992 | switch (baseType) { |
| 1993 | case tInt2: |
| 1994 | case tInt3: |
| 1995 | case tInt4: return Type::tInt; |
| 1996 | case tUInt2: |
| 1997 | case tUInt3: |
| 1998 | case tUInt4: return Type::tUInt; |
| 1999 | case tFloat2: |
| 2000 | case tFloat3: |
| 2001 | case tFloat4: return Type::tFloat; |
| 2002 | case tRange: return Type::tInt; |
| 2003 | case tURange: return Type::tUInt; |
| 2004 | case tRange64: return Type::tInt64; |
| 2005 | case tURange64: return Type::tUInt64; |
| 2006 | default: |
| 2007 | DAS_ASSERTF(0, |
| 2008 | "we should not even be here. we are calling getVectorBaseType on an unsuppored baseType." |
| 2009 | "likely new vector type been added."); |
| 2010 | return Type::none; |
| 2011 | } |
| 2012 | } |
| 2013 | |
| 2014 | Type TypeDecl::getVectorType ( Type bt, int dim ) { |
| 2015 | if ( dim==1 ) return bt; |
no outgoing calls
no test coverage detected