You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Original bug ID: 1915 Reporter: administrator Status: closed Resolution: not a bug Priority: normal Severity: minor Category: ~DO NOT USE (was: OCaml general)
Just run code below:
let s a = match a with
| false, false, false -> "1"
| false, false, true-> "2"
| false, true, fasle -> "3"
| false, true, true -> "4"
| true, false, fasle -> "5"
| true, fasle, true -> "6"
| true, true, fasle -> "7"
| true, true, true -> "8"
| _ -> "none"
;;
let f = false;;
let t = true;;
let all = [(f,f,f); (f,f,t); (f,t,f); (f,t,t);
(t,f,f); (t,f,t); (t,t,f); (t,t,t)]
;;
List.iter (fun tri -> print_endline (s tri)) all;;
Compilation output:
File "t.ml", line 5, characters 4-22:
Warning: this match case is unused.
File "t.ml", line 9, characters 4-22:
Warning: this match case is unused.
File "t.ml", line 10, characters 4-5:
Warning: this match case is unused.
Program output :
1
2
3
3
5
5
7
6
Is it a know bug?
Regards
Lukasz Lew
The text was updated successfully, but these errors were encountered:
Original bug ID: 1915
Reporter: administrator
Status: closed
Resolution: not a bug
Priority: normal
Severity: minor
Category: ~DO NOT USE (was: OCaml general)
Bug description
Full_Name: Lukasz Lew
Version: 3.02 - 3.07
OS: Win / Lin
Submission from: fw-gw-atm.mimuw.edu.pl (193.0.96.15)
Just run code below:
let s a = match a with
| false, false, false -> "1"
| false, false, true-> "2"
| false, true, fasle -> "3"
| false, true, true -> "4"
| true, false, fasle -> "5"
| true, fasle, true -> "6"
| true, true, fasle -> "7"
| true, true, true -> "8"
| _ -> "none"
;;
let f = false;;
let t = true;;
let all = [(f,f,f); (f,f,t); (f,t,f); (f,t,t);
(t,f,f); (t,f,t); (t,t,f); (t,t,t)]
;;
List.iter (fun tri -> print_endline (s tri)) all;;
Compilation output:
File "t.ml", line 5, characters 4-22:
Warning: this match case is unused.
File "t.ml", line 9, characters 4-22:
Warning: this match case is unused.
File "t.ml", line 10, characters 4-5:
Warning: this match case is unused.
Program output :
1
2
3
3
5
5
7
6
Is it a know bug?
Regards
Lukasz Lew
The text was updated successfully, but these errors were encountered: