3
0
Fork 0
mirror of https://github.com/Z3Prover/z3 synced 2025-06-02 12:21:21 +00:00
z3/src/api/dotnet/FPSort.cs
Nikolaj Bjorner 3d37060fa9 remove dependencies on contracts
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2018-10-20 10:24:36 -07:00

52 lines
1.1 KiB
C#

/*++
Copyright (c) 2013 Microsoft Corporation
Module Name:
FPSort.cs
Abstract:
Z3 Managed API: Floating Point Sorts
Author:
Christoph Wintersteiger (cwinter) 2013-06-10
Notes:
--*/
using System.Diagnostics;
using System;
namespace Microsoft.Z3
{
/// <summary>
/// FloatingPoint sort
/// </summary>
public class FPSort : Sort
{
/// <summary>
/// The number of exponent bits.
/// </summary>
public uint EBits { get { return Native.Z3_fpa_get_ebits(Context.nCtx, NativeObject); } }
/// <summary>
/// The number of significand bits.
/// </summary>
public uint SBits { get { return Native.Z3_fpa_get_sbits(Context.nCtx, NativeObject); } }
#region Internal
internal FPSort(Context ctx, IntPtr obj)
: base(ctx, obj)
{
Debug.Assert(ctx != null);
}
internal FPSort(Context ctx, uint ebits, uint sbits)
: base(ctx, Native.Z3_mk_fpa_sort(ctx.nCtx, ebits, sbits))
{
Debug.Assert(ctx != null);
}
#endregion
}
}