Mailing list for all users of the OCaml language and system.
 help / color / mirror / Atom feed
* [Caml-list] Typing trouble with PXP
@ 2002-04-03 13:00 Artem Prisyaznuk
  2002-04-03 20:59 ` Gerd Stolpmann
  0 siblings, 1 reply; 2+ messages in thread
From: Artem Prisyaznuk @ 2002-04-03 13:00 UTC (permalink / raw)
  To: caml-list


The problem is summarized in the following code:

	open Pxp_yacc;;

	let rec foo_fun node=
		node#write (`Out_channel stderr) `Enc_koi8r;;
	let  _ =
		let doc = parse_wfdocument_entity default_config (from_file "my.xml") default_spec in
		let root = doc#root in
		begin
				root#write (`Out_channel stderr) `Enc_koi8r;
				foo_fun root    
		end;;

This example doesn't compile and the compiler error message is:

	File "tmp.ml", line 10, characters 11-15:
	This expression has type
	  (('a Pxp_document.node as 'b) Pxp_document.extension as 'a)
	  Pxp_document.node =
		< add_node : ?force:bool -> 'b -> unit;
		  ........skip........
		  write : ?prefixes:string list ->
				  ?default:string ->
				  Pxp_types.output_stream -> Pxp_types.encoding -> unit >
	but is here used with type
	  < add_node : ?force:bool -> 'b -> unit;
		..........skip.............
		write : [> `Out_channel of out_channel] -> [> `Enc_koi8r] -> 'c >

-- 
Best regards
Artem Prisyaznuk
tema@sit.kiev.ua
-------------------
To unsubscribe, mail caml-list-request@inria.fr Archives: http://caml.inria.fr
Bug reports: http://caml.inria.fr/bin/caml-bugs FAQ: http://caml.inria.fr/FAQ/
Beginner's list: http://groups.yahoo.com/group/ocaml_beginners


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2002-04-03 20:59 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2002-04-03 13:00 [Caml-list] Typing trouble with PXP Artem Prisyaznuk
2002-04-03 20:59 ` Gerd Stolpmann

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox