| 
					
				 | 
			
			
				@@ -18,6 +18,7 @@ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				  
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 #include "cmArgumentParser.h" 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 #include "cmConfigureLog.h" 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+#include "cmExperimental.h" 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 #include "cmExportTryCompileFileGenerator.h" 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 #include "cmGlobalGenerator.h" 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 #include "cmList.h" 
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@@ -1068,6 +1069,17 @@ cm::optional<cmTryCompileResult> cmCoreTryCompile::TryCompileCode( 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				       cmakeVariables.emplace("CMAKE_OSX_ARCHITECTURES", *tcArchs); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				  
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    // Pass down CMAKE_EXPERIMENTAL_* feature flags 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    for (std::size_t i = 0; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+         i < static_cast<std::size_t>(cmExperimental::Feature::Sentinel); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+         i++) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+      auto const& data = cmExperimental::DataForFeature( 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        static_cast<cmExperimental::Feature>(i)); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+      if (data.ForwardThroughTryCompile) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        vars.insert(data.Variable); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+      } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     for (std::string const& var : vars) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				       if (cmValue val = this->Makefile->GetDefinition(var)) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         std::string flag = "-D" + var + "=" + *val; 
			 |