Add ifdef to suppress non-coreclr warning
authorstephentoub <stoub@microsoft.com>
Mon, 11 Jan 2016 23:25:17 +0000 (18:25 -0500)
committerstephentoub <stoub@microsoft.com>
Mon, 11 Jan 2016 23:25:17 +0000 (18:25 -0500)
My change to optimize AppDomain.Setup included moving a variable out of a loop, which also ended up moving it out of an ifdef.  That then causes an unused variable warning on some builds.

src/mscorlib/src/System/AppDomain.cs

index 12428be..ae5e841 100644 (file)
@@ -3623,7 +3623,9 @@ namespace System {
 
             if(propertyNames!=null && propertyValues != null)
             {
+#if FEATURE_CORECLR
                 StringBuilder normalisedAppPathList = null;
+#endif // FEATURE_CORECLR
                 for (int i=0; i<propertyNames.Length; i++)
                 {
                     if(propertyNames[i]=="APPBASE") // make sure in sync with Fusion