Changeset 181 for trunk/src/framework
- Timestamp:
- 11/19/08 13:44:02 (17 years ago)
- Files:
-
- 1 modified
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/framework/Utilities/ByteConverter.h
r102 r181 11 11 * This program is distributed in the hope that it will be useful, 12 12 * but WITHOUT ANY WARRANTY; without even the implied warranty of 13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 14 * GNU General Public License for more details. 15 15 * 16 16 * You should have received a copy of the GNU General Public License 17 17 * along with this program; if not, write to the Free Software 18 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307USA18 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 19 19 */ 20 20 … … 49 49 #if TRINITY_ENDIAN == TRINITY_BIGENDIAN 50 50 template<typename T> inline void EndianConvert(T& val) { ByteConverter::apply<T>(&val); } 51 template<typename T> inline void EndianConvertReverse(T&) { } 51 52 #else 52 53 template<typename T> inline void EndianConvert(T&) { } 54 template<typename T> inline void EndianConvertReverse(T& val) { ByteConverter::apply<T>(&val); } 53 55 #endif 54 56 55 template<typename T> inline void EndianConvert(T*) { } 57 template<typename T> void EndianConvert(T*); // will generate link error 58 template<typename T> void EndianConvertReverse(T*); // will generate link error 59 56 60 inline void EndianConvert(uint8&) { } 57 61 inline void EndianConvert( int8&) { } 62 inline void EndianConvertReverse(uint8&) { } 63 inline void EndianConvertReverse( int8&) { } 58 64 59 65 #endif