Imported Upstream version 4.0.1

Former-commit-id: 757121caeaad523350be5330f0a3ecc891c70fb8
This commit is contained in:
Jo Shields
2015-04-26 19:10:23 +01:00
parent 7fce50ac98
commit c54b0bda4e
252 changed files with 16715 additions and 1176 deletions

View File

@@ -217,7 +217,7 @@ monotouch_runtime_SUBDIRS := $(monotouch_runtime_dirs)
mobile_static_SUBDIRS := $(mobile_static_dirs)
mobile_SUBDIRS := $(mobile_dynamic_dirs)
xammac_SUBDIRS := $(xammac_dirs)
net_4_0_SUBDIRS := reference-assemblies
binary_reference_assemblies_SUBDIRS := reference-assemblies
net_4_5_SUBDIRS := $(net_4_5_dirs) $(xbuild_4_0_dirs) aot-compiler
xbuild_12_SUBDIRS := $(xbuild_4_0_dirs)
xbuild_14_SUBDIRS := $(xbuild_4_0_dirs)

View File

@@ -350,10 +350,17 @@ namespace System.Net.Http.Headers
sb.Append (entry.Key);
sb.Append (": ");
string separator = ",";
HeaderInfo headerInfo;
if (known_headers.TryGetValue (entry.Key, out headerInfo) && headerInfo.AllowsMany)
separator = headerInfo.Separator;
bool first = true;
foreach (var v in entry.Value) {
if (!first)
sb.Append (", ");
if (!first) {
sb.Append (separator);
sb.Append (" ");
}
sb.Append (v);
first = false;

View File

@@ -147,5 +147,13 @@ namespace MonoTests.System.Net.Http.Headers
Assert.AreEqual ("aa: v, v\r\nx: v\r\n", headers.ToString ());
}
[Test]
public void ToString_DifferentSeparator ()
{
headers.Add ("User-Agent", "MyApp/1.0.0.0 (iOS; 7.1.2; fr_FR) (Apple; iPhone3,1)");
Assert.AreEqual ("User-Agent: MyApp/1.0.0.0 (iOS; 7.1.2; fr_FR) (Apple; iPhone3,1)\r\n", headers.ToString ());
}
}
}

View File

@@ -0,0 +1,42 @@
//
// DefaultDllImportSearchPathsAttribute.cs
//
// Authors:
// Marek Safar <marek.safar@gmail.com>
//
// Copyright (C) 2015 Xamarin Inc (http://www.xamarin.com)
//
// Permission is hereby granted, free of charge, to any person obtaining
// a copy of this software and associated documentation files (the
// "Software"), to deal in the Software without restriction, including
// without limitation the rights to use, copy, modify, merge, publish,
// distribute, sublicense, and/or sell copies of the Software, and to
// permit persons to whom the Software is furnished to do so, subject to
// the following conditions:
//
// The above copyright notice and this permission notice shall be
// included in all copies or substantial portions of the Software.
//
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
//
namespace System.Runtime.InteropServices
{
[AttributeUsage (AttributeTargets.Assembly | AttributeTargets.Method, AllowMultiple = false)]
[System.Runtime.InteropServices.ComVisible (false)]
public sealed class DefaultDllImportSearchPathsAttribute : Attribute
{
public DefaultDllImportSearchPathsAttribute(DllImportSearchPath paths)
{
Paths = paths;
}
public DllImportSearchPath Paths { get; private set; }
}
}

View File

@@ -0,0 +1,42 @@
//
// DllImportSearchPath.cs
//
// Authors:
// Marek Safar <marek.safar@gmail.com>
//
// Copyright (C) 2015 Xamarin Inc (http://www.xamarin.com)
//
// Permission is hereby granted, free of charge, to any person obtaining
// a copy of this software and associated documentation files (the
// "Software"), to deal in the Software without restriction, including
// without limitation the rights to use, copy, modify, merge, publish,
// distribute, sublicense, and/or sell copies of the Software, and to
// permit persons to whom the Software is furnished to do so, subject to
// the following conditions:
//
// The above copyright notice and this permission notice shall be
// included in all copies or substantial portions of the Software.
//
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
//
namespace System.Runtime.InteropServices
{
[Flags]
public enum DllImportSearchPath
{
UseDllDirectoryForDependencies = 0x100,
ApplicationDirectory = 0x200,
UserDirectories = 0x400,
System32 = 0x800,
SafeDirectories = 0x1000,
AssemblyDirectory = 0x2,
LegacyBehavior = 0x0
}
}

