You've already forked linux-packaging-mono
Imported Upstream version 5.16.0.100
Former-commit-id: 38faa55fb9669e35e7d8448b15c25dc447f25767
This commit is contained in:
parent
0a9828183b
commit
7d7f676260
@@ -1,21 +0,0 @@
|
||||
|
||||
using System;
|
||||
|
||||
internal static partial class Interop
|
||||
{
|
||||
internal static IntPtr MemAlloc(UIntPtr sizeInBytes)
|
||||
{
|
||||
if (Environment.IsRunningOnWindows)
|
||||
return Windows_MemAlloc(sizeInBytes);
|
||||
else
|
||||
return Unix_MemAlloc(sizeInBytes);
|
||||
}
|
||||
|
||||
internal static void MemFree(IntPtr allocatedMemory)
|
||||
{
|
||||
if (Environment.IsRunningOnWindows)
|
||||
Windows_MemFree(allocatedMemory);
|
||||
else
|
||||
Unix_MemFree(allocatedMemory);
|
||||
}
|
||||
}
|
@@ -1,14 +0,0 @@
|
||||
|
||||
using System;
|
||||
|
||||
internal partial class Interop
|
||||
{
|
||||
internal partial class mincore
|
||||
{
|
||||
static mincore()
|
||||
{
|
||||
if (!Environment.IsRunningOnWindows)
|
||||
throw new PlatformNotSupportedException();
|
||||
}
|
||||
}
|
||||
}
|
@@ -0,0 +1,15 @@
|
||||
namespace System.Threading
|
||||
{
|
||||
public sealed class PreAllocatedOverlapped : IDisposable
|
||||
{
|
||||
[CLSCompliant (false)]
|
||||
public unsafe PreAllocatedOverlapped (IOCompletionCallback callback, object state, object pinData)
|
||||
{
|
||||
throw new PlatformNotSupportedException ();
|
||||
}
|
||||
|
||||
public void Dispose ()
|
||||
{
|
||||
}
|
||||
}
|
||||
}
|
@@ -3,7 +3,7 @@ using System.Threading;
|
||||
|
||||
namespace Internal.Runtime.Augments
|
||||
{
|
||||
class RuntimeThread
|
||||
sealed class RuntimeThread
|
||||
{
|
||||
readonly Thread thread;
|
||||
|
||||
@@ -33,5 +33,11 @@ namespace Internal.Runtime.Augments
|
||||
Thread.SpinWait (iterations);
|
||||
return true;
|
||||
}
|
||||
|
||||
public static int GetCurrentProcessorId ()
|
||||
{
|
||||
// TODO: Implement correctly
|
||||
return 1;
|
||||
}
|
||||
}
|
||||
}
|
@@ -1,5 +1,6 @@
|
||||
using System.Threading;
|
||||
using System.Threading.Tasks;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace System.IO
|
||||
{
|
||||
@@ -15,16 +16,19 @@ namespace System.IO
|
||||
throw new NotImplementedException ();
|
||||
}
|
||||
|
||||
public virtual ValueTask<int> ReadAsync(Memory<byte> destination, CancellationToken cancellationToken = default(CancellationToken))
|
||||
public virtual ValueTask<int> ReadAsync (Memory<byte> destination, CancellationToken cancellationToken = default(CancellationToken))
|
||||
{
|
||||
if (destination.TryGetArray (out ArraySegment<byte> array))
|
||||
if (MemoryMarshal.TryGetArray (destination, out ArraySegment<byte> array))
|
||||
return new ValueTask<int> (ReadAsync (array.Array, array.Offset, array.Count, cancellationToken));
|
||||
|
||||
throw new NotImplementedException ();
|
||||
}
|
||||
|
||||
public virtual Task WriteAsync (ReadOnlyMemory<byte> source, CancellationToken cancellationToken = default(CancellationToken))
|
||||
public virtual ValueTask WriteAsync (ReadOnlyMemory<byte> source, CancellationToken cancellationToken = default(CancellationToken))
|
||||
{
|
||||
if (MemoryMarshal.TryGetArray (source, out ArraySegment<byte> array))
|
||||
return new ValueTask (WriteAsync (array.Array, array.Offset, array.Count, cancellationToken));
|
||||
|
||||
throw new NotImplementedException ();
|
||||
}
|
||||
}
|
||||
|
@@ -1,5 +1,3 @@
|
||||
#if !MULTIPLEX_OS
|
||||
|
||||
namespace System.Threading
|
||||
{
|
||||
public sealed class ThreadPoolBoundHandle : IDisposable
|
||||
@@ -48,18 +46,4 @@ namespace System.Threading
|
||||
throw new PlatformNotSupportedException ();
|
||||
}
|
||||
}
|
||||
|
||||
public sealed partial class PreAllocatedOverlapped : IDisposable
|
||||
{
|
||||
[System.CLSCompliantAttribute (false)]
|
||||
public PreAllocatedOverlapped (System.Threading.IOCompletionCallback callback, object state, object pinData)
|
||||
{
|
||||
throw new PlatformNotSupportedException ();
|
||||
}
|
||||
|
||||
public void Dispose ()
|
||||
{
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif
|
Reference in New Issue
Block a user