adrien changed the topic of #ocaml to: Discussions about the OCaml programming language | http://www.ocaml.org | Current MOOC: https://huit.re/ocamlmooc | OCaml 4.04.0 release notes: http://ocaml.org/releases/4.04.html | Try OCaml in your browser: http://try.ocamlpro.com | Public channel logs at http://irclog.whitequark.org/ocaml
bronsen has quit [Ping timeout: 245 seconds]
reynir1 has joined #ocaml
gjaldon__ has quit [Ping timeout: 245 seconds]
banjiewen has quit [Ping timeout: 245 seconds]
M-martinklepsch has quit [Ping timeout: 245 seconds]
M-Illandan has quit [Ping timeout: 245 seconds]
rom1504 has quit [Ping timeout: 245 seconds]
bitbckt has quit [Ping timeout: 245 seconds]
thizanne has quit [Ping timeout: 245 seconds]
thizanne has joined #ocaml
rjungemann has quit [Ping timeout: 245 seconds]
vinoski has quit [Ping timeout: 245 seconds]
bigs_ has quit [Ping timeout: 245 seconds]
mehdib has quit [Ping timeout: 245 seconds]
MightyJoe has quit [Ping timeout: 245 seconds]
yetanotherion[m] has quit [Ping timeout: 245 seconds]
reynir has quit [Ping timeout: 245 seconds]
mehdib has joined #ocaml
vinoski has joined #ocaml
banjiewen has joined #ocaml
cyraxjoe has joined #ocaml
rjungemann has joined #ocaml
yetanotherion[m] has joined #ocaml
gjaldon__ has joined #ocaml
rom1504 has joined #ocaml
M-martinklepsch has joined #ocaml
M-Illandan has joined #ocaml
tane has quit [Quit: Leaving]
_whitelogger has joined #ocaml
fre has joined #ocaml
bitbckt has joined #ocaml
AlexDenisov has joined #ocaml
fre has quit [Ping timeout: 252 seconds]
fre has joined #ocaml
regnat[m] has joined #ocaml
Algebr has joined #ocaml
tane has joined #ocaml
mengu has joined #ocaml
frefity has quit [Ping timeout: 260 seconds]
dhil has joined #ocaml
<Onemorenickname> hello people
<Onemorenickname> i was wondering if there was some debugging-mode-compilation to ocaml
<Onemorenickname> so i could retrieve function names for instance
<Onemorenickname> or set stop-point
<Onemorenickname> things like that
mengu has quit [Remote host closed the connection]
<Onemorenickname> def`_, actually, it does not work, because I don't know any equality such that "lazy (Lazy.force x)) = x"
<Onemorenickname> (the classic polymorphic equality does not work here because of cyclic stuff)
frefity has joined #ocaml
malina has quit [Ping timeout: 260 seconds]
freusque has joined #ocaml
malina has joined #ocaml
aspiwack[m] has joined #ocaml
srenatus[m] has joined #ocaml
M-jimt has joined #ocaml
timclassic has joined #ocaml
M-martinklepsch has joined #ocaml
Bluddy[m] has joined #ocaml
na9da[m] has joined #ocaml
yetanotherion[m] has joined #ocaml
M-Illandan has joined #ocaml
ktosiek[m] has joined #ocaml
hpd[m] has joined #ocaml
M-ErkkiSeppl has joined #ocaml
AlexRussia has quit [Ping timeout: 260 seconds]
<orbifx> Onemorenickname: i think there is
<orbifx> -g
<Onemorenickname> orbifx, i'm having supra-bugs
<Onemorenickname> like, non-deterministic bugs, with no input and network
<Onemorenickname> and no concurrency
<Onemorenickname> i'm basically just running the same programs and getting different results
AlexDenisov has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
<def`_> Onemorenickname: equality is not defined on lazy values
<Onemorenickname> def`_, even physical equality ?
<def`_> even physical equality
<Onemorenickname> oh
<def`_> because a run of the gc can short-circuit some lazy values
<Onemorenickname> i tried with the interpreter some things, i got relatively consistent results
<Onemorenickname> ooooooh
<Onemorenickname> that explains my non-determinism.
<Onemorenickname> and why adding some random code at random places made it work with higher probability
<def`_> I had the same problem, it was a painful bug track :)
<Onemorenickname> so.....
<Onemorenickname> i have to force everything before adding to hashtbls and comparing ?
<Onemorenickname> well, I can force at creation time actually
<Onemorenickname> wait
orbifx has quit [Ping timeout: 268 seconds]
<Onemorenickname> hm
<def`_> but.. the hash of a value will change when it is force
<def`_> you cannot use lazy as hashtable keys
mengu has joined #ocaml
<def`_> that's how merlin does lazy equality
<Onemorenickname> def`_, i think i will simply use the lazyness for the construction of the cyclic values
<Onemorenickname> and loop through the values to "unlazy them"
<Onemorenickname> and then, use them as it
shinnya has joined #ocaml
<def`_> yes, that's a sane use
<Onemorenickname> the recursive loop is easy, because there is Lazy.status or something like that
<Onemorenickname> I should have thought of that sooner
<def`_> you are trying to solve difficult problems (equality of cyclic structures eventually non finite structures)
Onemorenickname has quit [Read error: Network is unreachable]
<def`_> just with the runtime, sadly it cannot handle this properly. You should be very careful when cyclic or lazy values, and always when using polymorphic functions
Onemorenickname has joined #ocaml
silver has joined #ocaml
sz0 has joined #ocaml
fre2 has joined #ocaml
freusque has quit [Ping timeout: 264 seconds]
regnat[m] has quit [Ping timeout: 252 seconds]
tane has quit [Quit: Leaving]
bronsen has quit [Ping timeout: 252 seconds]
Onemorenickname has quit [Ping timeout: 260 seconds]
djellemah_ has joined #ocaml
djellemah_ has quit [Remote host closed the connection]
M-ErkkiSeppl has quit [Ping timeout: 252 seconds]
regnat[m] has joined #ocaml
AlexRussia has joined #ocaml
M-ErkkiSeppl has joined #ocaml
aspiwack[m] has quit [Ping timeout: 264 seconds]
aspiwack[m] has joined #ocaml
mengu has quit [Remote host closed the connection]
mengu has joined #ocaml
hpd[m] has quit [Ping timeout: 252 seconds]
bigs_ has quit [Ping timeout: 252 seconds]
mengu has quit [Remote host closed the connection]
bigs_ has joined #ocaml
hpd[m] has joined #ocaml
fre has quit [Ping timeout: 252 seconds]
fre2 has quit [Quit: WeeChat 1.4]
freusque has joined #ocaml
AlexDenisov has joined #ocaml
dhil has quit [Ping timeout: 252 seconds]
sepp2k has joined #ocaml
regnat[m] has quit [Ping timeout: 252 seconds]
regnat[m] has joined #ocaml
AlfredENeuman has quit [Ping timeout: 240 seconds]
AlfredENeuman has joined #ocaml
zpe has joined #ocaml
<tobiasBora> Great, plplot binding works !
bronsen has joined #ocaml
<tobiasBora> By the way, I have a question :
freechips has quit [Ping timeout: 255 seconds]
<tobiasBora> what is the good way (let's say in the graphics environment) to draw a cut ellipse
Algebr has quit [Remote host closed the connection]
<tobiasBora> for example half of an ellipse
<tobiasBora> I'm stupid
<tobiasBora> there is a fill_arc method
fre has joined #ocaml
freechips has joined #ocaml
<tobiasBora> And another question:
<tobiasBora> is it possible to do antialiasing on the Graphics library ?
<tobiasBora> The circles I'm drawing are very ugly
<n4323> no idea. afaik the shipped Graphics library is not sophisticated in any way - more for educational use
snowcrshd has joined #ocaml
<tobiasBora> Ok. It's too bad, because if I'm not wrong it's the only graphical library installed by default on both linux and windows
d0nn1e has quit [Ping timeout: 240 seconds]
srenatus[m] has quit [Ping timeout: 252 seconds]
d0nn1e has joined #ocaml
AlexRussia has quit [Ping timeout: 240 seconds]
srenatus[m] has joined #ocaml
fre has quit [Ping timeout: 252 seconds]
hpd[m] has quit [Ping timeout: 252 seconds]
hpd[m] has joined #ocaml
AlexRussia has joined #ocaml
srenatus[m] has quit [Ping timeout: 252 seconds]
fre has joined #ocaml
foo30303 has joined #ocaml
tormen has joined #ocaml
AlexDenisov has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
mengu has joined #ocaml
zv has quit [Ping timeout: 268 seconds]
spew has joined #ocaml
srenatus[m] has joined #ocaml
jamesst20 has joined #ocaml
jamesst20 has quit [Ping timeout: 264 seconds]
Onemorenickname has joined #ocaml
AltGr has quit [Ping timeout: 264 seconds]
edwin has quit [Ping timeout: 264 seconds]
vinoski has quit [Ping timeout: 252 seconds]
vinoski has joined #ocaml
edwin has joined #ocaml
dhil has joined #ocaml
jabroney has joined #ocaml
fre2 has joined #ocaml
fre has quit [Ping timeout: 260 seconds]
jnavila has joined #ocaml
mengu has quit [Quit: Leaving...]
srenatus[m] has quit [Ping timeout: 252 seconds]
oo6 has joined #ocaml
fre2 has quit [Ping timeout: 252 seconds]
jnavila has quit [Ping timeout: 264 seconds]
freechips has quit [Ping timeout: 264 seconds]
regnat[m] has quit [Ping timeout: 252 seconds]
Onemorenickname has quit [Ping timeout: 264 seconds]
<oo6> join #linux
Onemorenickname has joined #ocaml
regnat[m] has joined #ocaml
srenatus[m] has joined #ocaml
MercurialAlchemi has quit [Ping timeout: 240 seconds]
jamesst20 has joined #ocaml
freechips has joined #ocaml
jamesst20 has quit [Ping timeout: 252 seconds]
shinnya has quit [Ping timeout: 240 seconds]
al-damiri has joined #ocaml
M-Illandan has quit [Ping timeout: 252 seconds]
AlexDenisov has joined #ocaml
eimantas has joined #ocaml
M-Illandan has joined #ocaml
djellemah has quit [Ping timeout: 260 seconds]
djellemah has joined #ocaml
spew has quit [Ping timeout: 260 seconds]
freusque has quit [Ping timeout: 260 seconds]
ryanartecona has joined #ocaml
freehck has joined #ocaml
Otze has joined #ocaml
oo6 has quit [Ping timeout: 240 seconds]
<Onemorenickname> i don't know any other languages with ocaml's functors
<Onemorenickname> i'm wondering why
Otze has quit [Client Quit]
<Onemorenickname> is the theory behind new / hard ?
oo6 has joined #ocaml
<Leonidas> SML
sh0t has joined #ocaml
spew has joined #ocaml
timclassic has quit [Ping timeout: 252 seconds]
regnat[m] has quit [Ping timeout: 252 seconds]
timclassic has joined #ocaml
snowcrshd has quit [Remote host closed the connection]
johnf_ has quit [Read error: Connection reset by peer]
MercurialAlchemi has joined #ocaml
johnf_ has joined #ocaml
freusque has joined #ocaml
oo6 has quit [Quit: Leaving]
foo30303 has quit [Quit: leaving]
regnat[m] has joined #ocaml
<Leonidas> Functors require a kind of ML-like module system, so the amount of languages which qualify is limited :)
Onemorenickname_ has joined #ocaml
Onemorenickname has quit [Ping timeout: 252 seconds]
ryanartecona has quit [Quit: ryanartecona]
freusque has quit [Ping timeout: 252 seconds]
Onemorenickname_ has quit [Read error: Network is unreachable]
Onemorenickname_ has joined #ocaml
ryanartecona has joined #ocaml
spew has quit [Ping timeout: 260 seconds]
dhil has quit [Ping timeout: 252 seconds]
octachron has joined #ocaml
ciniglio has joined #ocaml
malina has quit [Ping timeout: 264 seconds]
Onemorenickname_ has quit [Read error: Network is unreachable]
Onemorenickname_ has joined #ocaml
alfredo has quit [Quit: Textual IRC Client: www.textualapp.com]
freusque has joined #ocaml
sz0 has quit [Quit: Connection closed for inactivity]
freusque has quit [Ping timeout: 240 seconds]
larhat has quit [Quit: Leaving.]
larhat has joined #ocaml
larhat has quit [Client Quit]
copy` has joined #ocaml
TarVanimelde has joined #ocaml
zpe has quit [Remote host closed the connection]
AlexDenisov has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
nicoo has quit [Remote host closed the connection]
nicoo has joined #ocaml
aspiwack[m] has quit [Remote host closed the connection]
regnat[m] has quit [Read error: Connection reset by peer]
M-jimt has quit [Read error: Connection reset by peer]
srenatus[m] has quit [Read error: Connection reset by peer]
Bluddy[m] has quit [Write error: Connection reset by peer]
yetanotherion[m] has quit [Write error: Connection reset by peer]
M-martinklepsch has quit [Write error: Connection reset by peer]
ktosiek[m] has quit [Write error: Connection reset by peer]
M-Illandan has quit [Write error: Connection reset by peer]
M-ErkkiSeppl has quit [Read error: Connection reset by peer]
na9da[m] has quit [Write error: Connection reset by peer]
timclassic has quit [Read error: Connection reset by peer]
hpd[m] has quit [Read error: Connection reset by peer]
TarVanimelde has quit [Quit: TarVanimelde]
<infinity0> not many languages have higher-kinded types. there are other ways to do things besides ocaml's functors system though
<infinity0> haskell and scala let you express similar types of abstraction and IMO the way they do it is cleaner than in ocaml
<infinity0> there is an in-progress ocaml feature called "modular implicits" that does similar things but it's stuck atm on certain issues i don't know the details of
<infinity0> Onemorenickname_: ^
ryanartecona has quit [Quit: ryanartecona]
<Onemorenickname_> infinity0, in haskell, I can not have "local types"
<infinity0> you don't need to have local types, you can express them with higher-kinded type constructors
<Onemorenickname_> like, abstracting a type into a functor argument, and then, I don't have to write "'a shlobobo -> 'b shlababa"
<Onemorenickname_> I asked how to do that in haskell on #haskell, I4ve been told it's impossible in haskell
<infinity0> it's impossible to do exactly that, but you can arrange your program slightly differently to accomplish the equivalent thing
<Onemorenickname_> i'd lilke to know a way to do so
<Onemorenickname_> if you have an example
<Onemorenickname_> a way so i don't have to write "'a 'b 'c shlobobo" in every function, yet retaining polymorphism
<infinity0> lol... these days because the main thing i'm writing is in ocaml, i'm usually trying to translate in the other direction, from haskell to ocaml
<infinity0> but sure i'll have a go, if you want to paste me a starting example
<infinity0> in ocaml that is, and i'll translate it into what i'd write in haskell
<Onemorenickname_> hm, i'll take a minimal example
BitPuffin|osx has joined #ocaml
<Onemorenickname_> infinity0,
ryanartecona has joined #ocaml
slash^ has joined #ocaml
dhil has joined #ocaml
ygrek has joined #ocaml
regnat[m] has joined #ocaml
yomimono has joined #ocaml
<infinity0> Onemorenickname_: oh i see what you mean, you can't do "complex_t" in haskell without the polymorphic type params
<infinity0> still, what you can do is equivalent:
<infinity0> even in ocaml i would define those outside of BigModule anyways, i try to avoid those sorts of module features as far as possible
<Onemorenickname_> infinity0, why so ?
<Onemorenickname_> i find it cool that when I have several polymorphic parameters, i can abstract them
<Onemorenickname_> (when i get higher order polymorphic parameters, it's god-send)
orbifx has joined #ocaml
<infinity0> i think it's clearer to have the type parameters be explicit and i haven't needed to nest modules that deeply
<Onemorenickname_> i see
<infinity0> and when you need to nest many complex types together, most of the time there remains 2 or 3 type parameters
<infinity0> because the intermediate aliases share type params (e.g. Complex and UltraComplex both share t1, t2 in f and g, in your example)
<Onemorenickname_> indeed, but keeping track of which types are equal and so on is a high burden
<Onemorenickname_> (at least for me)
<infinity0> it's easier to read in the long run, i feel
<infinity0> i also have a slight incentive to make my code easily-translatable to haskell and other languages in the long run
SpaceSheep has joined #ocaml
<Onemorenickname_> infinity0, curiosity : where does that incentive comes from ?
<infinity0> dunno, hard to explain in a few sentences
<infinity0> i don't like to lock myself too deeply into a particular language, OTOH i am happy to lock myself into more "mathematical" features of a language that i can see implemented in many many different languages
<infinity0> universally-quantified type polymorphism are in enough languages i "like" that i'm happy to use it all over the place in my code, but the ocaml module system not so much
<Onemorenickname_> I see
<Onemorenickname_> that's why i wondered earlier why not many languages had ocaml's functors
<Onemorenickname_> and if there was any theory behind
<infinity0> the modular implicits paper is quite nice, it has a fair bit of theory
<infinity0> linking ocaml, haskell and scala together
<infinity0> scala and rust do let you define locally abstract types btw
<infinity0> inside "traits" that is. they are probably a bit closer to ocaml's modules, than haskel typeclasses
Anarchos has joined #ocaml
AltGr has joined #ocaml
jnavila has joined #ocaml
larhat has joined #ocaml
<Onemorenickname_> infinity0, about polymorphism, do you know of a language where you can specify something along the line of "(implicit_cast int string string_of_int)", and from there, if I do "print (~implicit) 5", I get "5" ?
<infinity0> this is exactly what is covered in the modular implicits paper :p
<Onemorenickname_> perfect, i'm beginning read this
<Onemorenickname_> but i did not know if there was such a system
<Onemorenickname_> as it's more "practical" than theoritical
<Onemorenickname_> (the hard part is in getting a coherent type of the value, not casting it)
<infinity0> yeah, it's not "cast" per se, there does have to exist somewhere a function that does the actual conversion safely
ygrek has quit [Ping timeout: 252 seconds]
<Onemorenickname_> yep
<Onemorenickname_> i use the cast terminology because i come from c
<infinity0> aha
<infinity0> you would probably also find rust interesting in that case, the first rust compiler was originally written in ocaml
dhil has quit [Ping timeout: 264 seconds]
Onemorenickname_ has quit [Ping timeout: 260 seconds]
aspiwack[m] has joined #ocaml
srenatus[m] has joined #ocaml
timclassic has joined #ocaml
M-jimt has joined #ocaml
M-martinklepsch has joined #ocaml
na9da[m] has joined #ocaml
Bluddy[m] has joined #ocaml
M-Illandan has joined #ocaml
yetanotherion[m] has joined #ocaml
hpd[m] has joined #ocaml
ktosiek[m] has joined #ocaml
M-ErkkiSeppl has joined #ocaml
Fistine has joined #ocaml
larhat1 has joined #ocaml
larhat has quit [Read error: Connection reset by peer]
ygrek has joined #ocaml
rcsole has joined #ocaml
Anarchos has quit [Quit: Vision[0.9.7-H-20140108]: i've been blurred!]
<rcsole> Hi everyone! I'm trying to setup a project with several subfolders with exercises and tests inside each subfolder. I'm struggling to figure out how to run every test inside each subfolder in OCaml (yes, I am new to OCaml). Any help and/or pointers to relevant documentation would be extremely helpful!
milodavis has quit [Quit: WeeChat 1.0.1]
larhat has joined #ocaml
larhat1 has quit [Read error: No route to host]
larhat1 has joined #ocaml
tane has joined #ocaml
larhat has quit [Ping timeout: 260 seconds]
larhat has joined #ocaml
larhat1 has quit [Read error: No route to host]
larhat1 has joined #ocaml
jamesst20 has joined #ocaml
larhat has quit [Read error: No route to host]
<zozozo> rcsole: how are you building yours tests / do tests depend on each other ?
<rcsole> no, they don't depend on each other
<rcsole> i'm not even sure how to build them to be fair, i'm having a hard time going through the ounit documentation
<zozozo> so, each of your files define one or more ounit tests ?
<rcsole> yes!
larhat has joined #ocaml
<zozozo> so first you need to have one file when you gather (e.g. build a list of) all these tests and run them using the ounit runner, then build and execute that file
<rcsole> i see
<rcsole> that makes sense
larhat1 has quit [Ping timeout: 264 seconds]
<rcsole> i'll try to get it working! thank you @zozozo
noddy has quit [Ping timeout: 252 seconds]
larhat1 has joined #ocaml
larhat has quit [Ping timeout: 240 seconds]
jamesst20 has quit [Remote host closed the connection]
jamesst20 has joined #ocaml
octachron has quit [Quit: Leaving]
andreas__ has quit [Quit: Connection closed for inactivity]
larhat1 has quit [Read error: No route to host]
larhat has joined #ocaml
TheLemonMan has joined #ocaml
jamesst20 has quit [Ping timeout: 268 seconds]
yomimono has quit [Ping timeout: 240 seconds]
larhat1 has joined #ocaml
MercurialAlchemi has quit [Ping timeout: 252 seconds]
larhat has quit [Ping timeout: 260 seconds]
thegameg has quit [Quit: Bye bye.]
thegameg has joined #ocaml
thegameg has quit [Client Quit]
thegameg has joined #ocaml
SpaceSheep has quit [Ping timeout: 260 seconds]
thegameg has quit [Client Quit]
SpaceSheep has joined #ocaml
thegameg has joined #ocaml
MercurialAlchemi has joined #ocaml
Onemorenickname has joined #ocaml
<Onemorenickname> infinity0, sorry, i got disconnected D:
<infinity0> Onemorenickname: ah, the last thing i said was just "you would probably also find rust interesting in that case, the first rust compiler was originally written in ocaml"
<infinity0> in response to "i come from c"
<Onemorenickname> i see
<Onemorenickname> i did not like the rust type system when i saw it
<infinity0> oh, which parts?
AlexDenisov has joined #ocaml
<Onemorenickname> infinity0, the different kind of references
<Onemorenickname> i'd prefer a language where you can build your own model checking stuff
<Onemorenickname> i guess it's practical, it's just I don't like it
<infinity0> ah, they've removed those now, there's only one type of reference (plus unsafe "raw" pointers but you don't usually want to use those)
<infinity0> however there are still 3 different types of "function" depending on how they use/consume the free variables which is what stopped me from writing more abstract stuff in it
<Onemorenickname> it's been a while since i've looked into it
<Onemorenickname> i did not know the language had evolved that much
<maurer> Now, there are only two kinds of references - & and &mut
<infinity0> 1.0 was about 1-2 years ago and they've tried to keep it more stable since that time
<infinity0> oh, i was just counting that as 1 maurer. before 1.0 they had garbage-collected references and other things too
<maurer> Yeah, I'm a little sad that despite all their hullabloo about "gc pointers will come back as a lib"
<maurer> none have actually appeared
<maurer> so you just need to use Rc and Weak and careful data structure design
<Onemorenickname> (i don't like default gc)
<maurer> I'm all for doing proper memory management for fastpath parts of programs, but sometimes it's nice to just declare a gc'd variable
<maurer> and not have to worry abou tit
<Onemorenickname> (or gc in general actually)
<Onemorenickname> by the way, I have a programming problem in ocaml
<Onemorenickname> i'm trying to make a grammar_of_pregrammar function
freusque has joined #ocaml
<Onemorenickname> and i'm failing miserably
<Onemorenickname> basically, i don't have an algorithm allowing me to translate "let rec x = lazy ([|[`NT(x)]|])" into "y = [|[`NT(y)]|]"
<Onemorenickname> I think i'm missing something big
strykerkkd has joined #ocaml
kakadu_ has joined #ocaml
<Onemorenickname> it'd be trivial with mutable structures
<Onemorenickname> but i don't see how to do it with immutable ones
ryanartecona has quit [Quit: ryanartecona]
<infinity0> can you explain it in a bit more detail?
<infinity0> i don't totally follow what you mean by "let rec x =" since x is not a function
<Onemorenickname> infinity0, "x" is a recursive grammar
<Onemorenickname> like you would write "S -> a | Sa" for a^n
<Onemorenickname> here, I would write it "let rec s = [| [t "a"] ; [nt S ; t "a"] |]"
<Onemorenickname> I finally managed to do so, by using the fact that array are mutables
<Onemorenickname> but I think there is a functional solutions I haven't found
<infinity0> you want to make a cyclic data structure?
<Onemorenickname> converting a cyclic data structure to an other cyclic data structure basically
<Onemorenickname> based on their "structure"
<Onemorenickname> as it can be mutually cyclic, I can't do it recursively
<Onemorenickname> I don't have a "decreasing parameter"
<Onemorenickname> (i don't know how it's called)
ygrek_ has joined #ocaml
<infinity0> i haven't needed to mess around with these myself. in haskell there's something you do called "tying the knot" to make cyclic data structures
zv has joined #ocaml
<infinity0> googling "haskell tying the knot ocaml" brings up some stuff that might help you, but i don't know them specifically
ygrek has quit [Ping timeout: 260 seconds]
<Onemorenickname> infinity0, i will google that, thanks for the pointer :)
<Onemorenickname> many interesting people around here :D
ygrek_ has quit [Ping timeout: 268 seconds]
<infinity0> though i'm not entirely sure you want a cyclic data structure, a grammar isn't exactly cyclic
<infinity0> a S might contain a S inside itself but these two values would be different and the overall structure isn't cyclic
<Onemorenickname> these two values are the same
<Onemorenickname> and it is indeed not cyclic, more like mutually recursive
<Onemorenickname> (well, it depends what you mean by cyclic)
slash^ has quit [Remote host closed the connection]
<infinity0> ok, well as long as you're sure the values are the same, then "cyclic" would be a good way of describing it. i just have never seen these sorts of things when doing "grammars"
<Onemorenickname> (when i build them, the interpreter writes "cyclic")
<Onemorenickname> infinity0, it's because i want to do grammars in a cleaner way than using words for grammars
<Onemorenickname> and then using a hashtbl or whatever
<infinity0> i'd also see if you can make it not cyclic, then it would be much easier to make it pure/functional
<infinity0> like if it's just a shared cache or environment or something, you can just have every element point to it
<Onemorenickname> yep, but there is no shared cache or evironment
<Onemorenickname> the subgrammars just linked to each other
snowcrshd has joined #ocaml
<tane> Onemorenickname, what is to be gained by not having some tree-like structure with symbols referencing cyclic links?
<Onemorenickname> tane, i don't have to loop through the whole hashtbl to find the subgrammars, i don't have to store a hashtbl doing so, I know every node is defined and not a symbol to nothing
<Onemorenickname> i don't have to mind about name collisions
<Onemorenickname> I don't add additional noise
mengu has joined #ocaml
TarVanimelde has joined #ocaml
snowcrshd has quit [Remote host closed the connection]
jamesst20 has joined #ocaml
Onemorenickname_ has joined #ocaml
jamesst20 has quit [Ping timeout: 240 seconds]
Onemorenickname_ has quit [Remote host closed the connection]
nicoo has quit [Ping timeout: 240 seconds]
Onemorenickname_ has joined #ocaml
nicoo has joined #ocaml
Onemorenickname has quit [Ping timeout: 240 seconds]
Onemorenickname_ has quit [Remote host closed the connection]
Onemorenickname_ has joined #ocaml
jnavila has quit [Remote host closed the connection]
Onemorenickname_ has quit [Max SendQ exceeded]
MercurialAlchemi has quit [Ping timeout: 268 seconds]
Onemorenickname_ has joined #ocaml
Onemorenickname_ has quit [Remote host closed the connection]
TarVanimelde has quit [Quit: TarVanimelde]
spew has joined #ocaml
ryanartecona has joined #ocaml
Onemorenickname has joined #ocaml
Onemorenickname has quit [Max SendQ exceeded]
Onemorenickname has joined #ocaml
Onemorenickname has quit [Max SendQ exceeded]
Onemorenickname has joined #ocaml
Onemorenickname has quit [Max SendQ exceeded]
Onemorenickname has joined #ocaml
Onemorenickname has quit [Max SendQ exceeded]
Onemorenickname has joined #ocaml
strykerkkd has quit [Quit: Leaving]
AlexDenisov has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
TarVanimelde has joined #ocaml
AlexDenisov has joined #ocaml
AlexDenisov has quit [Client Quit]
AlexDenisov has joined #ocaml
AlexDenisov has quit [Client Quit]
AlexDenisov has joined #ocaml
AlexDenisov has quit [Client Quit]
AlexDenisov has joined #ocaml
AlexDenisov has quit [Client Quit]
fre has joined #ocaml
TarVanimelde has quit [Quit: TarVanimelde]
SpaceSheep has quit [Ping timeout: 260 seconds]
SpaceSheep has joined #ocaml
silver has quit [Ping timeout: 260 seconds]
silver has joined #ocaml
freusque has quit [Ping timeout: 264 seconds]
Simn has quit [Quit: Leaving]
fre has quit [Ping timeout: 240 seconds]
fre has joined #ocaml
larhat1 has quit [Quit: Leaving.]
TheLemonMan has quit [Quit: "It's now safe to turn off your computer."]
wtetzner has joined #ocaml
yomimono has joined #ocaml
tane has quit [Quit: Leaving]
kakadu_ has quit [Remote host closed the connection]
yomimono has quit [Ping timeout: 240 seconds]
fre has quit [Quit: WeeChat 1.4]
jamesst20 has joined #ocaml
Space_Sheep has joined #ocaml
SpaceSheep has quit [Ping timeout: 240 seconds]
AltGr has left #ocaml [#ocaml]
jamesst20 has quit [Ping timeout: 264 seconds]
ryanartecona has quit [Quit: ryanartecona]
rcsole has quit [Ping timeout: 240 seconds]
Space_Sheep has quit [Quit: WeeChat 1.6]
mengu has quit [Read error: Connection reset by peer]
mengu has joined #ocaml
mengu has quit [Read error: Connection reset by peer]
mengu has joined #ocaml