File diff suppressed because it is too large Load Diff

View File

@@ -54,7 +54,7 @@ namespace MonoTests.System.Threading
public void Constructor_Defaults ()
{
Assert.IsFalse (mre.IsSet, "#1");
Assert.AreEqual (10, mre.SpinCount, "#2");
Assert.AreEqual (Environment.ProcessorCount == 1 ? 1 : 10, mre.SpinCount, "#2");
}
[Test]

View File

@@ -607,6 +607,8 @@ System.Runtime.InteropServices/CONNECTDATA.cs
System.Runtime.InteropServices/CriticalHandle.cs
System.Runtime.InteropServices/CurrencyWrapper.cs
System.Runtime.InteropServices/DefaultCharSetAttribute.cs
System.Runtime.InteropServices/DllImportSearchPath.cs
System.Runtime.InteropServices/DefaultDllImportSearchPathsAttribute.cs
System.Runtime.InteropServices/DESCKIND.cs
System.Runtime.InteropServices/DispatchWrapper.cs
System.Runtime.InteropServices/DISPPARAMS.cs

View File

@@ -1 +1 @@
49f816213be165022e8677532601a760171cde7a
4816a33a1117da3f621fc172ae972cb88e983fe0

View File

@@ -1 +1 @@
b0b5eee6071ded2ebd95521972c0df2c88e50deb
d56b0642b5e7cef07830b8435781e7decd5a3c88

View File

@@ -1 +1 @@
f5fb66b0084a9b19caf40eb6af8006e3ad5d086f
f812e116ea4476a6400787d291a6c33982351043

View File

@@ -1 +1 @@
6914d5a4219e0c744f39061819064a11992c8c0d
d5baf4466182688805ba46006f24dee0f2a58a7f

View File

@@ -1 +1 @@
5904d2521471bbf55b59d880c2c2db4f8541eaf2
e634a26a89825c34d9fa548f211a6b2e1968da66

View File

@@ -1 +1 @@
918c2fe1f59932f25345576015dcb4587da4e712
45516bac994827703522453286f3a1c1b8d75b1b

View File

@@ -1 +1 @@
324b4f1564f360d9036eb9db709bd652ed7456e5
340def76e208dadff3d94c971334b503dee1dc4c

View File

@@ -1 +1 @@
0aebaa98e4bce0d7503d0ec21e5b1ce28078cd70
976d3a548faca8313dcbe8037ca0a8aa1d22b8da

View File

@@ -4,10 +4,16 @@ include ../../build/rules.make
all-local:
install-local:
$(MKINSTALLDIRS) $(DESTDIR)$(LIBRARY_INSTALL_DIR)
$(INSTALL_LIB) ../../../external/binary-reference-assemblies/v4.0/* $(DESTDIR)$(LIBRARY_INSTALL_DIR)
PROFILE_DIR=$(DESTDIR)$(mono_libdir)/mono/
DISTFILES = $(wildcard ../../../external/binary-reference-assemblies/v4.0/*) Makefile
install-local:
$(MKINSTALLDIRS) $(PROFILE_DIR)/2.0
$(MKINSTALLDIRS) $(PROFILE_DIR)/3.5
$(MKINSTALLDIRS) $(PROFILE_DIR)/4.0
$(INSTALL_LIB) ../../../external/binary-reference-assemblies/v2.0/* $(PROFILE_DIR)/2.0
$(INSTALL_LIB) ../../../external/binary-reference-assemblies/v3.5/* $(PROFILE_DIR)/3.5
$(INSTALL_LIB) ../../../external/binary-reference-assemblies/v4.0/* $(PROFILE_DIR)/4.0
DISTFILES = $(wildcard ../../../external/binary-reference-assemblies/v4.0/*) $(wildcard ../../../external/binary-reference-assemblies/v3.5/*) $(wildcard ../../../external/binary-reference-assemblies/v2.0/*) Makefile
dist-local: dist-default