Index: src/Common/PassVisitor.impl.h
===================================================================
--- src/Common/PassVisitor.impl.h	(revision 25ba99989ac95d7ff7b36866920921f955fcf7c8)
+++ src/Common/PassVisitor.impl.h	(revision 4429b04ca946276c0b8ac84a2f2188572c29d66c)
@@ -400,4 +400,11 @@
 	{
 		auto guard = makeFuncGuard( [this]() { indexerScopeEnter(); }, [this]() { indexerScopeLeave(); } );
+		// implicit add __func__ identifier as specified in the C manual 6.4.2.2
+		static ObjectDecl func(
+			"__func__", noStorageClasses, LinkageSpec::C, nullptr,
+			new ArrayType( Type::Qualifiers(), new BasicType( Type::Qualifiers( Type::Const ), BasicType::Char ), nullptr, true, false ),
+			nullptr
+		);
+		indexerAddId( &func );
 		maybeAccept_impl( node->type, *this );
 		maybeAccept_impl( node->statements, *this );
@@ -418,4 +425,11 @@
 	{
 		auto guard = makeFuncGuard( [this]() { indexerScopeEnter(); }, [this]() { indexerScopeLeave(); } );
+		// implicit add __func__ identifier as specified in the C manual 6.4.2.2
+		static ObjectDecl func(
+			"__func__", noStorageClasses, LinkageSpec::C, nullptr,
+			new ArrayType( Type::Qualifiers(), new BasicType( Type::Qualifiers( Type::Const ), BasicType::Char ), nullptr, true, false ),
+			nullptr
+		);
+		indexerAddId( &func );
 		maybeMutate_impl( node->type, *this );
 		maybeMutate_impl( node->statements, *this );
