File: Extern2.cs

package info (click to toggle)
dafny 2.3.0%2Bdfsg-0.1
  • links: PTS, VCS
  • area: main
  • in suites: bookworm, bullseye
  • size: 15,608 kB
  • sloc: cs: 69,676; python: 725; sh: 43; makefile: 40
file content (15 lines) | stat: -rw-r--r-- 457 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
using System.Numerics;

namespace Library {
  public partial class LibClass {
    // static method CallMeInt(x: int) returns (y: int, z: int)
    public static void CallMeInt(BigInteger x, out BigInteger y, out BigInteger z) {
      y = x + BigInteger.One;
      z = y + y;
    }
    // static method CallMeNative(x: MyInt, b: bool) returns (y: MyInt)
    public static void CallMeNative(int x, bool b, out int y) {
      y = b ? x + 1 : x - 1;
    }
  }
}