Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

typage des formats et kprintf #3268

Closed
vicuna opened this issue Mar 21, 2002 · 2 comments
Closed

typage des formats et kprintf #3268

vicuna opened this issue Mar 21, 2002 · 2 comments
Labels

Comments

@vicuna
Copy link

vicuna commented Mar 21, 2002

Original bug ID: 1018
Reporter: administrator
Status: closed
Resolution: fixed
Priority: normal
Severity: minor
Category: ~DO NOT USE (was: OCaml general)

Bug description

Objective Caml version 3.04+8 (2002-03-13)

Printf.kprintf print_string "%t" (fun x -> x);;

Bus error

(problème identique avec %a)

de plus le manuel n'est pas clair quand au type de la fonction attendu :
pour un ('a,'b,'c) format, il n'est précisé nul part que le type est
('b -> 'c) et non ('b -> unit).

@vicuna
Copy link
Author

vicuna commented Mar 21, 2002

Comment author: administrator

Printf.kprintf print_string "%t" (fun x -> x);;

Bus error

Ah oui, j'avais pas vu que le type du resultat de printf doit etre egal
au type du resultat des fonctions %a et %t... C'est fixe dans la version
de travail.

de plus le manuel n'est pas clair quand au type de la fonction attendu :
pour un ('a,'b,'c) format, il n'est précisé nul part que le type est
('b -> 'c) et non ('b -> unit).

En effet, il faut lire la description de fprintf et generaliser "stream" et
"unit" en 'b et 'c.

Merci pour le rapport de bug,

-- Damien

@vicuna
Copy link
Author

vicuna commented Jun 3, 2002

Comment author: administrator

Fixed 2002-03-21 by Damien.

@vicuna vicuna closed this as completed Jun 3, 2002
@vicuna vicuna added the bug label Mar 19, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant