From: David B. <dav...@gm...> - 2011-05-11 05:59:12
|
Hi Alexander, Server commands have only one parameter (of type string). If you want more structure, you have to parse that string. This will change in the future to something more convenient, but I can't say when. The Liquidsoap is inspired from functional programming in general (and OCaml in particular) but the language syntax has nothing to do with OCaml. So no, you can't learn OCaml to learn our syntax. However, learning OCaml will make you more comfortable about static typing and type inference errors. I don't know if this is crucial. More simply, the lesson from your multiple-argument experience might be the following: read and understand the type of functions (such as server.register) and don't try to work around it (server.register says it wants a function with only one argument, it means that only this is supported). Cheers, -- David |