Index: trunk/src/core/ascii_printer.cc
===================================================================
--- trunk/src/core/ascii_printer.cc	(revision 486)
+++ trunk/src/core/ascii_printer.cc	(revision 487)
@@ -20,5 +20,5 @@
 	for ( char c : text )
 	{
-		m_terminal->print( coord, color, static_cast<unsigned char>( c ) );
+		m_terminal->print( coord, color, c );
 		++coord.x;
 		if ( coord.x >= m_terminal->get_size().x ) break;
Index: trunk/src/core/io_event.cc
===================================================================
--- trunk/src/core/io_event.cc	(revision 486)
+++ trunk/src/core/io_event.cc	(revision 487)
@@ -64,7 +64,6 @@
 	;
 
-	uint32 counter = 0;
 	db->create_type<io_event_code>()
-#	define NV_IO_EVENT( id ) .value( #id, counter++ )
+#	define NV_IO_EVENT( id ) .value( #id, id )
 #		include <nv/detail/io_event_list.inc>
 #	undef NV_IO_EVENT
Index: trunk/src/core/random.cc
===================================================================
--- trunk/src/core/random.cc	(revision 486)
+++ trunk/src/core/random.cc	(revision 487)
@@ -22,5 +22,5 @@
 {
 	m_state[0] = static_cast<uint32>( seed & mt_full_mask );
-	for ( int i = 1; i < mersenne_n; i++ )
+	for ( uint32 i = 1; i < mersenne_n; i++ )
 	{
 		m_state[i]  = ( 1812433253UL * ( m_state[i - 1] ^ ( m_state[i - 1] >> 30 ) ) + i );
@@ -71,5 +71,5 @@
 
 random::random( random::seed_type seed /*= 0 */ )
-	: m_remaining( 0 ), m_next( nullptr ), m_seeded( 0 )
+	: m_next( nullptr ), m_remaining( 0 ), m_seeded( 0 )
 {
 	mt_init( seed == 0 ? randomized_seed() : seed );
Index: trunk/src/curses/curses_terminal.cc
===================================================================
--- trunk/src/curses/curses_terminal.cc	(revision 486)
+++ trunk/src/curses/curses_terminal.cc	(revision 487)
@@ -53,5 +53,5 @@
 }
 
-void curses_terminal::print( position p, uint32 color, unsigned char ch )
+void curses_terminal::print( position p, uint32 color, char ch )
 {
 	m_update_needed = true;
@@ -64,5 +64,5 @@
 		attrset((static_cast<uint32>(color+1) << 24)  & 0xff000000ul);
 	}
-	mvaddch( p.y-1, p.x-1, ch );
+	mvaddch( p.y-1, p.x-1, chtype(ch) );
 	::move( m_cursor.y-1, m_cursor.x-1 );
 }
Index: trunk/src/engine/animation.cc
===================================================================
--- trunk/src/engine/animation.cc	(revision 486)
+++ trunk/src/engine/animation.cc	(revision 487)
@@ -61,9 +61,9 @@
 		layer.def_state = -1;
 
-		if ( layer.mask != -1 )
+		if ( layer.mask >= 0 )
 		{
 			const auto& tree = animator->poses->get_tree();
 			layer.mask_vector.resize( tree.size(), false );
-			fill_mask_vector_rec( layer.mask_vector, tree, layer.mask );
+			fill_mask_vector_rec( layer.mask_vector, tree, uint32( layer.mask ) );
 		}
 
Index: trunk/src/formats/assimp_loader.cc
===================================================================
--- trunk/src/formats/assimp_loader.cc	(revision 486)
+++ trunk/src/formats/assimp_loader.cc	(revision 487)
@@ -215,9 +215,9 @@
 		{
 			aiBone* bone  = mesh->mBones[m];
-			for (unsigned int w=0; w<bone->mNumWeights; w++)
+			for ( size_t w=0; w<bone->mNumWeights; w++)
 			{
 				assimp_skinned_vtx& v = vtx[ bone->mWeights[w].mVertexId ];
 				bool found = false;
-				for ( int i = 0 ; i < 4; ++i )
+				for ( size_t i = 0 ; i < 4; ++i )
 				{
 					if ( v.boneweight[i] <= 0.0f ) 
@@ -409,5 +409,5 @@
 			{
 				assimp_skinned_vtx& vertex = channel.data()[v];
-				for ( int i = 0; i < 4; ++i )
+				for ( size_t i = 0; i < 4; ++i )
 				{
 					if ( vertex.boneweight[i] > 0.0f )
@@ -429,6 +429,6 @@
 			mat4 tr = nv::math::inverse( assimp_mat4_cast( m_data->node_by_name[bone_data[i].name]->mTransformation ) );
 			int pid = bone_data[i].parent_id;
-			if ( pid != -1 )
-				bone_data[i].transform = tr * bone_data[pid].transform;
+			if ( pid >= 0 )
+				bone_data[i].transform = tr * bone_data[ size_t( pid ) ].transform;
 			else
 				bone_data[i].transform = tr;
@@ -492,8 +492,6 @@
 {
 	int this_is_incorrect;
-	return m_mesh_count == 0 || m_data->scene->mNumAnimations > 0 && m_data->skeletons.size() == 0;
-}
-
-int indent = 0;
+	return m_mesh_count == 0 || ( m_data->scene->mNumAnimations > 0 && m_data->skeletons.size() == 0 );
+}
 
 void nv::assimp_loader::scan_nodes( const void* node ) const
@@ -537,8 +535,7 @@
 	transform t = nv::transform( nv::assimp_mat4_cast( node->mTransformation ) );
 
-	nodes[ this_id ] = anode ? create_keys( anode, t ) : data_channel_set_creator::create_set( 0 );
-
-	infos[this_id].name      = make_name( name );
-	infos[this_id].parent_id = parent_id;
+	nodes[ uint32( this_id ) ] = anode ? create_keys( anode, t ) : data_channel_set_creator::create_set( 0 );
+	infos[ uint32( this_id ) ].name      = make_name( name );
+	infos[ uint32( this_id ) ].parent_id = parent_id;
 	// This value is ignored by the create_transformed_keys, but needed by create_direct_keys!
 	// TODO: find a common solution!
Index: trunk/src/formats/nmd_loader.cc
===================================================================
--- trunk/src/formats/nmd_loader.cc	(revision 486)
+++ trunk/src/formats/nmd_loader.cc	(revision 487)
@@ -66,5 +66,5 @@
 {
 	if ( count == 0 ) return;
-	source.seek( count * sizeof( nmd_attribute ), origin::CUR );
+	source.seek( long( count * sizeof( nmd_attribute ) ), origin::CUR );
 }
 
@@ -220,9 +220,5 @@
 void nv::nmd_dump_bones( stream& stream_out, const data_node_list& nodes )
 {
-	uint32 total = sizeof( nmd_animation_header );
-	for ( auto node : nodes )
-	{
-		total += sizeof( nmd_element_header );
-	}
+	uint32 total = sizeof( nmd_animation_header ) + sizeof( nmd_element_header ) * nodes.size();
 
 	nmd_element_header header;
Index: trunk/src/gfx/image.cc
===================================================================
--- trunk/src/gfx/image.cc	(revision 486)
+++ trunk/src/gfx/image.cc	(revision 487)
@@ -26,6 +26,7 @@
 	: m_size( size ), m_depth( depth ), m_data( nullptr )
 {
+	NV_ASSERT( size.x >= 0 && size.y >= 0, "bad parameters passed to image!" );
 	sint32 bsize = m_size.x * m_size.y * static_cast<sint32>( m_depth );
-	m_data = new uint8[ bsize ];
+	m_data = new uint8[ size_t( bsize ) ];
 
 	if ( reversed )
Index: trunk/src/gfx/mesh_creator.cc
===================================================================
--- trunk/src/gfx/mesh_creator.cc	(revision 486)
+++ trunk/src/gfx/mesh_creator.cc	(revision 487)
@@ -265,6 +265,7 @@
 	delete[] tangents2;
 
-	uint32 n_channel_index = m_data->get_channel_index( slot::NORMAL );
-	data_channel_set_creator( m_data ).set_channel( n_channel_index, merge_channels( *m_nrm_channel, g_channel ) );
+	int n_channel_index = m_data->get_channel_index( slot::NORMAL );
+	NV_ASSERT( n_channel_index >= 0, "Normal channel not found!" );
+	data_channel_set_creator( m_data ).set_channel( uint32( n_channel_index ), merge_channels( *m_nrm_channel, g_channel ) );
 	initialize();
 }
Index: trunk/src/gfx/texture_font.cc
===================================================================
--- trunk/src/gfx/texture_font.cc	(revision 486)
+++ trunk/src/gfx/texture_font.cc	(revision 487)
@@ -80,5 +80,5 @@
 static uint8* convert_to_rgba(uint8* rgb, const int lines, const int line_count, const int line_bpitch )
 {
-	uint8* result = new uint8[ lines * line_count * 4 ];
+	uint8* result = new uint8[ static_cast< uint32 >( lines * line_count * 4 ) ];
 	uint8* rgba   = result;
 	for(int l=0; l<lines; ++l) 
Index: trunk/src/gl/gl_context.cc
===================================================================
--- trunk/src/gl/gl_context.cc	(revision 486)
+++ trunk/src/gl/gl_context.cc	(revision 487)
@@ -216,5 +216,5 @@
 			glBindBufferBase( buffer_type_to_enum( info->type ), index, info->glid );
 		else
-			glBindBufferRange( buffer_type_to_enum( info->type ), index, info->glid, offset, size );
+			glBindBufferRange( buffer_type_to_enum( info->type ), index, info->glid, static_cast<GLintptr>( offset ), static_cast<GLsizeiptr>( size ) );
 	}
 }
@@ -790,5 +790,5 @@
 		else
 		{
-			glDrawArrays( primitive_to_enum(prim), first, static_cast<GLsizei>( count ) );
+			glDrawArrays( primitive_to_enum(prim), static_cast<GLint>( first ), static_cast<GLsizei>( count ) );
 		}
 		unbind( va );
Index: trunk/src/gl/gl_device.cc
===================================================================
--- trunk/src/gl/gl_device.cc	(revision 486)
+++ trunk/src/gl/gl_device.cc	(revision 487)
@@ -358,6 +358,6 @@
 	if ( info )
 	{
-		int result = glGetUniformBlockIndex( info->glid, name.data() );
-		if ( result >= 0 ) return result;
+		GLuint result = glGetUniformBlockIndex( info->glid, name.data() );
+		if ( result != GL_INVALID_INDEX ) return static_cast<int>( result );
 		if ( fatal )
 		{
@@ -427,18 +427,19 @@
 		if ( ubase->is_dirty() )
 		{
-			int uloc = ubase->get_location();
+			GLint   uloc = ubase->get_location();
+			GLsizei size = static_cast<GLsizei>( ubase->get_length() );
 			switch( ubase->get_type() )
 			{
-			case FLOAT          : glUniform1fv( uloc, ubase->get_length(), static_cast< uniform< enum_to_type< FLOAT >::type >*>( ubase )->get_value() ); break;
-			case INT            : glUniform1iv( uloc, ubase->get_length(), static_cast< uniform< enum_to_type< INT >::type >*>( ubase )->get_value() ); break;
-			case FLOAT_VECTOR_2 : glUniform2fv( uloc, ubase->get_length(), reinterpret_cast<const GLfloat*>( static_cast< uniform< enum_to_type< FLOAT_VECTOR_2 >::type >*>( ubase )->get_value())); break;
-			case FLOAT_VECTOR_3 : glUniform3fv( uloc, ubase->get_length(), reinterpret_cast<const GLfloat*>( static_cast< uniform< enum_to_type< FLOAT_VECTOR_3 >::type >*>( ubase )->get_value())); break;
-			case FLOAT_VECTOR_4 : glUniform4fv( uloc, ubase->get_length(), reinterpret_cast<const GLfloat*>( static_cast< uniform< enum_to_type< FLOAT_VECTOR_4 >::type >*>( ubase )->get_value())); break;
-			case INT_VECTOR_2   : glUniform2iv( uloc, ubase->get_length(), reinterpret_cast<const GLint*>( static_cast< uniform< enum_to_type< INT_VECTOR_2 >::type >*>( ubase )->get_value())); break;
-			case INT_VECTOR_3   : glUniform3iv( uloc, ubase->get_length(), reinterpret_cast<const GLint*>( static_cast< uniform< enum_to_type< INT_VECTOR_3 >::type >*>( ubase )->get_value())); break;
-			case INT_VECTOR_4   : glUniform4iv( uloc, ubase->get_length(), reinterpret_cast<const GLint*>( static_cast< uniform< enum_to_type< INT_VECTOR_4 >::type >*>( ubase )->get_value())); break;
-			case FLOAT_MATRIX_2 : glUniformMatrix2fv( uloc, ubase->get_length(), GL_FALSE, reinterpret_cast<const GLfloat*>( static_cast< uniform< enum_to_type< FLOAT_MATRIX_2 >::type >*>( ubase )->get_value())); break;
-			case FLOAT_MATRIX_3 : glUniformMatrix3fv( uloc, ubase->get_length(), GL_FALSE, reinterpret_cast<const GLfloat*>( static_cast< uniform< enum_to_type< FLOAT_MATRIX_3 >::type >*>( ubase )->get_value())); break;
-			case FLOAT_MATRIX_4 : glUniformMatrix4fv( uloc, ubase->get_length(), GL_FALSE, reinterpret_cast<const GLfloat*>( static_cast< uniform< enum_to_type< FLOAT_MATRIX_4 >::type >*>( ubase )->get_value())); break;
+			case FLOAT          : glUniform1fv( uloc, size, static_cast< uniform< enum_to_type< FLOAT >::type >*>( ubase )->get_value() ); break;
+			case INT            : glUniform1iv( uloc, size, static_cast< uniform< enum_to_type< INT >::type >*>( ubase )->get_value() ); break;
+			case FLOAT_VECTOR_2 : glUniform2fv( uloc, size, reinterpret_cast<const GLfloat*>( static_cast< uniform< enum_to_type< FLOAT_VECTOR_2 >::type >*>( ubase )->get_value())); break;
+			case FLOAT_VECTOR_3 : glUniform3fv( uloc, size, reinterpret_cast<const GLfloat*>( static_cast< uniform< enum_to_type< FLOAT_VECTOR_3 >::type >*>( ubase )->get_value())); break;
+			case FLOAT_VECTOR_4 : glUniform4fv( uloc, size, reinterpret_cast<const GLfloat*>( static_cast< uniform< enum_to_type< FLOAT_VECTOR_4 >::type >*>( ubase )->get_value())); break;
+			case INT_VECTOR_2   : glUniform2iv( uloc, size, reinterpret_cast<const GLint*>( static_cast< uniform< enum_to_type< INT_VECTOR_2 >::type >*>( ubase )->get_value())); break;
+			case INT_VECTOR_3   : glUniform3iv( uloc, size, reinterpret_cast<const GLint*>( static_cast< uniform< enum_to_type< INT_VECTOR_3 >::type >*>( ubase )->get_value())); break;
+			case INT_VECTOR_4   : glUniform4iv( uloc, size, reinterpret_cast<const GLint*>( static_cast< uniform< enum_to_type< INT_VECTOR_4 >::type >*>( ubase )->get_value())); break;
+			case FLOAT_MATRIX_2 : glUniformMatrix2fv( uloc, size, GL_FALSE, reinterpret_cast<const GLfloat*>( static_cast< uniform< enum_to_type< FLOAT_MATRIX_2 >::type >*>( ubase )->get_value())); break;
+			case FLOAT_MATRIX_3 : glUniformMatrix3fv( uloc, size, GL_FALSE, reinterpret_cast<const GLfloat*>( static_cast< uniform< enum_to_type< FLOAT_MATRIX_3 >::type >*>( ubase )->get_value())); break;
+			case FLOAT_MATRIX_4 : glUniformMatrix4fv( uloc, size, GL_FALSE, reinterpret_cast<const GLfloat*>( static_cast< uniform< enum_to_type< FLOAT_MATRIX_4 >::type >*>( ubase )->get_value())); break;
 			default : break; // error?
 			}
@@ -507,5 +508,5 @@
 		}
 
-		uniform_base* u = uniform_base::create( utype, uni_loc, uni_len );
+		uniform_base* u = uniform_base::create( utype, uni_loc, size_t( uni_len ) );
 		NV_ASSERT( u, "Unknown uniform type!" );
 		(*p->m_uniform_map)[ name ] = u;
Index: trunk/src/gui/gui_ascii_renderer.cc
===================================================================
--- trunk/src/gui/gui_ascii_renderer.cc	(revision 486)
+++ trunk/src/gui/gui_ascii_renderer.cc	(revision 487)
@@ -18,5 +18,5 @@
 	bool   clear;
 	bool   border;
-	uchar8 border_chars[8];
+	char   border_chars[8];
 	uint32 border_color;
 	uint32 text_color;
@@ -67,5 +67,5 @@
 				er->border_color = uint32( border_color );
 			for ( uint32 i = 0; i < 8 && i < path.length(); i++ )
-				er->border_chars[i] = static_cast< uchar8 >( path[i] );
+				er->border_chars[i] = path[i];
 		}
 	}
@@ -102,5 +102,5 @@
 		for ( char c : e->m_text )
 		{
-			m_terminal->print( p, er->text_color, static_cast< unsigned char >( c ) );
+			m_terminal->print( p, er->text_color, c );
 			++p.x;
 		}
Index: trunk/src/gui/gui_gfx_renderer.cc
===================================================================
--- trunk/src/gui/gui_gfx_renderer.cc	(revision 486)
+++ trunk/src/gui/gui_gfx_renderer.cc	(revision 487)
@@ -311,5 +311,5 @@
 		}
 
-		e->m_text;
+//		e->m_text;
 		if ( !e->m_text.empty() )
 		{
Index: trunk/src/gui/gui_style.cc
===================================================================
--- trunk/src/gui/gui_style.cc	(revision 486)
+++ trunk/src/gui/gui_style.cc	(revision 487)
@@ -33,7 +33,7 @@
 	if ( !resolve( e->m_id, e->m_class, cselector, centry, LUA_TTABLE ) ) return false;
 	vec = vec4();
-	for ( int i = 0; i < 4; ++i )
+	for ( size_t i = 0; i < 4; ++i )
 	{
-		lua_rawgeti( m_lua, -1, i+1 );
+		lua_rawgeti( m_lua, -1, int(i+1) );
 		if ( lua_isnil( m_lua, -1 ) ) return true;
 		vec[i] = static_cast< float >( lua_tonumber( m_lua, -1 ) );
Index: trunk/src/image/miniz.cc
===================================================================
--- trunk/src/image/miniz.cc	(revision 486)
+++ trunk/src/image/miniz.cc	(revision 487)
@@ -3,4 +3,16 @@
 
 using namespace nv;
+
+#define MINIZ_NO_TIME
+#define MINIZ_NO_ZLIB_COMPATIBLE_NAMES
+
+#define MINIZ_HAS_64BIT_REGISTERS 0
+#define TINFL_USE_64BIT_BITBUF 0
+
+#if NV_COMPILER == NV_CLANG
+#pragma clang diagnostic ignored "-Wunused-macros"
+#pragma clang diagnostic ignored "-Wold-style-cast"
+#pragma clang diagnostic ignored "-Wsign-conversion"
+#endif
 
 #if defined( _M_IX86 ) || defined( _M_X64 ) || defined( __i386__ ) || defined( __i386 ) || defined( __i486__ ) || defined( __i486 ) || defined( i386 ) || defined( __ia64__ ) || defined( __x86_64__ )
Index: trunk/src/image/png_loader.cc
===================================================================
--- trunk/src/image/png_loader.cc	(revision 486)
+++ trunk/src/image/png_loader.cc	(revision 487)
@@ -10,4 +10,13 @@
 
 using namespace nv;
+
+#if NV_COMPILER == NV_CLANG
+#pragma clang diagnostic ignored "-Wunused-macros"
+#pragma clang diagnostic ignored "-Wold-style-cast"
+#pragma clang diagnostic ignored "-Wsign-conversion"
+#pragma clang diagnostic ignored "-Wreserved-id-macro"
+#pragma clang diagnostic ignored "-Wmissing-prototypes"
+#define NULL 0
+#endif
 
 enum
@@ -322,10 +331,15 @@
 };
 
+static int iabs( int a )
+{
+	return a < 0 ? -a : a;
+}
+
 static int stbi__paeth( int a, int b, int c )
 {
 	int p = a + b - c;
-	int pa = abs( p - a );
-	int pb = abs( p - b );
-	int pc = abs( p - c );
+	int pa = iabs( p - a );
+	int pb = iabs( p - b );
+	int pc = iabs( p - c );
 	if ( pa <= pb && pa <= pc ) return a;
 	if ( pb <= pc ) return b;
@@ -1050,5 +1064,5 @@
 		case 3: format.format = RGB; break;
 		case 4: format.format = RGBA; break;
-		default: return false;
+		default: return nullptr;
 		}
 		size = ivec2( x, y );
Index: trunk/src/io/c_stream.cc
===================================================================
--- trunk/src/io/c_stream.cc	(revision 486)
+++ trunk/src/io/c_stream.cc	(revision 487)
@@ -50,5 +50,5 @@
 {
 	NV_ASSERT( buffer != nullptr && max_count != 0, "Bad parameter passed to write!" );
-	char* result = ::fgets( buffer, max_count, reinterpret_cast<FILE*>( m_file ) );
+	char* result = ::fgets( buffer, static_cast<int>( max_count ), reinterpret_cast<FILE*>( m_file ) );
 	if ( !result ) return false;
 	return true;
Index: trunk/src/lib/gl.cc
===================================================================
--- trunk/src/lib/gl.cc	(revision 486)
+++ trunk/src/lib/gl.cc	(revision 487)
@@ -161,7 +161,7 @@
 	if ( wgl_library_loaded ) return true;
 
-	HGLRC (NV_GL_APIENTRY *wgl_createcontext) (HDC)        = nullptr;
-	BOOL  (NV_GL_APIENTRY *wgl_makecurrent)   (HDC, HGLRC) = nullptr;
-	BOOL  (NV_GL_APIENTRY *wgl_deletecontext) (HGLRC)      = nullptr;
+	HGLRC ( NV_GL_APIENTRY *wgl_createcontext) (HDC)        = nullptr;
+	BOOL  ( NV_GL_APIENTRY *wgl_makecurrent)   (HDC, HGLRC) = nullptr;
+	BOOL  ( NV_GL_APIENTRY *wgl_deletecontext) (HGLRC)      = nullptr;
 
 	void_assign( wgl_createcontext, gl_library.get("wglCreateContext") );
Index: trunk/src/lua/lua_math.cc
===================================================================
--- trunk/src/lua/lua_math.cc	(revision 486)
+++ trunk/src/lua/lua_math.cc	(revision 487)
@@ -11,5 +11,5 @@
 #include "nv/stl/type_traits/common.hh"
 
-static int nlua_swizzel_lookup[256];
+static size_t nlua_swizzel_lookup[256];
 
 using nv::lua::detail::is_vec;
@@ -18,5 +18,5 @@
 using nv::lua::detail::push_vec;
 
-inline bool nlua_is_swizzel( const unsigned char* str, int max )
+inline bool nlua_is_swizzel( const unsigned char* str, size_t max )
 {
 	while (*str)
@@ -279,7 +279,7 @@
 	{
  		switch (len) {
-		case 2 : { vec2 v2 = to_vec<vec2>(L,3); for ( int i = 0; i<int( len ); ++i) (*v)[nlua_swizzel_lookup[key[i]]] = v2[i]; } return 0;
-		case 3 : { vec3 v3 = to_vec<vec3>(L,3); for ( int i = 0; i<int( len ); ++i) (*v)[nlua_swizzel_lookup[key[i]]] = v3[i]; } return 0;
-		case 4 : { vec4 v4 = to_vec<vec4>(L,3); for ( int i = 0; i<int( len ); ++i) (*v)[nlua_swizzel_lookup[key[i]]] = v4[i]; } return 0;
+		case 2 : { vec2 v2 = to_vec<vec2>(L,3); for ( size_t i = 0; i< len; ++i) (*v)[nlua_swizzel_lookup[key[i]]] = v2[i]; } return 0;
+		case 3 : { vec3 v3 = to_vec<vec3>(L,3); for ( size_t i = 0; i< len; ++i) (*v)[nlua_swizzel_lookup[key[i]]] = v3[i]; } return 0;
+		case 4 : { vec4 v4 = to_vec<vec4>(L,3); for ( size_t i = 0; i< len; ++i) (*v)[nlua_swizzel_lookup[key[i]]] = v4[i]; } return 0;
  		default: break;
 		}
Index: trunk/src/stl/assert.cc
===================================================================
--- trunk/src/stl/assert.cc	(revision 486)
+++ trunk/src/stl/assert.cc	(revision 487)
@@ -28,7 +28,14 @@
 #	else // NV_COMPILER
 #	if NV_COMPILER == NV_CLANG
-extern "C" {
-	extern void __assert(const char *, const char *, unsigned int, const char *) NV_NORETURN;
+// extern "C" {
+// 	extern void __assert(const char *, const char *, unsigned int, const char *) NV_NORETURN;
+// }
+
+int error_here;
+static void __assert( const char *, const char *, unsigned int, const char * ) NV_NORETURN
+{
+	//no-op
 }
+
 #define NV_ASSERT_IMPL __assert
 #	else
