Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/corert.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarek Safar <marek.safar@gmail.com>2018-06-18 14:33:53 +0300
committerMarek Safar <marek.safar@gmail.com>2018-06-18 14:33:53 +0300
commitaf496fc1c27c9886fdb6ea1ac967ba8d549e8ccc (patch)
tree324f9ee3df5ee0d4accb4ea8a95fee4d051b492a
parent8867cf2ee1599d1b1cdb35822736e6fb293ef06c (diff)
Add dependency tracking to string constructors
-rw-r--r--src/System.Private.CoreLib/src/System/String.cs9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/System.Private.CoreLib/src/System/String.cs b/src/System.Private.CoreLib/src/System/String.cs
index a10d212c0..bb238f940 100644
--- a/src/System.Private.CoreLib/src/System/String.cs
+++ b/src/System.Private.CoreLib/src/System/String.cs
@@ -82,6 +82,7 @@ namespace System
// declared constructors.
[MethodImplAttribute(MethodImplOptions.InternalCall)]
+ [PreserveDependency("System.String.CreateString(System.Char[])")]
public extern String(char[] value);
[System.Runtime.CompilerServices.DependencyReductionRoot]
@@ -105,6 +106,7 @@ namespace System
}
[MethodImplAttribute(MethodImplOptions.InternalCall)]
+ [PreserveDependency("System.String.CreateString(System.Char[], System.Int32, System.Int32)")]
public extern String(char[] value, int startIndex, int length);
[System.Runtime.CompilerServices.DependencyReductionRoot]
@@ -141,6 +143,7 @@ namespace System
[CLSCompliant(false)]
[MethodImplAttribute(MethodImplOptions.InternalCall)]
+ [PreserveDependency("System.String.CreateString(System.Char*)")]
unsafe public extern String(char* value);
[System.Runtime.CompilerServices.DependencyReductionRoot]
@@ -173,6 +176,7 @@ namespace System
[CLSCompliant(false)]
[MethodImplAttribute(MethodImplOptions.InternalCall)]
+ [PreserveDependency("System.String.CreateString(System.Char*, System.Int32, System.Int32)")]
unsafe public extern String(char* value, int startIndex, int length);
[System.Runtime.CompilerServices.DependencyReductionRoot]
@@ -214,6 +218,7 @@ namespace System
[CLSCompliant(false)]
[MethodImpl(MethodImplOptions.InternalCall)]
+ [PreserveDependency("System.String.CreateString(System.SByte*)")]
public extern unsafe String(sbyte* value);
[DependencyReductionRoot]
@@ -232,6 +237,7 @@ namespace System
[CLSCompliant(false)]
[MethodImpl(MethodImplOptions.InternalCall)]
+ [PreserveDependency("System.String.CreateString(System.SByte*, System.Int32, System.Int32)")]
public extern unsafe String(sbyte* value, int startIndex, int length);
[DependencyReductionRoot]
@@ -284,6 +290,7 @@ namespace System
[CLSCompliant(false)]
[MethodImpl(MethodImplOptions.InternalCall)]
+ [PreserveDependency("System.String.CreateString(System.SByte*, System.Int32, System.Int32, System.Text.Encoding)")]
public extern unsafe String(sbyte* value, int startIndex, int length, Encoding enc);
[DependencyReductionRoot]
@@ -329,6 +336,7 @@ namespace System
}
[MethodImplAttribute(MethodImplOptions.InternalCall)]
+ [PreserveDependency("System.String.CreateString(System.Char, System.Int32)")]
public extern String(char c, int count);
[System.Runtime.CompilerServices.DependencyReductionRoot]
@@ -376,6 +384,7 @@ namespace System
}
[MethodImplAttribute(MethodImplOptions.InternalCall)]
+ [PreserveDependency("System.String.CreateString(System.ReadOnlySpan`1<System.Char>)")]
public extern String(ReadOnlySpan<char> value);
[DependencyReductionRoot]