aboutsummaryrefslogtreecommitdiff
path: root/src/test/run-pass/int-lib.rs
blob: ce39de4392106a5679f8b2472e078478fd30a221 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
use std;

import std._int;

fn test_to_str() {
  check (_int.to_str(0, 10u) == "0");
  check (_int.to_str(1, 10u) == "1");
  check (_int.to_str(-1, 10u) == "-1");
  check (_int.to_str(255, 16u) == "ff");
  check (_int.to_str(-71, 36u) == "-1z");
}

fn main() {
  test_to_str();
}