00:06
serge has joined #ocaml
00:11
serge has quit [Ping timeout: 260 seconds]
00:16
Haudegen has quit [Ping timeout: 260 seconds]
00:17
fds has quit [Ping timeout: 255 seconds]
00:23
spew has quit [Quit: Connection closed for inactivity]
00:28
serge has joined #ocaml
00:33
serge has quit [Ping timeout: 240 seconds]
00:58
RalfJ has quit [Ping timeout: 272 seconds]
00:59
RalfJ has joined #ocaml
01:01
serge has joined #ocaml
01:04
RalfJ has quit [Ping timeout: 272 seconds]
01:05
serge has quit [Ping timeout: 260 seconds]
01:24
serge has joined #ocaml
01:28
serge has quit [Ping timeout: 240 seconds]
01:28
RalfJ has joined #ocaml
01:41
serge has joined #ocaml
01:42
RalfJ has quit [Ping timeout: 272 seconds]
01:46
serge has quit [Ping timeout: 240 seconds]
01:52
malina has joined #ocaml
01:53
wingsorc has joined #ocaml
01:55
serge has joined #ocaml
01:57
serge_ has joined #ocaml
01:59
serge has quit [Ping timeout: 240 seconds]
02:01
serge_ has quit [Ping timeout: 260 seconds]
02:04
serge has joined #ocaml
02:09
serge has quit [Ping timeout: 255 seconds]
02:09
RalfJ has joined #ocaml
02:17
RalfJ has quit [Ping timeout: 272 seconds]
02:19
RalfJ has joined #ocaml
02:27
webshinra has quit [Remote host closed the connection]
02:31
serge has joined #ocaml
02:35
serge has quit [Ping timeout: 240 seconds]
02:42
mahmudov has quit [Remote host closed the connection]
03:03
serge has joined #ocaml
03:07
serge has quit [Ping timeout: 240 seconds]
03:08
wingsorc has quit [Ping timeout: 240 seconds]
03:10
ecrok has joined #ocaml
03:10
ecrok has left #ocaml [#ocaml]
03:13
kleisli has quit [Ping timeout: 260 seconds]
03:14
quiso has joined #ocaml
03:14
quiso has left #ocaml [#ocaml]
03:17
Droheq_ has joined #ocaml
03:17
Droheq_ has left #ocaml [#ocaml]
03:17
Criephoakl has joined #ocaml
03:17
Criephoakl has left #ocaml [#ocaml]
03:19
<
companion_cube >
I wonder if we should set +s to force ssl here
03:19
<
companion_cube >
it tends to repel spammers afaik
03:20
eghiogray has joined #ocaml
03:20
eghiogray has left #ocaml ["hi"]
03:21
plah has joined #ocaml
03:21
plah has left #ocaml ["hi"]
03:22
Yoasl has joined #ocaml
03:22
Yoasl has left #ocaml ["hi"]
03:24
mbuf has joined #ocaml
03:34
tormen_ has quit [Ping timeout: 240 seconds]
03:35
kleisli has joined #ocaml
03:36
<
nicolaus >
Hi, I have this module1.ml then this module1.ml would like to create multiple instance of module2.ml
03:37
<
nicolaus >
how can i achieve this?
03:51
mfp has quit [Ping timeout: 245 seconds]
03:59
malina has quit [Remote host closed the connection]
04:01
oni-on-ion has quit [Remote host closed the connection]
04:01
oni-on-ion has joined #ocaml
04:17
mbuf has quit [Remote host closed the connection]
04:18
mbuf has joined #ocaml
04:46
oni-on-ion has quit [Ping timeout: 258 seconds]
04:55
callcc[m] has joined #ocaml
06:01
dborisog has joined #ocaml
06:03
malina has joined #ocaml
06:12
narimiran has joined #ocaml
06:35
vicfred has quit [Quit: Leaving]
06:35
<
vsiles >
nicolaus: can you be more explicit about their content and you mean by multiple instances ?
06:35
<
vsiles >
you might have to use "real" modules, and not file as modules (not sure)
06:42
<
nicolaus >
sorry, I named my files like [name]module.ml
06:43
<
nicolaus >
like one sort of main function would create multiple instances of one function
06:46
<
vsiles >
still a bit confused. Go to go commute, I'll be back afterwards. Feel free to drop some actual code if you can :)
06:57
<
nicolaus >
yes sorry, I also don't know how to specifically point it out on words without code. :)
07:28
mbuf has quit [Ping timeout: 258 seconds]
07:31
webshinra has joined #ocaml
07:39
Serpent7776 has joined #ocaml
07:54
<
callcc[m] >
I am making quickjs bindings in ocaml, and I have a problem
07:54
<
callcc[m] >
there are two different JSValue define in quickjs.h, decided by JS_NAN_BOXING .
07:54
<
callcc[m] >
my questions is, what is the best way to define JSValue in ctype?
07:58
Serpent7776 has quit [Remote host closed the connection]
07:59
Serpent7776 has joined #ocaml
08:25
mbuf has joined #ocaml
08:38
<
vsiles >
nicolaus: back online. Feel free to drop some examples :D
08:49
RalfJ has quit [Remote host closed the connection]
08:50
RalfJ has joined #ocaml
09:08
mbuf has quit [Ping timeout: 255 seconds]
09:08
mbuf has joined #ocaml
09:39
toppler` is now known as toppler
09:41
nullcone has quit [Quit: Connection closed for inactivity]
09:44
RalfJ has quit [Ping timeout: 272 seconds]
09:45
<
nicolaus >
hi vsiles, as far as I have read and searched. I think the term is concurrency. Running the same lines of code via different threads.I don't know if it makes sense to you already
09:48
RalfJ has joined #ocaml
09:52
<
vsiles >
you have a function f in a module A and you want to run multiple instances of it on different inputs, concurrently, in a module B
09:52
<
vsiles >
something like that ?
09:56
<
nicolaus >
i am planning to call a function in module B from module A. module A stores the ID of all the instances of module B
09:57
<
nicolaus >
So, A decides which module B thread/process to kill
09:58
<
nicolaus >
I am also planning that module A can still send functions/signals to module B while running
09:58
<
nicolaus >
i don't have a sample code yet because I don't know still how to implement it.
10:01
<
vsiles >
What I don't get is what you mean by "intances of module B" ? If moduleB.ml wants to call a function in moduleA.ml, you just have to build them both and use moduleA.f() in moduleB. I guess it's the architecture of moduleB I'm not getting
10:01
<
def` >
maybe there is global state in the module?
10:15
kleisli has quit [Ping timeout: 255 seconds]
10:20
dmiles has quit [Ping timeout: 268 seconds]
10:29
<
nicolaus >
No, module A calls module B. moduleA then stores some kind of process ID's or any identifier of running instances of module B.
10:30
mbuf has quit [Quit: Leaving]
10:43
<
vsiles >
a module is a bunch of code, it's not a process/executable, so I'm really lost, sorry
10:48
<
vsiles >
do you want to do actual process management ? moduleA forks a bunch of new process executing moduleB, and keeping tab on them ?
10:54
<
nicolaus >
ahh that's why we did not understand each other, because i keep using module as a term. lol
10:54
<
nicolaus >
but yes, that's my plan
10:54
<
nicolaus >
and hopefully still be able to send out functions to these processes
12:22
<
vsiles >
I don't know much about system programming in ocaml but I'm pretty sure it provides fork/exec and things like that. If you want multi-thread (not processes), you should at least look at the Lwt library (but I'm not the best to answer about that)
12:22
dhil has joined #ocaml
12:22
ggole has joined #ocaml
12:29
<
nicolaus >
thanks vsiles
12:56
<
Leonidas >
Lwt does not do multi threading, in the same way as Async does not do multithreading
12:57
<
Leonidas >
nicolaus: I think you should describe the problem you want to solve, not your attempts to solve it since the way you describe things it makes it harder to understand
13:01
FreeBirdLjj has joined #ocaml
13:25
<
nicolaus >
Leonidas, these instances that I do want to keep track would receive asynchronous data and I want to work on those data immediately that's why I am thinking of implementing it by multiple threads of the same program/lines of code
13:26
sarna has joined #ocaml
13:37
<
Leonidas >
yeah, then you don't need any threads at all
13:37
<
Leonidas >
just use Async/Lwt
14:05
<
nicolaus >
ohh, ok. i'll check it out
14:05
<
nicolaus >
thank you so much for the help
14:18
mbuf has joined #ocaml
14:47
vicfred has joined #ocaml
14:55
rzmt has quit [Ping timeout: 265 seconds]
14:56
<
Nikkel >
I have a design question
14:56
<
Nikkel >
I want to use yojson to create a deriver for a list of (string, string list) assocs
14:56
<
Nikkel >
but I don't know how to define it here.
15:01
andreas303 has quit [Ping timeout: 240 seconds]
15:04
andreas303 has joined #ocaml
15:13
<
Leonidas >
an assoc is just a `(string, Yojson.t) list`
15:20
<
Leonidas >
nicolaus: oh, now I get it. You can't just specify random keys in assocs in ppx_deriving_yojson
15:20
dhil has quit [Ping timeout: 240 seconds]
15:21
<
Leonidas >
ppx_deriving_yojson maps a an JSON object to a record, and a record has to have fixed keys.
15:28
dhil has joined #ocaml
15:30
Serpent7776 has quit [Quit: Leaving]
15:31
spew has joined #ocaml
15:40
FreeBirdLjj has quit [Remote host closed the connection]
15:44
gareppa has joined #ocaml
16:00
gareppa has quit [Quit: Leaving]
16:03
<
companion_cube >
seems like +S kept the spammer away \o/
16:04
<
simpson >
The spam stopped hours ago, based on logs of the only other channel I saw which had it. There was not much, all told.
16:04
<
companion_cube >
still, it's interestingly correlated
16:05
<
simpson >
Sure. I'm merely trying to temper false-positive readings.
16:10
malina has quit [Ping timeout: 240 seconds]
16:12
<
companion_cube >
well it also worked on another chan I'm on, a while ago :)
16:16
<
reynir >
Yea, it works fairly well from what I hear, but it also keeps some legit users away I'm afraid
16:17
<
companion_cube >
I mean, who uses a client that can't SSL?
16:17
<
companion_cube >
bots, I understand, but clients…
16:18
<
reynir >
Probably basically none
16:20
FreeBirdLjj has joined #ocaml
16:25
FreeBirdLjj has quit [Ping timeout: 240 seconds]
16:38
dhil has quit [Ping timeout: 240 seconds]
16:45
nullifidian__ has joined #ocaml
16:48
nullifidian_ has quit [Ping timeout: 260 seconds]
16:48
<
CcxWrk >
I'm not sure if the official webchat is marked as TLS (even though people access it via HTTPS)
16:49
<
companion_cube >
what's the official webchat using, remind me?
16:50
<
CcxWrk >
Oh, they moved to Kiwi now. Was patched qWebIRC before I think.
16:52
<
companion_cube >
can't find the URL for that actually, where is it listed? :)
16:54
<
companion_cube >
I mean, I thought there was a link on ocaml.org or something :p
16:55
testcaml has joined #ocaml
16:55
<
testcaml >
ah, seems to work o/
16:55
testcaml has quit [Remote host closed the connection]
16:57
<
Leonidas >
(curiously, the link is behind Meetup (which finds 0 meetups in less than infinite distance from my location) and G+ (which is dead))
17:00
FreeBirdLjj has joined #ocaml
17:05
FreeBirdLjj has quit [Ping timeout: 248 seconds]
17:12
<
gahr >
I am trying to use let* but I get an error let operators are not supported before OCaml 4.08
17:12
<
gahr >
my compiler is 4.09
17:12
<
companion_cube >
are you sure you're in the right opam environment?
17:13
<
gahr >
at least by judjing by _build/log, which mentions /usr/home/gahr/.opam/4.09.0/bin/ocamlc.opt
17:13
<
gahr >
I have ppx_let v0.13.0 Monadic let-bindings
17:14
<
companion_cube >
not sure if you still need ppx_let though
17:14
<
gahr >
right I just tried with and without, same error
17:15
<
gahr >
core uses it, so I can't just uninstall it
17:17
<
companion_cube >
🤷 no idea then, sorry
17:18
<
gahr >
opam switch says
17:18
<
gahr >
→ 4.09.0 ocaml-base-compiler.4.09.0 4.09.0
17:18
<
companion_cube >
did you `eval $( opam env )` though?
17:18
<
companion_cube >
ah yeah, OMP, damn
17:22
<
gahr >
OPAM_SWITCH_PREFIX=/usr/home/gahr/.opam/4.09.0
17:22
<
gahr >
CAML_LD_LIBRARY_PATH=/usr/home/gahr/.opam/4.09.0/lib/stublibs:/usr/home/gahr/.opam/4.09.0/lib/ocaml/stublibs:/usr/home/gahr/.opam/4.09.0/lib/ocaml
17:22
<
gahr >
OCAML_TOPLEVEL_PATH=/usr/home/gahr/.opam/4.09.0/lib/toplevel
17:23
<
companion_cube >
yeah it's just that a library tries to port your code back to the 4.07 AST
17:23
<
companion_cube >
which doesn't have let operators
17:25
<
gahr >
how do I figure which one?
17:25
<
gahr >
must be one of the ppx I'm using I guess
17:30
mbuf has quit [Read error: Connection reset by peer]
17:36
FreeBirdLjj has joined #ocaml
17:41
FreeBirdLjj has quit [Ping timeout: 240 seconds]
17:42
dhil has joined #ocaml
17:43
<
Leonidas >
most likely
17:43
<
Leonidas >
maybe you can then just use dune rewriting %)
17:43
<
companion_cube >
moar magic…
17:44
<
gahr >
I don't know what that means.. I'm very entry level..
17:44
ygrek__ has joined #ocaml
17:45
<
Leonidas >
gahr: dune has a mode where it does what ppx_let does but for the let* syntax
17:45
<
gahr >
ah cool, how do I turn it on?
17:45
<
Leonidas >
companion_cube: don't want to drop the @? :p
17:46
<
Leonidas >
personally I'm holding out and not using the let* syntax to begin with
17:47
<
companion_cube >
Leonidas: you scared? :p
17:47
<
Leonidas >
without a matching match* it is strictly less useful than ppx_let
17:48
<
gahr >
I'm using match (foo, bar) with | (Some foo, Some bar) -> Some (do something with foo and bar) | _ -> None
17:48
<
gahr >
let* foo = foo in let* bar = bar in Some (do soemthing with foo and bar)
17:48
<
Leonidas >
one could argue that the way the monad is specified in ppx_let is somewhat clearer but thats arguable and frankly I don't really use it
17:48
<
companion_cube >
I also holding out from all ppx :p
17:49
<
gahr >
that might help...
17:49
<
Leonidas >
gahr: I often have cases like `match%map request () with | Ok v -> … | Error … -> …`
17:50
<
Leonidas >
with let I would need to introduce a rather pointless binding
17:50
<
gahr >
got to run, thanks
17:50
<
companion_cube >
is it like `request () >|= function …` ?
17:50
<
Leonidas >
companion_cube: yes
17:50
<
dash >
Not gonna let automation steal your code writing job eh
17:50
<
Leonidas >
companion_cube: I actually used that a lot even in my Lwt code
17:52
<
companion_cube >
yeah `match%lwt` was nice
17:52
<
Leonidas >
`match%bind` works with Lwt too :p
17:53
<
companion_cube >
god I hate pervasive monads so much
17:54
<
dash >
Ready for lessnads
17:54
<
companion_cube >
ready for effects
18:00
nullcone has joined #ocaml
18:06
dhil has quit [Ping timeout: 240 seconds]
18:19
FreeBirdLjj has joined #ocaml
18:24
FreeBirdLjj has quit [Ping timeout: 265 seconds]
18:25
FreeBirdLjj has joined #ocaml
18:30
Jesin has quit [Quit: Leaving]
18:30
FreeBirdLjj has quit [Ping timeout: 272 seconds]
18:32
Jesin has joined #ocaml
18:44
mahmudov has joined #ocaml
18:47
FreeBirdLjj has joined #ocaml
18:48
amiloradovsky has joined #ocaml
18:53
FreeBirdLjj has quit [Ping timeout: 248 seconds]
18:54
<
companion_cube >
gosh, batteries 3.0… didn't think I'd live to see that day :D
18:55
FreeBirdLjj has joined #ocaml
19:01
FreeBirdLjj has quit [Ping timeout: 272 seconds]
19:01
FreeBirdLjj has joined #ocaml
19:06
FreeBirdLjj has quit [Ping timeout: 240 seconds]
19:12
<
thizanne >
wait until it becomes trendy again
19:12
<
companion_cube >
I wouldn't hold my breath
19:24
FreeBirdLjj has joined #ocaml
19:27
mrd_ has joined #ocaml
19:28
mrd_ has quit [Client Quit]
19:28
FreeBirdLjj has quit [Ping timeout: 248 seconds]
19:29
mrd has quit [Quit: the quit message at the end of the universe]
19:31
mrd has joined #ocaml
19:31
mrd has quit [Changing host]
19:31
mrd has joined #ocaml
19:37
FreeBirdLjj has joined #ocaml
19:43
ggole has quit [Quit: Leaving]
19:43
kleisli has joined #ocaml
19:43
FreeBirdLjj has quit [Ping timeout: 272 seconds]
19:54
Jesin has quit [Quit: Leaving]
19:57
Jesin has joined #ocaml
20:00
andreas303 has quit [Remote host closed the connection]
20:03
andreas303 has joined #ocaml
20:12
dborisog has quit [Ping timeout: 240 seconds]
20:17
FreeBirdLjj has joined #ocaml
20:21
oni-on-ion has joined #ocaml
20:26
TC01 has quit [Ping timeout: 265 seconds]
20:27
FreeBirdLjj has quit [Ping timeout: 240 seconds]
20:33
TC01 has joined #ocaml
20:39
leah2 has quit [Remote host closed the connection]
20:40
leah2 has joined #ocaml
20:42
FreeBirdLjj has joined #ocaml
20:57
FreeBirdLjj has quit [Ping timeout: 248 seconds]
21:00
leah2 has quit [Remote host closed the connection]
21:01
leah2 has joined #ocaml
21:05
FreeBirdLjj has joined #ocaml
21:10
FreeBirdLjj has quit [Ping timeout: 260 seconds]
21:11
FreeBirdLjj has joined #ocaml
21:16
FreeBirdLjj has quit [Ping timeout: 240 seconds]
21:24
FreeBirdLjj has joined #ocaml
21:29
FreeBirdLjj has quit [Ping timeout: 248 seconds]
21:30
narimiran has quit [Ping timeout: 258 seconds]
21:31
FreeBirdLjj has joined #ocaml
21:35
FreeBirdLjj has quit [Ping timeout: 245 seconds]
21:42
FreeBirdLjj has joined #ocaml
21:47
FreeBirdLjj has quit [Ping timeout: 272 seconds]
21:52
sagax has quit [Ping timeout: 272 seconds]
21:52
FreeBirdLjj has joined #ocaml
21:56
FreeBirdLjj has quit [Ping timeout: 240 seconds]
21:59
Jesin has quit [Quit: Leaving]
22:02
FreeBirdLjj has joined #ocaml
22:03
Jesin has joined #ocaml
22:04
amiloradovsky has quit [Ping timeout: 240 seconds]
22:04
amiloradovsky has joined #ocaml
22:05
TakinOver has quit [Remote host closed the connection]
22:07
FreeBirdLjj has quit [Ping timeout: 258 seconds]
22:08
Jesin has quit [Remote host closed the connection]
22:08
FreeBirdLjj has joined #ocaml
22:12
FreeBirdLjj has quit [Ping timeout: 248 seconds]
23:14
mahmudov has quit [Ping timeout: 265 seconds]
23:40
amiloradovsky has quit [Ping timeout: 248 seconds]