<nicoo>
python476: Do you really mean “matching on a length-1 list and returning this thing”? Because that would be so specialized it wouldn't have a name
<nicoo>
(Also, getting a length-1 'a list instead of a 'a directly sounds fishy)
rgrinberg has joined #ocaml
rand has joined #ocaml
jonludlam has quit [Ping timeout: 240 seconds]
raphaelss has joined #ocaml
seungjin has joined #ocaml
<python476>
not matchin per se, just some unwrapping function
<python476>
it feels list-monadic ... but I don't want to sound ..monadic
swgillespie has joined #ocaml
raphaelss has quit [Read error: Connection reset by peer]
seungjin has quit [Ping timeout: 264 seconds]
tmtwd has joined #ocaml
toolslive has quit [Ping timeout: 252 seconds]
nullcatxxx_ has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
nullcatxxx_ has joined #ocaml
nullcatxxx_ has quit [Client Quit]
prepor has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
<companion_cube>
but the PR's reason to exist is that syntax can favor bugs
FreeBird_ has joined #ocaml
darkf_ is now known as darkf
FreeBirdLjj has quit [Ping timeout: 265 seconds]
FreeBird_ has quit [Ping timeout: 260 seconds]
sepp2k has joined #ocaml
superboum has quit [Ping timeout: 240 seconds]
charpi`` is now known as charpi
pyon has quit [Quit: restart]
djellemah has quit [Read error: Connection reset by peer]
ely-se has quit [Quit: leaving]
mort___1 has joined #ocaml
mort___ has quit [Ping timeout: 246 seconds]
huza has joined #ocaml
prepor has joined #ocaml
Haudegen has quit [Ping timeout: 255 seconds]
rgrinberg has joined #ocaml
Haudegen has joined #ocaml
ely-se has joined #ocaml
rgrinberg has quit [Ping timeout: 260 seconds]
superboum has joined #ocaml
djellemah has joined #ocaml
<libertas>
hi, just a beginner question: if date is a record, why does this return a syntax error: let next date = let date.minute = date.minute + 1 in date;;
<flux>
"let date.minute =", what should it do?
<flux>
if you're thinking 'write a new value to a record field', then no, let doesn't do that
<flux>
is the date.minute field mutable in the first place? how is it defined?
<libertas>
just to alter the value of a field
<ely-se>
I think you want: let next date = { date with minute = date.minute + 1 };;
<libertas>
humm, the brackets
<flux>
libertas, depending on how the type of 'date' is defined, that may be impossible. but what ely-se is suggesting that return a new version of the date with the one field changed.
<MercurialAlchemi>
toolslive: well... I don't know
<MercurialAlchemi>
I had to disable the git module and codelens to get my CPU back
<MercurialAlchemi>
also, you get to work with MSBuild
<MercurialAlchemi>
MSBuild would be less shitty without VS, I imagine, because it is clearly made to be edited by clicky people through Visual Studio, which is why doing anything semi-complex (or trying to figure out what the hell it's doing) is such a pain
<MercurialAlchemi>
the big things missing for the perfect OCaml experience on Linux are (IMHO): out-of-the-box recompilation, project-wide renaming from merlin, and a debugger which doesn't suck
<companion_cube>
same, except recompilation is trivial with inotify ;)
<MercurialAlchemi>
companion_cube: yeah, I also hacked something together, but "good experience" includes "working out of the box", not "reading 50 pages of how to configure various tools"
<toolslive>
and various profiling tools
<toolslive>
that don't suck
<MercurialAlchemi>
yeah
<MercurialAlchemi>
but I use profiling rarely, I'd be happy to be already 90% there
<def`>
+ I want GUIs, for visualization
<toolslive>
I tend to use callgrind, which is ok-ish. but I still need something to find memory leaks in a big codebase
<toolslive>
and a decent simple code generation tool (ppx ain't it)
<toolslive>
and decent multi core
ely-se has joined #ocaml
tmtwd has joined #ocaml
<MercurialAlchemi>
multi core isn't a tooling problem
<MercurialAlchemi>
though it can easily make for tooling problems :)
<MercurialAlchemi>
def`: visualisation of what?
<toolslive>
the thread was "xxx in 2015 sucks the same way as xxx in 2014" so 'multi core in ocaml' qualifies
<def`>
MercurialAlchemi: heap values
lyxia has quit [Ping timeout: 252 seconds]
tobiasBora has quit [Ping timeout: 264 seconds]
Maelan has quit [Ping timeout: 264 seconds]
<MercurialAlchemi>
toolslive: ah... I had narrowed it down to emacs/vim+merlin vs VS: return of the vengeance of the final battle
sgnb` has quit [Read error: Connection reset by peer]
bernardofpc has quit [Ping timeout: 268 seconds]
sgnb` has joined #ocaml
bernardofpc has joined #ocaml
sepp2k has joined #ocaml
rgrinberg has joined #ocaml
tobiasBora has joined #ocaml
lyxia has joined #ocaml
Maelan has joined #ocaml
<jmasseo>
toolslive: i solved that pex problem it fed me. kind of fun.
tmtwd has quit [Ping timeout: 260 seconds]
tmtwd has joined #ocaml
<companion_cube>
this moment where you add one type parameter to every type
<jmasseo>
can studio speak ocaml?
<jmasseo>
is F# close enough?
s1n4 has quit [Quit: leaving]
pacmann has joined #ocaml
darkf has quit [Read error: Connection reset by peer]
darkf has joined #ocaml
sgnb` has quit [Read error: Connection reset by peer]
<Leonidas>
last time i saw F#, it looked rather different from ocaml
<Leonidas>
like an ML with C# syntax shoveled in.
<Leonidas>
jmasseo: what do you mean with "speak"?
<Leonidas>
execute it? highlight it?
sgnb has joined #ocaml
<jmasseo>
highlight it.
<ggole>
companion_cube: isn't it fun when your text editor is more helpful than your language at dealing with your language!
<jmasseo>
yeah i know F# had linq and stuff.
<companion_cube>
ggole: I'm not sure that my editor is up to the task
<jmasseo>
could always write OCaml support for VS.
<Leonidas>
toolslive: depends on what you consider. C# does not feel superior to OCaml to me, full of pesky objects ;-)
<jmasseo>
kind of like the python tools
<jmasseo>
tie in merlin and everything
<Leonidas>
jmasseo: I mean, sure you could. But what do you win by it?
<Leonidas>
when you start writing your language plugin from scratch, I don't see how much visual studio helps you with that besides providing a widget for displaying syntax highlighted text.
<jmasseo>
nothing, really.
<jmasseo>
emacs works fine.
<jmasseo>
it's got completion and highlighting
<jmasseo>
and you can write any feature that is missing.
<jmasseo>
a lot easier than you could in VS
<Leonidas>
I can see people wanting to have tools like Resharper, but that does not support OCaml either ;-)
<jmasseo>
the only benefits would come from a full integration
<jmasseo>
VS speaks GDB and LLDB now i think
<toolslive>
f# type providers are pretty sexy.
<jmasseo>
i might check out F# after i finish the ocaml mooc.
<jmasseo>
I like C# a lot for windows work
<jmasseo>
or multiplatform gui work
emaphis has joined #ocaml
<jmasseo>
i'm a sysadmin though, so that's almost always Pet Project type stuff.
<jmasseo>
at this gig we all have macs and all our stuff in debian in aws.
<jmasseo>
i would write work stuff in C# just to troll my peers.
MercurialAlchemi has quit [Ping timeout: 272 seconds]
jeffmo has joined #ocaml
mort___1 has joined #ocaml
mort___ has quit [Ping timeout: 246 seconds]
govg has quit [Ping timeout: 264 seconds]
govg has joined #ocaml
octachron has quit [Quit: Leaving]
ril has joined #ocaml
ril is now known as ril[away]
ril[away] is now known as ril
govg has quit [Ping timeout: 252 seconds]
mal`` has joined #ocaml
mal`` has quit [Max SendQ exceeded]
govg has joined #ocaml
mal`` has joined #ocaml
govg has quit [Ping timeout: 260 seconds]
jeffmo has quit [Quit: jeffmo]
ely-se has quit [Quit: leaving]
govg has joined #ocaml
govg has quit [Remote host closed the connection]
govg has joined #ocaml
ril has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
mort___1 has quit [Quit: Leaving.]
MercurialAlchemi has joined #ocaml
travisbrady has joined #ocaml
ril has joined #ocaml
mort___ has joined #ocaml
damason_afk has quit [Quit: No Ping reply in 180 seconds.]
damason has joined #ocaml
Guest38 has joined #ocaml
pacmann has quit [Remote host closed the connection]
bjorkintosh has quit [Ping timeout: 250 seconds]
slash^ has joined #ocaml
travisbrady has quit [Ping timeout: 264 seconds]
<charpi>
Hi, I am quite new to ocaml and lwt. Looking at lwt documentation I can see that the socket_domain can only be PF_UNIX | PF_INET |PF_INET6. Does anyone know if it is possible to create AF_NETLINK sockets ?
<flux>
charpi, you probably want to use a specific ocaml library for it. seems like this might be suitabe, though it uses some C library to do it: https://github.com/xapi-project/ocaml-netlink
<flux>
I'm guessing it might not play nice with lwt as-is, though
<charpi>
i see
poulpeux has joined #ocaml
ollehar has quit [Ping timeout: 265 seconds]
<charpi>
isn't easier to just glue some specific C functions and my Ocaml program ?
ygrek has joined #ocaml
<poulpeux>
Hello everyone. I've got a question for those who understand the Unix module. I'm looking for a way to execute a piece of shell code and get the standard output of the command in a separate channel, just like the open_process* function, but I would also like to get the exit code, like the system or create_process functions. However, the system function doesn't redirect stdout and the create_process* functions don't allow an
<poulpeux>
arbitrary piece of shell code. What should I do ?
Mercuria1Alchemi has joined #ocaml
beaver_pelt has joined #ocaml
<smondet>
poulpeux: use create_process with [| "sh"; "-c"; your_command |] ?
<beaver_pelt>
Hello
<charpi>
thanks flux. I will have a look to the netlink lib
<poulpeux>
smondet: Wonderful ! It does exactly what I was looking for ! Thank you !
<flux>
charpi, I'm sure though that if the library doesn't support LWT as is, it would be easy to modify to support it, and probably the changes would be accepted by the library author as well :)
<flux>
charpi, good luck! also it might not be the only available library, but it was the first google hit. ;)
<charpi>
flux: yes I could have tried google first. I was just a bit surprised that only IP sockets were supported
<orbifx>
also which package includes caml/alloc.h?
<Kakadu>
opam package?
<Kakadu>
alloc.h should be shipped with compiler
<Kakadu>
`ocamlc -where`/caml/alloc.h
<orbifx>
ok should that be included in the command: g++ `pkg-config --cflags Qt5Quick` -fPIC -c class2_c.cpp -o class2_c.o
^elyse^ has quit [Quit: Leaving...]
<orbifx>
as a pkg-config option if ocaml supports it or as a substritution as provided above?
<orbifx>
although to be honest this isn't your commands fault.. this should be in the include path, but Arch doesn't seem to have it. I will raise that to the package manager.
<orbifx>
types will not be getting any promotions, tough times..
<orbifx>
kakadu: is that browser tha one installable with opam?
<Kakadu>
orbifx: yep
govg has quit [Ping timeout: 240 seconds]
<orbifx>
kakadu: and what do you mean by "base" on it? Use it as an example application or for referencing types with it?!
<Kakadu>
1st one
<orbifx>
ok, just noticed it is a general reference browser, handy
<orbifx>
but it doesn't quit with Ctrl+Q
<Kakadu>
Alt+F4
ril has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
shinnya has quit [Ping timeout: 268 seconds]
<orbifx>
kakadu: are you on windows?
<Kakadu>
nope
destrius has quit [Remote host closed the connection]
<Kakadu>
Actually I installed some kind of plugin to disable Ctrl+Q in firefox....
<orbifx>
ok. I use xmonad, which by default doesn't have alt+f4
<orbifx>
most of the apps I use support ctrl+q
<orbifx>
have seen a shift+q
<orbifx>
so far so good kakadu
<orbifx>
i gotta pack it in for tonight but will probably get to continue tomorrow
<orbifx>
One suggestion, maybe I can contribute somehow to that eventually, is to make it have less boiler plate. Obscuring the OO stuff might be worth while.