<AltGr>
this time it seems I really have trouble accessing it
<AltGr>
How am I supposed to work withoug github ?
<AltGr>
:p
keen__________28 has joined #ocaml
keen__________27 has quit [Ping timeout: 246 seconds]
<ggole>
Make local commits for now?
<ggole>
But yeah, bit of a pain
<dmbaturin>
AltGr: If it was subversion, you would be in a real trouble. ;)
<AltGr>
git is not the trouble actually, OPAM's issue tracker is
<AltGr>
but it seems almost back to normal
<AltGr>
happy not to be a sysadmin at github right now
<ggole>
Indeed
<dmbaturin>
I wonder why big projects would choose github issues rather than their own bugtracker actually. The code hosting service is not a concern, but the issues are a typical cloud service that locks you in.
cesar_ has joined #ocaml
cesar_ is now known as Guest50837
Guest50837 has quit [Ping timeout: 256 seconds]
<AltGr>
dmbaturin, the integration of the issues with the PR mechanism _does_ provide additional value, it's very convenient to work with ; but that's indeed an issues and there are several plans to get a proper export of Github data
AlexRussia has quit [Ping timeout: 250 seconds]
AlexRussia has joined #ocaml
Algebr` has joined #ocaml
darkf_ has joined #ocaml
kakadu has joined #ocaml
Algebr has quit [Ping timeout: 265 seconds]
darkf has quit [Ping timeout: 265 seconds]
s1n4 has quit [Read error: Connection reset by peer]
shinnya has joined #ocaml
ygrek has joined #ocaml
leowzukw has joined #ocaml
ygrek has quit [Ping timeout: 244 seconds]
tianon has quit [Read error: Connection reset by peer]
tianon has joined #ocaml
psy_ has quit [Ping timeout: 250 seconds]
madroach has quit [Quit: leaving]
cesar_ has joined #ocaml
cesar_ is now known as Guest41121
Guest41121 has quit [Ping timeout: 256 seconds]
<reynir>
MercurialAlchemi: Århus is my hometown :o
Simn has joined #ocaml
tianon has quit [Read error: Connection reset by peer]
tianon has joined #ocaml
freling has joined #ocaml
mort___ has joined #ocaml
madroach has joined #ocaml
kushal has quit [Ping timeout: 245 seconds]
AltGr has left #ocaml [#ocaml]
xificurC has joined #ocaml
xificurC has quit [Quit: WeeChat 1.1.1]
Haudegen has quit [Ping timeout: 250 seconds]
oriba has joined #ocaml
Haudegen has joined #ocaml
tianon has quit [Read error: Connection reset by peer]
Kensan has joined #ocaml
tianon has joined #ocaml
<Kensan>
Hi
<Kensan>
I am planning to familiarize myself with functional programming and am thinking about learning both Ocaml and Haskell. Are there reasons to learn them in a particular order, e.g. first Ocaml then Haskell or the other way around?
<companion_cube>
both are interesting to learn, any order will do
<Drup>
Kensan: OCaml is probably a gentler introduction, because you don't need to jump into the functional bandwagon as quickly, and the purely functional stuff is not imediatly useful. You may learn quicker with Haskell (or don't understand a thing and be disgusted, it depends of people)
ghostpl_ has quit [Remote host closed the connection]
oriba has quit [Quit: oriba]
mengu has joined #ocaml
mengu has joined #ocaml
milosn has quit [Ping timeout: 250 seconds]
milosn has joined #ocaml
AlexRussia has quit [Ping timeout: 272 seconds]
idegen has joined #ocaml
shinnya has quit [Ping timeout: 264 seconds]
Nahra has quit [Remote host closed the connection]
ghostpl_ has joined #ocaml
ghostpl_ has quit [Ping timeout: 256 seconds]
avsm has joined #ocaml
darkf has quit [Quit: Leaving]
paradoja has joined #ocaml
avsm has quit [Quit: Leaving.]
cesar_ has joined #ocaml
cesar_ is now known as Guest58391
Guest58391 has quit [Ping timeout: 256 seconds]
JuggleTux has quit [Quit: leaving]
lewis1711 has joined #ocaml
idegen has quit [Ping timeout: 256 seconds]
tane has joined #ocaml
ghostpl_ has joined #ocaml
ghostpl_ has quit [Ping timeout: 246 seconds]
struktured has quit [Ping timeout: 252 seconds]
mort___ has quit [Ping timeout: 252 seconds]
struktured has joined #ocaml
robink_ has joined #ocaml
robink has quit [Quit: No Ping reply in 180 seconds.]
avsm has joined #ocaml
psy_ has joined #ocaml
seangrove has quit [Remote host closed the connection]
seangrove has joined #ocaml
avsm has quit [Quit: Leaving.]
leowzukw has quit [Quit: Lost terminal]
Haudegen has quit [Ping timeout: 252 seconds]
kushal has joined #ocaml
pyon has quit [Quit: My morality has evaporated under the harsh UV light.]
idegen has joined #ocaml
s1n4 has joined #ocaml
Haudegen has joined #ocaml
ghostpl_ has joined #ocaml
Hannibal_Smith has joined #ocaml
ghostpl_ has quit [Ping timeout: 272 seconds]
cesar_ has joined #ocaml
cesar_ is now known as Guest40056
Guest40056 has quit [Ping timeout: 256 seconds]
seangrove has quit [Ping timeout: 264 seconds]
kdef has joined #ocaml
seangrove has joined #ocaml
avsm has joined #ocaml
JuggleTux has joined #ocaml
<dmbaturin>
Kensan: I guess you will find OCaml's module system appealing. Haskell modules dump all the names into the main namespace if you import them, and there are no functors (modules parameterized by other modules where the parameter is required to implement specific signature).
AlexRussia has joined #ocaml
pyon has joined #ocaml
matason has joined #ocaml
<dmbaturin>
On the other hand, OCaml has no support for function overloading, which some people find annoying (+. -. etc. operators for floats etc.). Haskell's has overloading via type classes, but there are implications that make some people prefer no overloading at all. :)
pobivan has joined #ocaml
<lewis1711>
dmbaturin, type classes are one of the few things I like about haskell. what are their implications that you dislike?
<lewis1711>
(in practice the lack of overloaded functions only really annoys me in ocaml when there is a function for List that I want to use for Set or Array)
<Kensan>
dmbaturin: Thanks for the info.
<Kensan>
dmbaturin: You also use Ada, right? Did you pick up Ocaml before learning Ada?
larhat has joined #ocaml
<dmbaturin>
lewis1711: In everyday life, the length and complexity of error messages it often creates. :)
iorivur has joined #ocaml
<dmbaturin>
And that you easily can't provide e.g. different ordering for the same type in different cases.
<dmbaturin>
Kensan: Yep, that's why I mentioned the module system first.
<dmbaturin>
And no, I learnt it after Ada.
struktured has quit [Ping timeout: 272 seconds]
<Kensan>
dmbaturin: I see. If I may ask: are you currently working on a project with Ocaml and if so, why did you choose it over Ada?
<dmbaturin>
What you may find a bit limiting after Ada is lack of subtyping. Abstract types can help you enforce constraints, but no magical "1..100" and the like.
<dmbaturin>
Kensan: The big project I'm doing in OCaml handles quite fancy datastructures, algebraic types, parametric polymorphism, and immutability by default come in handy.
<Kensan>
dmbaturin: If I understand correctly, parametric polymorphism is akin to Ada's generics, right?
struktured has joined #ocaml
<dmbaturin>
Yes, except you don't need to instantiate them, it just works with any type.
<Kensan>
dmbaturin: Is your project hosted somewhere publicly where I might take a look?
<dmbaturin>
Yes, but it's quite an early stage, so it hardly will be representative for a while.
<dmbaturin>
I hope it will soon though. :)
<Kensan>
Just being curious :)
testcocoon has quit [Quit: Coyote finally caught me]
<dmbaturin>
Kensan: http://opam.ocaml.org/packages/ OPAM is the ocaml package manager, you may choose something from the package list to look into.
<Kensan>
Yeah, I just installed opam etc. Started reading Real World Ocaml.
<Kensan>
dmbaturin: So for your project you ditched Ada in favor of Ocaml?
<dmbaturin>
The standard warning: RWO uses a third-party library called Core everywhere, sometimes without mentioning it.
The_Mad_Pirate has quit [Excess Flood]
<dmbaturin>
You may or may not like Core, but in any case it's not a part of the language and you are free to use or not use it.
testcocoon has joined #ocaml
<dmbaturin>
Kensan: For this one, I evaluated several options. The first prototype was in python.
<dmbaturin>
(Which went badly, because python's dynamic typing and mutability made datastructure handling annoying, and no one was willing to contribute to the logic despite the use of a common language :)
mort___ has joined #ocaml
dhil has joined #ocaml
dsheets has joined #ocaml
<Kensan>
dmbaturin: I see.
dsheets has quit [Client Quit]
paradoja has quit [Remote host closed the connection]
<dmbaturin>
Kensan: For a quick description of what it does, I mainain a linux distro for routers (http://vyos.net) that has a single CLI for all network functions. There's a single config file from which actual iptables, quagga etc. configs are produced.
ghostpl_ has joined #ocaml
TheLemonMan has quit [Quit: leaving]
<dmbaturin>
The current backend written long ago has multiple problems, so I'm rewriting it. It handles config node operations (create, delete, rename etc.), checks if it doesn't violate any invariants and executes scripts that product the configs.
<Kensan>
dmbaturin: Yeah, I remember that we talked about that some time ago in #ada.
paradoja has joined #ocaml
<dmbaturin>
I hope some day my own routing protocols stack (which is in Ada, for obvious reasons) takes off and we'll replace quagga with it.
<dmbaturin>
There are many things quagga got right, and things it got very wrong.
The_Mad_Pirate has joined #ocaml
ghostpl_ has quit [Ping timeout: 248 seconds]
c74d has joined #ocaml
leowzukw has joined #ocaml
cesar_ has joined #ocaml
cesar_ is now known as Guest70877
<dmbaturin>
Backend problem is more urgent though. "Blocked by problems in the backend" is nearly a stock answer for many feature requests. :)
swgillespie has joined #ocaml
<dmbaturin>
Like remote API or atomic commit.
The_Mad_Pirate has quit [Ping timeout: 248 seconds]
Guest70877 has quit [Ping timeout: 246 seconds]
<Kensan>
dmbaturin: Sounds interesting (the project, not the problems ;)
<mahem1>
Do I really need to start creating a whole set of functors for each type?
<mahem1>
Like, get_ball_pos and get_box_pos or move_ball and move_box
<dmbaturin>
Sounds like a case for OOP.
thomasga has quit [Quit: Leaving.]
<mahem1>
Hmmm, was trying to avoid mutable objects. Or even objects having their own methods.
<mahem1>
But I guess it must be done...
thomasga has joined #ocaml
AlexRussia has quit [Ping timeout: 245 seconds]
<lewis1711>
mahem1, why do your objects need to be mutable?
AlexRussia has joined #ocaml
ericbmerritt has joined #ocaml
<mahem1>
lewis1711: They do not. Would it make sense to create an immutable object with no internal methods?
The_Mad_Pirate has joined #ocaml
<Drup>
well, you need at least accessors
<mrvn>
if you have an object with no methods then why not use a record?
leonidr has joined #ocaml
<mahem1>
By accessors I assume you mean "get" methods. Hmmm, not helpful either.
<lewis1711>
mrvn, because you can't write a function that performs on multiple records, even if they have a field in common. or can you? I thought you could, but maybe I am thinking of F#
mengu has quit [Remote host closed the connection]
mengu has joined #ocaml
mengu has joined #ocaml
<Drup>
lewis1711: no you can't, that's what the object type system is for
<Drup>
mahem1: what's the issue with accessors ?
The_Mad_Pirate has quit [Read error: Connection reset by peer]
The_Mad_Pirate has joined #ocaml
<Drup>
attributes are always private, so you need something to access their value anyway
unterstrom has joined #ocaml
<mahem1>
Drup: First off, I'm lazy and it's extra work. Secondly, it's putting more control into the internal object. (As oopposed to just using external functions)
mengu has quit [Ping timeout: 255 seconds]
<lewis1711>
looking at mahem1s code I would put "pos" and "vel" into their own independent record anyway
<Drup>
it's only for accessor, it's not really control ..
<mahem1>
Meaning that it's just one more interface. Objects can learn to lie. But no, not a big issue.
<mahem1>
lewis1711: If I did that then I could create a function that works for both Box.object_state and Ball.object_state?
<lewis1711>
well tbh I have no clue why each of them are their own module
matason has joined #ocaml
<lewis1711>
I'm a noob though so I should really shutup
mort___ has quit [Quit: Leaving.]
merry has quit [Remote host closed the connection]
<ggole>
mahem1: no, you need objects for that kind of polymorphism
swgillespie has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<mahem1>
lewis1711: Because they are two different type structues?
matason has quit [Ping timeout: 272 seconds]
<mahem1>
ggole: Fair enough. I'll see how far I get with using immutable objects. (And then probably break down and just us straight up mutable objects and inheritance.)
<lewis1711>
I'd probably also do "type coordinate = (int * int)" just to stop repeating yourself but meh
AlexRussia has joined #ocaml
<mahem1>
lewis1711: That gists is all good and dandy, but once your start writing a lot of code record names are going to conflict.
<lewis1711>
right, so put them in modules :P
<mahem1>
But then I get into the same issues as I had before, right?
<lewis1711>
no...
<mahem1>
Or I can use something like My_module.shape?
<lewis1711>
how are the ball and box in anyway different, except their shape?
ggole has quit []
<lewis1711>
with my code you could just write all your functions to take a type shape
<lewis1711>
and when you actually want to deal with the size (like a volume function or whatever), pattern match
unterstrom has quit [Ping timeout: 246 seconds]
<mahem1>
Not exactly. Like I have Ball and Box now. But potentially I might have something like a Car that also has a position and velocity (and an engine and model and wheels...)
jonludlam has quit [Remote host closed the connection]
matason has joined #ocaml
<lewis1711>
oh right. yeah use immutable objects then.
unterstrom has joined #ocaml
<mahem1>
:\ Fair enough.
<mahem1>
So what would we do without the O in Ocaml?
jonludlam has joined #ocaml
thomasga has quit [Quit: Leaving.]
<Drup>
mahem1: to be honest, if you only want a common little piece of data and no behavior at all
tnguyen has quit [Quit: tnguyen]
<Drup>
I would just define "type 'a data_thing = { content : 'a ; pos : int * int ; .... }"
matason has quit [Ping timeout: 244 seconds]
<mahem1>
So then everything that I wanted to give a position and velocity I could put in a data_thing. I guess that works.
unterstrom has quit [Ping timeout: 252 seconds]
<Drup>
(the downside is that you have an additional indirection to access the actual content)
struktured has quit [Ping timeout: 256 seconds]
shinnya has joined #ocaml
lordkryss has joined #ocaml
Haudegen has quit [Ping timeout: 248 seconds]
<mahem1>
Though would be interesting to create some type of standard hierarchy. (Like if content had a another "sub-type")
kushal has quit [Quit: Leaving]
<Drup>
you should really use objects for this kind of subtyping, I'm not sure to see what issues you have with that :)
<mrvn>
mahem1: and you can't put different 'a data_thing's into a list, array or hashtbl
<mrvn>
With objects you can have a common base class
s1n4 has quit [Ping timeout: 244 seconds]
<mahem1>
I just wanted to do things completely "functionally". Like that is why I am using Ocaml. Like if I want objects I can just use python...
<Drup>
You can do functional stuff with OCaml's objects
badon has quit [Disconnected by services]
badon_ has joined #ocaml
<Drup>
they are very different from the usual OOP.
badon_ is now known as badon
hugomg has joined #ocaml
ghostpl_ has joined #ocaml
<mahem1>
Fair enough. I'll try it out. Hope that they work for me. Anyways, thanks for the thoughts and input.
Haudegen has joined #ocaml
badon has quit [Ping timeout: 264 seconds]
swgillespie has joined #ocaml
cesar_ has joined #ocaml
cesar_ is now known as Guest67765
tnguyen has joined #ocaml
Guest67765 has quit [Ping timeout: 256 seconds]
swgillespie has quit [Read error: Connection reset by peer]
cthuluh has quit [Ping timeout: 256 seconds]
leowzukw has quit [Quit: Lost terminal]
swgillespie has joined #ocaml
unterstrom has joined #ocaml
mengu has joined #ocaml
swgillespie has quit [Max SendQ exceeded]
swgillespie has joined #ocaml
Hannibal_Smith has quit [Quit: Leaving]
tnguyen has quit [Ping timeout: 265 seconds]
tnguyen has joined #ocaml
avsm has quit [Quit: Leaving.]
iorivur has quit [Remote host closed the connection]
matason has joined #ocaml
oscar_toro has quit [Ping timeout: 252 seconds]
slash^ has quit [Read error: Connection reset by peer]
Submarine has quit [Remote host closed the connection]