samrat has quit [Quit: Computer has gone to sleep.]
WraithM has quit [Ping timeout: 245 seconds]
dav has quit [Read error: Connection reset by peer]
pkrnj has joined #ocaml
isms has joined #ocaml
isms has quit [Client Quit]
MercurialAlchemi has joined #ocaml
siddhart1v_away is now known as siddharthv
Wandering_Glitch is now known as WanderingGlitch
WanderingGlitch has quit [Changing host]
WanderingGlitch has joined #ocaml
pkrnj has quit [Quit: Computer has gone to sleep.]
pkrnj has joined #ocaml
axiles has joined #ocaml
alexey_ has quit [Quit: leaving]
ZenosDance has quit [Ping timeout: 240 seconds]
manud has quit [Ping timeout: 240 seconds]
pkrnj has quit [Quit: Computer has gone to sleep.]
slash^ has joined #ocaml
araujo has quit [Quit: Leaving]
SGrondin has quit [Quit: Leaving.]
pkrnj has joined #ocaml
samrat has joined #ocaml
pkrnj has quit [Quit: Computer has gone to sleep.]
wemeetagain has joined #ocaml
pkrnj has joined #ocaml
fold has joined #ocaml
pkrnj has quit [Client Quit]
<wemeetagain>
hello, ocaml newb here, looking to interact with: type rlp = | String of string | List of rlp list;; but having some difficulty.. It looks as though this type doesn't know how to use ::. So: String "Hello" :: List ["world"];; does not work. I feel that I'm missing something big here.. wondering if anyone can help
philtom has quit [Ping timeout: 245 seconds]
<asmanur>
It's because it should be List [String "world"] wormphle1m ?
<asmanur>
because List expects a list of rlp's not a list of strings
<wemeetagain>
Oh, whoops, thats what I meant
<wemeetagain>
it still doesnt like that
<wemeetagain>
I'm feeling like I need to somehow define :: for this type
<wemeetagain>
but
<def`>
:: [] to close the list
<wemeetagain>
but then I get an rlp list, rather than a List
<wemeetagain>
and its no longer of type rlp, its of type rlp list
<def`>
:P
<wemeetagain>
maybe I'm just trying to do something impossible?
<wemeetagain>
I'm not entirely sure
<def`>
String "Hello" :: List [String "World"] :: []
<def`>
is a list
<def`>
List (String "Hello" :: List [String "World"] :: [])
<def`>
is an rlp
<wemeetagain>
ahhh, ok
<def`>
equals to List [String "hello"; List [String "World"]]
<def`>
you can't mix _ list and rlp, but you created the List constructor to inject one into the other
<wemeetagain>
mm, yea
fold has quit [Ping timeout: 245 seconds]
<wemeetagain>
so then how would I append a String to a List?
<wemeetagain>
thats I guess what I'm grappling with
<flux>
let append string list = match list with | String _ -> failwith "cannot add a string to a string" | List xs -> List (string::xs)
<flux>
actually List (String string::xs)
<flux>
and actually that prepends, not appends :)
<wemeetagain>
ah, yeah, thats actually wht I meant
<wemeetagain>
I'm wondering how this is different than just using ::, which doesnt work
<wemeetagain>
I mean, this prepend function works, but I'm now a bit confused that it worked, yet a similar expression without the function doesnt work
<wemeetagain>
ohhh, it seperates xs, the underlying List from the argument 'list'
<wemeetagain>
*the underlying list
<def`>
yes
<wemeetagain>
beautiful
<wemeetagain>
these are some tricky intricacies
<wemeetagain>
but I guess it makes sense, the :: wasnt working on a List, it DOES however work on a list
rgrinberg has quit [Quit: Leaving.]
<wemeetagain>
curious, are there any default standard names for arguments?
<wemeetagain>
er, even for a function
<wemeetagain>
like if you have a function that does something, but in reverse, I imagine I'd add a _rev to the end of its name
<wemeetagain>
can you share a bit of the conventions behind the naming?
<wemeetagain>
thats a big thing I worry about, looking at even the small bit of code I've written
<wemeetagain>
its so easy to write stuff but later look back and not even know what I was doing
<wemeetagain>
just because the names are not..... optimal
<def`>
wemeetagain: looking at the stdlib, you'll find
<def`>
List.append & List.rev_append, List.map & List.rev_map, etc.
<wemeetagain>
ah, ok, so the convention is to prepend the rev
<wemeetagain>
and I've also seen xtype_from_ytype and also ytype_to_xtype
<wemeetagain>
is there a better naming between the two
rgrinberg has joined #ocaml
MercurialAlchemi has quit [Remote host closed the connection]
dubst3pp4 has joined #ocaml
MercurialAlchemi has joined #ocaml
<wemeetagain>
def`: flux: thank you so much for the help. It can be a little tricky for a beginner, even if you have experience with other programming languages. Sometimes, even the tiniest push can make all the difference. :)
<def`>
wemeetagain: you're welcome
<def`>
the xtype_from_type (or sometime xtype_of_ytype) reads better with function composition
<def`>
xtype_of_ytype (ytype_of_ztype z)
<def`>
but that's mostly a matter of taste. I use either of or to depending on what is the most specific object to me (in a module, like SpecificObject.to_genericone / of_genericone)
<wemeetagain>
ok, thanks
<wemeetagain>
Yeah, the of/from seems to read better in a lot of cases
studybo__ has joined #ocaml
studybot_ has quit [Ping timeout: 264 seconds]
studybo__ is now known as studybot
zarul has joined #ocaml
eikke__ has joined #ocaml
wemeetagain has quit [Quit: WeeChat 1.0]
avsm has joined #ocaml
path[l] has joined #ocaml
MercurialAlchemi has quit [Remote host closed the connection]
<path[l]>
Hi everyone, I’m trying to build this project on my machine https://github.com/jaked/deriving and when I try to make the tests it gives me a bunch of warnings about unused open modules but eventually fails with make: *** [byte-code] Error 2
<path[l]>
any idea how I can figure out why its not building
MercurialAlchemi has joined #ocaml
dubst3pp4 has quit [Quit: Ĝis la revido!]
path[l] has quit [Ping timeout: 250 seconds]
fraggle_laptop has quit [Remote host closed the connection]
dubst3pp4 has joined #ocaml
path[l] has joined #ocaml
fraggle_ has quit [Read error: Connection reset by peer]
eikke__ has quit [Ping timeout: 240 seconds]
ggole has joined #ocaml
fraggle_ has joined #ocaml
lpw25 has joined #ocaml
lpw25 has quit [Client Quit]
lpw25 has joined #ocaml
Simn has joined #ocaml
samrat has quit [Quit: Computer has gone to sleep.]
samrat has joined #ocaml
cago has joined #ocaml
BitPuffin has joined #ocaml
studybot is now known as nns
BitPuffin has quit [Ping timeout: 250 seconds]
ontologiae_ has joined #ocaml
zpe has joined #ocaml
slash^ has quit [Read error: Connection reset by peer]
q66[lap] has joined #ocaml
q66[lap] has quit [Changing host]
q66[lap] has joined #ocaml
slash^ has joined #ocaml
zpe has quit [Remote host closed the connection]
zpe has joined #ocaml
rand000 has joined #ocaml
zpe has quit [Ping timeout: 255 seconds]
AltGr has joined #ocaml
zpe has joined #ocaml
WraithM has joined #ocaml
octachron has joined #ocaml
avsm has quit [Quit: Leaving.]
WraithM has quit [Ping timeout: 240 seconds]
BitPuffin has joined #ocaml
WraithM has joined #ocaml
thomasga has joined #ocaml
eikke__ has joined #ocaml
pgomes has joined #ocaml
<pgomes>
Hi
<pgomes>
I have a problem: I cannot build camlp4 on 4.02.0...
<path[l]>
jpdeplaix: hi thanks, let me try to build that one instead :). But I wondered why the previous one (which built except for the tests), does not give me any indication of what the error is
sgnb` has quit [Ping timeout: 250 seconds]
<path[l]>
jpdeplaix: can that be built without opam, since it complains about oasis.dynrun
thomasga has quit [Quit: Leaving.]
thomasga has joined #ocaml
sgnb has joined #ocaml
zpe has quit [Remote host closed the connection]
zpe has joined #ocaml
zpe has quit [Ping timeout: 260 seconds]
samrat has quit [Quit: Computer has gone to sleep.]
path[l] has quit [Ping timeout: 260 seconds]
path[l] has joined #ocaml
mort___ has joined #ocaml
<jpdeplaix>
path[l]: you need oasis to be installed
Shozan is now known as SHODAN
dsheets has joined #ocaml
samrat has joined #ocaml
thomasga has quit [Quit: Leaving.]
dubst3pp4 has quit [Quit: Ĝis la revido!]
Guest38898 is now known as johnelse
mort___ has left #ocaml [#ocaml]
<path[l]>
jpdeplaix: I dont think I will be able to add a dependency on oasis in what I”m doing, since everything but the tests build with the older project, is it not possible for me to force ocaml to let me know why this build failed?
Submarine has quit [Remote host closed the connection]
<MercurialAlchemi>
it reminds of some terrible, terrible codebases where developers futilely try to cling to French when the language is full of English keywords, ending with grotesque, hideous French-English function names
<MercurialAlchemi>
OCAML_PERFIDE_ALBION :D
<MercurialAlchemi>
brilliant
zpe has quit [Ping timeout: 245 seconds]
ollehar has joined #ocaml
hhugo has joined #ocaml
samrat has quit [Quit: Computer has gone to sleep.]
cespinoza has quit [Ping timeout: 245 seconds]
Algebr has joined #ocaml
tautologico has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
cody__ has quit [Quit: Leaving]
ontologiae_ has quit [Quit: WeeChat 0.4.0]
zpe has joined #ocaml
_andre has quit [Quit: leaving]
zpe has quit [Remote host closed the connection]
zpe has joined #ocaml
cespinoza has joined #ocaml
rgrinberg has joined #ocaml
hhugo has quit [Quit: Leaving.]
rgrinberg has quit [Client Quit]
zpe has quit [Ping timeout: 245 seconds]
flx has joined #ocaml
Simn has quit [Ping timeout: 260 seconds]
flux has quit [Ping timeout: 272 seconds]
flx is now known as flux
Hannibal_Smith has quit [Quit: Sto andando via]
sheijk has joined #ocaml
sepp2k has quit [Quit: Konversation terminated!]
WraithM has quit [Ping timeout: 260 seconds]
axiles has quit [Remote host closed the connection]
dsheets has quit [Ping timeout: 260 seconds]
avsm has joined #ocaml
dsheets has joined #ocaml
avsm1 has joined #ocaml
WraithM has joined #ocaml
avsm has quit [Ping timeout: 255 seconds]
rand000 has quit [Quit: leaving]
rollertrump has joined #ocaml
avsm1 has quit [Quit: Leaving.]
hhugo has joined #ocaml
zpe has joined #ocaml
dsheets has quit [Ping timeout: 260 seconds]
MercurialAlchemi has quit [Ping timeout: 255 seconds]
zpe has quit [Ping timeout: 260 seconds]
philtom has joined #ocaml
kakadu_ has joined #ocaml
ggole has quit []
path[l] has quit [Quit: path[l]]
tane has quit [Quit: Verlassend]
Simn has joined #ocaml
eikke__ has quit [Ping timeout: 260 seconds]
Simn has quit [Ping timeout: 260 seconds]
nojb has joined #ocaml
zarul has quit [Ping timeout: 250 seconds]
zarul has joined #ocaml
zarul has joined #ocaml
zarul has quit [Changing host]
WraithM has quit [Ping timeout: 245 seconds]
hhugo has quit [Quit: Leaving.]
ollehar has quit [Ping timeout: 245 seconds]
Algebr has quit [Ping timeout: 260 seconds]
kakadu_ has quit [Quit: Konversation terminated!]
eikke__ has joined #ocaml
lordkryss has quit [Quit: Connection closed for inactivity]
jao has joined #ocaml
jao has quit [Changing host]
jao has joined #ocaml
hhugo has joined #ocaml
lbaan has joined #ocaml
thomasga has quit [Quit: Leaving.]
thomasga has joined #ocaml
thomasga has quit [Client Quit]
hhugo has quit [Ping timeout: 245 seconds]
cartwright has quit [Remote host closed the connection]
cantstanya has joined #ocaml
fraggle-boate has quit [Ping timeout: 245 seconds]
sheijk_ has joined #ocaml
sheijk_ has quit [Client Quit]
Thooms has quit [Quit: WeeChat 0.4.3]
fraggle-boate has joined #ocaml
sheijk has quit [Ping timeout: 255 seconds]
lbaan has quit [Quit: sleeping device]
ZenosDance has joined #ocaml
cespinoza has quit [Ping timeout: 260 seconds]
fraggle-boate has quit [Ping timeout: 255 seconds]
fraggle-boate has joined #ocaml
cespinoza has joined #ocaml
eikke__ has quit [Ping timeout: 245 seconds]
madroach has quit [Ping timeout: 250 seconds]
madroach has joined #ocaml
NoNNaN has quit [Remote host closed the connection]
NoNNaN has joined #ocaml
nojb has quit [Ping timeout: 245 seconds]
Anarchos has quit [Quit: Vision[0.9.7-H-20140108]: i've been blurred!]
ZenosDance has quit [Ping timeout: 272 seconds]
pyon has quit [Quit: These skies and seas hold great possibilities for you. Stay alive. Pursue happiness. I expect much from your life.]