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: 3902 Reporter: vanicat Assigned to:@pierreweis Status: closed (set by @xavierleroy on 2006-05-06T07:53:07Z) Resolution: fixed Priority: normal Severity: minor Version: 3.09.0 Fixed in version: 3.09.0 Category: ~DO NOT USE (was: OCaml general)
Bug description
When trying the new printf format, I've the following, which is very very strange:
Printf.printf "%{%d%s%}" "kk%dkk%s\n" ;;
: unit =
let t = Obj.repr (Printf.printf "%{%d%s%}" "kk%dkk%s\n");;
Obj.is_block t;;
: bool = true
Obj.is_block (Obj.repr ());;
: bool = false
Obj.tag t;;
: int = 247
Obj.closure_tag;;
: int = 247
So it seem that Printf.printf "%{%d%s%}" "kk%dkk%s\n" should have a functional type, not unit.
The text was updated successfully, but these errors were encountered:
It seems that the function Printf.nargs_of_format_type counts each %( %{ %) and %} as an argument ... which looks wrong. And in the case of %{, the internal % shouldn't be counted.
Original bug ID: 3902
Reporter: vanicat
Assigned to: @pierreweis
Status: closed (set by @xavierleroy on 2006-05-06T07:53:07Z)
Resolution: fixed
Priority: normal
Severity: minor
Version: 3.09.0
Fixed in version: 3.09.0
Category: ~DO NOT USE (was: OCaml general)
Bug description
When trying the new printf format, I've the following, which is very very strange:
Printf.printf "%{%d%s%}" "kk%dkk%s\n" ;;
let t = Obj.repr (Printf.printf "%{%d%s%}" "kk%dkk%s\n");;
Obj.is_block t;;
Obj.is_block (Obj.repr ());;
Obj.tag t;;
Obj.closure_tag;;
So it seem that Printf.printf "%{%d%s%}" "kk%dkk%s\n" should have a functional type, not unit.
The text was updated successfully, but these errors were encountered: