<xtalmath>
Error: This expression has type int array array but an expression was expected of type (int array * int * 'a) array
<xtalmath>
since this is from januari 2011, i'm assuming ocaml changed a bit such that the code no longer works?
bytbox has quit [Remote host closed the connection]
claudiuc_ has joined #ocaml
<xtalmath>
im currently following the tryocaml thing, but I suspect that even after I completed it, I wont necessarily be able to fix the code
rgrinberg has joined #ocaml
<xtalmath>
so if someone understands the algebra/algorithm behind alg, feel free to help me out
claudiuc has quit [Ping timeout: 240 seconds]
claudiuc_ has quit [Ping timeout: 250 seconds]
johnnydiabetic has quit [Ping timeout: 240 seconds]
<Drup>
xtalmath: afaict, the code is just false, period. It wouldn't have worked with an older version of ocaml.
<Drup>
xtalmath: also, the last commit is from and 2013, changed the file were there is the error and is called "Nonworking version"
<Drup>
xtalmath: the commit just before compile
<xtalmath>
euhm, I got the tar.gz, you have it from Mercurial repository
<xtalmath>
?
<Drup>
it's the same
<xtalmath>
and it just doesnt work? is it possible to revert changes to the last working version somehow?
<xtalmath>
at some time it must have worked, or they wouldnt put up the blog entry
<Drup>
the tar.gz is auto generated from the repository
<Drup>
(I checked)
<xtalmath>
erm, im new to hg as well tbh
<Drup>
me too
<Drup>
(after cloning)
<xtalmath>
you have a clue how to make it work?
<Drup>
xtalmath: sure, just checkout the previous commit
<Drup>
"hg checkout 194:7b1185cf609f"
<Drup>
I did "hg lg", copy pasted the reference, and used "hg checkout"
<Drup>
not very different to git :D
<Drup>
hg log*
gperetin has quit [Ping timeout: 240 seconds]
<xtalmath>
thats from the many-sorted branch?
<Drup>
apparently
gperetin has joined #ocaml
<xtalmath>
which is the same as the ones before I assume?
<xtalmath>
ah yes now its compiling
<xtalmath>
hmm now "./src/alg.native --count --size 8 theories/group.th" gives "Syntax error: line 2, 11"
<xtalmath>
thanks for helping me compile btw!
<Drup>
can't help you with actually using the thing, now idea what it's about :)
<xtalmath>
it searches finite models that satisfy axioms entered, so you can give say ring axioms, and some more requirements and it can display models that fit
koderok has joined #ocaml
koderok has quit [Client Quit]
<xtalmath>
ah it works with the second last version (so not the many sorted one) :D
bytbox has joined #ocaml
travisbrady has quit [Quit: travisbrady]
samrat has joined #ocaml
philtor has quit [Read error: No route to host]
siddharthv_away is now known as siddharthv
samrat has quit [Quit: Computer has gone to sleep.]
xtalmath has left #ocaml [#ocaml]
samrat has joined #ocaml
samrat has quit [Client Quit]
ggole has joined #ocaml
jbza has joined #ocaml
<jbza>
I am getting poor performance on an algorithm that I have written that relies on pattern matching where there is ~500 distinct patterns. I am wondering if this poor performance may be due to the pattern matching?
<jbza>
Is it linear time to search for matching patterns?
<Drup>
500 patterns O_O
<jbza>
Would a trie/hashtable encounter better performance?
<Drup>
is it auto-generated or what ?
<jbza>
There are 500 distinct datatypes, but would reformulating them as strings be faster?
<jbza>
Yes, auto-generated
<jbza>
not datatypes, constructors
<Drup>
pattern matchin (without guards) is as clever as you can get
<Drup>
constructors are ints, and an efficient decision tree is generated
<jbza>
Hmm
<Drup>
but 500 hunder is quite ridiculous
<jbza>
It is a java grammar
<Drup>
java gramar has 500 hundred keywords ?
<Drup>
baah
<Drup>
-hundred
<jbza>
in BNF form, yeah
<Drup>
I don't really know, your use case is weird :/
<Drup>
I think you will have to compare
<jbza>
That's okay, if it isn't the pattern matching, then my algorithm must be slow
samrat has joined #ocaml
<Drup>
you profiled, I suppose ?
<jbza>
I did but I didn't get very far
<jbza>
what is the equivalent of "-auto-all" in from gch profiling
<jbza>
For getting in the inner methods
<Drup>
compile with the switch 4.01.0+fp
<Drup>
it will add various dwarf information and give you the call graph in perf
<jbza>
Thanks
<MercurialAlchemi>
there is one thing I don't understand - I try making my opam package following the docs and using a testing repo. Since it tends to blow up upon install, I install all the deps listed in the /opam file first. Then I tell opam to install my package, and sure enough, it's reinstalling all the dependencies
<Drup>
MercurialAlchemi: build script ?
<MercurialAlchemi>
just three lines, ocaml setup.ml -{configure,build,install}
<MercurialAlchemi>
nothing particularly odd
<MercurialAlchemi>
haha
<Drup>
show me :)
darkf_ has joined #ocaml
<MercurialAlchemi>
of course it blows up when reinstall ocamlfind with # Makefile:150: depend: No such file or directory
<MercurialAlchemi>
# ocamlfind: Package bytes is already installed
<MercurialAlchemi>
(which it installed just fine 30min ago)
<Drup>
if it's 1.1 ... there are multiple solver weirdness
<Drup>
especially if you are not using aspcud
<MercurialAlchemi>
What's that?
<Drup>
an external dependency solver opam can use instead of the built-in one
<Drup>
and it's much better
<MercurialAlchemi>
(and unfortunately it's the only version packaged for Debian)
<MercurialAlchemi>
hm
<MercurialAlchemi>
There is an aspcud package on Debian
<MercurialAlchemi>
You think if I install it, opam will magically detect it and use it?
<Drup>
yes
<elspru>
wow
jbza has quit [Ping timeout: 246 seconds]
<elspru>
ocaml has labeled arguments :-) I like that.
<elspru>
I'm considering making human speakable syntax for it.
<MercurialAlchemi>
Drup: thanks
Hannibal_Smith has joined #ocaml
koderok has joined #ocaml
siddharthv is now known as siddharthv_away
siddharthv_away is now known as siddharthv
koderok has quit [Quit: koderok]
MercurialAlchemi has quit [Remote host closed the connection]
MercurialAlchemi has joined #ocaml
<elspru>
trying to opam install libext, tells me camlp4of not found.
<elspru>
i install camlp4 so not sure what i'm missing.
<elspru>
says it can't find camlp4-extra
tane has joined #ocaml
<elspru>
found it in ubuntu repositories
Arsenik has joined #ocaml
darkf_ is now known as darkf
rgrinberg has quit [Quit: Leaving.]
rgrinberg has joined #ocaml
WraithM has quit [Ping timeout: 260 seconds]
WraithM has joined #ocaml
Submarine has quit [Remote host closed the connection]
eikke__ has joined #ocaml
AltGr has joined #ocaml
Simn has joined #ocaml
_0xAX has joined #ocaml
bezirg has quit [Ping timeout: 240 seconds]
Submarine has joined #ocaml
studybot has quit [Remote host closed the connection]
Hannibal_Smith has quit [Quit: Sto andando via]
jonludlam has quit [Remote host closed the connection]
eikke__ has quit [Ping timeout: 245 seconds]
bezirg has joined #ocaml
cago has joined #ocaml
rgrinberg has quit [Quit: Leaving.]
WraithM has quit [Ping timeout: 245 seconds]
Cariboo has left #ocaml [#ocaml]
Cariboo has joined #ocaml
eikke__ has joined #ocaml
michael_lee has joined #ocaml
<madroach>
OCaml 4.02beta is complaining "This comment contains an unterminated string literal" when there are braces '{' in comments.
<madroach>
Is this known / wanted behaviour?
<adrien_oww>
it's not something like
<adrien_oww>
(* "foo *)
<adrien_oww>
?
<madroach>
no
<madroach>
something like this in coq: (* between u v = {w|u<=w<=v, w canonical} *)
<madroach>
or this in ocamlnet: * As recommended by RFC 2045, the characters [!#$\@[]^`{|}~]
<def`>
{a|… is a string literal in ocaml
<acieroid>
madroach: yep it is explained in the changelog
<def`>
you have to close it with a corresponding |a}
<def`>
ocaml 4.02*
<madroach>
thanks.
bezirg has quit [Quit: Leaving.]
bezirg has joined #ocaml
thomasga has joined #ocaml
<ggole>
Wait, what?
<ggole>
# {a|what|a};; - : string = "what" O_o
<ggole>
So what's the purpose of this somewhat surprising construct?
<def`>
preprocessors, matching "a" qualified strings
<ggole>
ppx?
<def`>
Maybe, I don't know exactly if that's ppx, but it must be something related
<def`>
(I just saw that when porting lexer to merlin :P(
<def`>
)
<tane>
still, why would that impose certain constructs being written out in comments?
<ggole>
OK, thanks.
rwmjones has quit [Read error: No route to host]
dsheets has joined #ocaml
<def`>
tane: ocaml allows code inside comments, so lexical rules for code apply inside comments
rwmjones has joined #ocaml
<tane>
oh ok, thanks
hhugo has joined #ocaml
<adrien>
def`: that is getting restrictive for comments
<adrien>
plus it breaks compat
<ggole>
It'd be nice if it only applied to specially formatted comments
<def`>
I agree
Kakadu has joined #ocaml
Submarine has quit [Remote host closed the connection]
hhugo has quit [Quit: Leaving.]
<whitequark>
def`: ggole: ppx.
<whitequark>
it's for things like {html| |html}
fold has quit [Ping timeout: 250 seconds]
michael_lee has quit [Ping timeout: 260 seconds]
thomasga has quit [Quit: Leaving.]
octachron has joined #ocaml
hhugo has joined #ocaml
elfring has joined #ocaml
_andre has joined #ocaml
nojb has joined #ocaml
<nojb>
Why are the compiler-libs installed both under /usr/local/lib/ocaml and /usr/local/lib/ocaml/compiler-libs ?
<whitequark>
they aren't
<nojb>
whitequark: are they supposed to be installed only under lib/ocaml/compiler-libs ?
<whitequark>
yes
dsheets has quit [Ping timeout: 272 seconds]
fold has joined #ocaml
nojb has quit [Ping timeout: 264 seconds]
<hcarty>
Is there a proper opam-way to retrieve (or write) an application with a set of dependencies and then install those dependencies? A functioning version of 'opam get-me-what-i-need-to-hack-on /path/to/my/project/'
ebzzry has quit [Remote host closed the connection]
nojb has joined #ocaml
lpw25 has joined #ocaml
dsheets has quit [Ping timeout: 255 seconds]
dsheets has joined #ocaml
oriba has joined #ocaml
hcartym has joined #ocaml
hhugo has quit [Quit: Leaving.]
ousado has quit [Remote host closed the connection]
ousado has joined #ocaml
dsheets has quit [Ping timeout: 255 seconds]
ousado has quit [Ping timeout: 245 seconds]
ousado has joined #ocaml
<orbitz>
mfp: i found a representation of snapshots + log i liked for my design. logs are a list (effectively) and snapshots are 'nil'
nojb has quit [Quit: ERC Version 5.3 (IRC client for Emacs)]
<mfp>
orbitz: 'nil', as in "not reified"?
<mfp>
In my state machine, snapshots themselves do not appear (it only tracks ongoing snapshot transfers, to avoid sending again when there's already one in progress). Then, on the "install_snapshot" event, the log is trimmed (it's assumed the snapshot affects the state of the replicated state machine, which the core Oraft state machine is oblivious to).
<mfp>
is your representation anything like the above?
hhugo has joined #ocaml
<orbitz>
mfp: nil as in the end ofa list. so conceptually a log is a bunch of cons cells with a nil at the end, but 'nil' is just teh last snapshot
octachron has quit [Ping timeout: 246 seconds]
<orbitz>
mfp: yes, my implementation involves the implementation doing more of the managemetn
<mfp>
where the list is inverted, right? (i.e., the snapshot being actually the *beginning* of the log list chronologically)
<mfp>
when I looked around for implementations in other langs for ideas, I found they usually take over snapshot transfer and force you to serialize the whole thing to a string
<bernardofpc>
Mercurial> # ocamlfind: Package bytes is already installed -> same here
<mfp>
my mid-term goal is to replicate LSM data which allows trivially efficient incremental transfer, so I wanted to keep the Raft state machine oblivious to the specifics of snapshot shipping
_cody_ has joined #ocaml
sepp2k has joined #ocaml
NoNNaN has quit [Remote host closed the connection]
<mfp>
another way would be to just functorize everything out, but since the SM is already pure, simply handling snapshots with "received snapshot" / "snapshot send failed" events and "send snapshot with at least log entries up to N to X" actions is cleaner
* mfp
bbiaw
<orbitz>
mfp: yes, inverted
<orbitz>
mfp: yes i'm still not sure how exactly i want to do snapshot transfer
<orbitz>
definitly not serialize the whole thing to string since, like you, i want tens to hundresd of gigabytes
bytbox has quit [Remote host closed the connection]
samrat has quit [Quit: Computer has gone to sleep.]
Simn has quit [Read error: Connection reset by peer]
Hannibal_Smith has quit [Quit: Sto andando via]
Simn has joined #ocaml
ebzzry has joined #ocaml
siddharthv is now known as siddharthv_away
thomasga has joined #ocaml
ontologiae has joined #ocaml
dsheets has joined #ocaml
dsheets has quit [Remote host closed the connection]
dsheets_ has joined #ocaml
lordkryss has joined #ocaml
michael_lee has joined #ocaml
tane has quit [Quit: Verlassend]
englishm has joined #ocaml
darkf has quit [Quit: Leaving]
ontologiae has quit [Ping timeout: 255 seconds]
travisbrady has joined #ocaml
travisbrady has quit [Client Quit]
elfring has quit [Quit: Konversation terminated!]
hhugo has quit [Quit: Leaving.]
fraggle-boate has quit [Quit: Quitte]
fraggle-boate has joined #ocaml
jpdeplaix has quit [Ping timeout: 264 seconds]
michael_lee has quit [Quit: Ex-Chat]
bytbox has joined #ocaml
jpdeplaix has joined #ocaml
_cody_ has quit [Quit: Leaving]
bytbox has quit [Remote host closed the connection]
samrat has joined #ocaml
mort___ has joined #ocaml
_0xAX has quit [Remote host closed the connection]
travisbrady has joined #ocaml
eikke__ has quit [Ping timeout: 245 seconds]
typedlambda has quit [Ping timeout: 250 seconds]
typedlambda has joined #ocaml
hhugo has joined #ocaml
S11001001 has joined #ocaml
S11001001 has quit [Changing host]
S11001001 has joined #ocaml
axiles has quit [Read error: Connection reset by peer]
axiles has joined #ocaml
<Drup>
whitequark: RIP, _oasis for ppx
<whitequark>
Drup: hmm?
<Drup>
"please do a bug report, no ETA"
<Drup>
is pretty much equivalent to "never" in my book
<whitequark>
ah, yeah.
<Drup>
(at least for oasis)
bezirg has quit [Ping timeout: 260 seconds]
fold has quit [Ping timeout: 250 seconds]
samrat has quit [Ping timeout: 240 seconds]
fold has joined #ocaml
samrat has joined #ocaml
wwilly has joined #ocaml
oriba_ has joined #ocaml
toroidalcode has quit [Ping timeout: 245 seconds]
oriba_ has quit [Client Quit]
oriba has quit [Ping timeout: 255 seconds]
bytbox has joined #ocaml
cago has left #ocaml [#ocaml]
descender has quit [Ping timeout: 245 seconds]
ontologiae has joined #ocaml
ontologiae has quit [Ping timeout: 244 seconds]
tane has joined #ocaml
troydm has quit [Ping timeout: 250 seconds]
avsm has joined #ocaml
WraithM has joined #ocaml
jprakash has joined #ocaml
philtor_ has joined #ocaml
avsm has quit [Quit: Leaving.]
mort___ has left #ocaml [#ocaml]
shinnya has joined #ocaml
AltGr has left #ocaml [#ocaml]
bytbox has quit [Ping timeout: 255 seconds]
philtor_ has quit [Ping timeout: 260 seconds]
axiles has quit [Ping timeout: 240 seconds]
axiles has joined #ocaml
hhugo has quit [Quit: Leaving.]
rgrinberg has joined #ocaml
rgrinberg has quit [Client Quit]
samrat has quit [Quit: Computer has gone to sleep.]
rgrinberg has joined #ocaml
hcartym_ has joined #ocaml
shinnya has quit [Ping timeout: 272 seconds]
hcartym has quit [Ping timeout: 255 seconds]
sporkmonger has joined #ocaml
troydm has joined #ocaml
sporkmonger has quit [Quit: Poof!]
Kakadu has quit [Ping timeout: 246 seconds]
hcartym_ has quit [Read error: Connection reset by peer]
hcartym has joined #ocaml
sporkmonger has joined #ocaml
sporkmonger has quit [Client Quit]
NoNNaN has joined #ocaml
hcartym has quit [Read error: Connection reset by peer]
bytbox has joined #ocaml
hhugo has joined #ocaml
slash^ has joined #ocaml
q66 has joined #ocaml
yacks has quit [Ping timeout: 240 seconds]
Hannibal_Smith has joined #ocaml
yacks has joined #ocaml
_0xAX has joined #ocaml
<orbitz>
evening
<bitbckt>
mornin
<orbitz>
how goes it bitbckt
<bitbckt>
fair-to-middlin'. how're you, orbitz?
bytbox has quit [Remote host closed the connection]
troutwine_away is now known as troutwine
<orbitz>
bitbckt: i'm good. Working on some Ocaml, whee
<orbitz>
Intereste to see what 4.03.0 looks like with namespaces
<orbitz>
compiletimes with Core are pretty weaksauce
<bitbckt>
yeah, they're hoping to fix that up soon-ish. packs are a pain.
englishm has quit [Remote host closed the connection]
hhugo has quit [Quit: Leaving.]
Kakadu has joined #ocaml
hhugo has joined #ocaml
englishm has joined #ocaml
lpw25 has quit [Remote host closed the connection]
ontologiae has joined #ocaml
<orbitz>
I like the idea of packs at least
<orbitz>
I think the Core library layout is kind of unfriendly to modularity thouhg
<flux>
4.03 is going to have namespaces?
<adrien>
birth of a rumor
<flux>
oh, 'scheduled for release 2015-05-01', so I guess it could have anything :-)