This is exactly the same problem as your previous post.
You are trying to define a non-regular type.
I.e., if you expand the definition of job, you get:
type ('a,'b) batch = private
< build : < create_batch : 'c.('a -> 'c) -> ('a,'c) batch; .. > ->
('a priority * 'a) list ->
Hi list,
Consider this:
type 'a x = { x_v : 'a }
and 'a y = { y_x : int kind;
y_arr : 'a array
}
and 'a kind =
X of 'a x
| Y of 'a y
I'd like to write a function _getter_ that's polymorphic over kind. This
doesn't work, getting int kind -> int:
let rec getter = func
Unfortunately, most forms of parsing are not terribly amenable to
efficient parallelization because of the irregular nature of the
subcomponents of the parsing problem. That is, you can't easily break
up the problem into subcomponents that can be farmed out to different
CPUs. That said, if
There is certainly a reasonable body of basic CS research on
parallelizing CFG algorithms such as CYK, the Earley parser, and to a
lesser extent the more practical LALR strategy used by yacc etc. (In
the latter case it seems to get easier if you're willing to trade off
determinism when parsing ambi
I'm desperately trying to prepare for the imminent drop of a rock-solid
multicore-friendly OCaml implementation and was wondering what work has been
done on parallelized parsers and/or parallel-friendly grammars?
For example, Mathematica syntax for nested lists of integers looks like:
{{{1,
Dear caml-list,
I try to define the signature of three interdependant classes that should
then be derived and completed for various implementation. The code below
causes the strange error messsage:
File "tmp.ml", line 4, characters 7-92:
In the definition of job, type ('a, 'b) b
*
* *
*FM2009: 16th FM Symposium and 2nd World Congress *
* Theory meets practice *
* *
*
Goswin von Brederlow wrote:
> Which would also need
>
> module A1 = new module A
> module A2 = new module A
> A1.incr_x ()
> A1.get_x;;
> - : int = 124
> A2.get_x ();;
> - : int = 123
>
> So you see A does not have global variables but only instance
> variables. What you describe are ocaml object