#hoplon

/

      • alandipert
        DomKM: in your build.boot you can do e.g. (set! clojure.core/*warn-on-reflection* true)
      • DomKM
        alandipert: perfect, thanks
      • alandipert
        actually just need (set! *warn-on-reflection* true) since it’s referred, but yeah. np!
      • DomKM
        michaniskin__: It's a way to set clojure.core vars globally. I typically use `:global-vars {*warn-on-reflection* true}` in all projects
      • michaniskin__
        makes sense
      • firstclassfunc_ has quit
      • raywillig
        forgive the noob question, but what does *warn-on-reflection* do for you? like how does it influence your behavior?
      • the example on clojure docs looks a little lame
      • brucehauman_ joined the channel
      • brucehauman has quit
      • brucehauman_ is now known as brucehauman
      • danielszmulewicz has quit
      • danielszmulewicz joined the channel
      • martinklepsch
        michaniskin__: tested repl + reload in cljs-example, all seems to work
      • schmir joined the channel
      • danielszmulewicz has quit
      • cpmcdaniel has quit
      • michaniskin__
        raywillig: reflection warnings just tell you where you can add annotations to improve performance
      • the compiler can know in advance which java implementation to use and doesn't have to do runtime reflection when the function is called
      • martinklepsch: great, i'll merge and push immediately
      • martinklepsch
        michaniskin__: take your time
      • raywillig
        you mean annotations like type hints?
      • with those kinds of annotations can you do multi arity functions with same arity but different type hints for a given function?
      • michaniskin__
      • clojure normally doesn't know which replaceAll method to use there
      • so it does reflection to see which interfaces filename implements
      • and it chooses the right method to invoke
      • with the ^String type annotation it can hardcode that in at compile time
      • emit the bytecode to invoke that specific implementation
      • raywillig
        so i guess that can save a bunch of time at runtime
      • michaniskin__
        yeah that's what the warning tells you about
      • raywillig
        cool, thx
      • bsima has quit
      • NOTICE: [boot] schmir opened pull request #108: throw a descriptive exception when the java compiler cannot be used (master...no-jdk-npe) http://git.io/Fg20
      • schmir
        I'm trying to get boot working on windows...
      • michaniskin__
        schmir: all right!
      • i know things are rough currently with windows suport
      • martinklepsch
      • this is WIP of someone I know who started working on making things work in windows
      • michaniskin__
        this will be good for me to see also, so i can learn how to write cross-platform code
      • martinklepsch
        he wanted to make a PR, dunno what kept him from doing so
      • schmir
        I think relative-to shouldn't return an URI. it should return a File object
      • martinklepsch
        schmir: yeah, something like that lypanov also said. like URI isn't cross platform or so
      • michaniskin__
        schmir: yeah this part of java confuses me
      • martinklepsch
        (I don't really remember tbh)
      • michaniskin__
        i wonder if pathetic would help?
      • schmir
        pathetic's readme says windows paths won't work
      • NOTICE: [boot] micha closed pull request #108: throw a descriptive exception when the java compiler cannot be used (master...no-jdk-npe) http://git.io/Fg20
      • NOTICE: [boot] micha pushed 2 new commits to master: http://git.io/Fgoy
      • NOTICE: boot/master b18ed9e Ralf Schmitt: throw a descriptive exception when the java compiler cannot be used...
      • NOTICE: boot/master 77b5bb1 Micha Niskin: Merge pull request #108 from schmir/no-jdk-npe...
      • Deraen
        I'm not sure if File object can be relative
      • michaniskin__
        File object can be relative
      • martinklepsch
        schmir: check out these repo's I linked I just read some messages and he said the same thing about relative-to
      • s/I linked/I linked./
      • punctuation is there for a reason, eh?
      • michaniskin__
        since boot requires java 7+, maybe the Paths stuff is what we want
      • Deraen
        Okay. Still, returning File object is a bit strange as if anything tries to read the file it will probably fail
      • martinklepsch
        anyway, later all!
      • michaniskin__
        later martin!
      • Deraen
        https://github.com/boot-clj/boot/blob/master/bo... This should help a bit with fixing relative-to for windows
      • (and making sure fixes don't break it for Unixes :)
      • michaniskin__
        yeah we need legitimate tests for this
      • i wonder if i can run windows tests on drone.io
      • schmir
        How am I supposed to develop boot? currently I'm always running 'make install' and try it on my project
      • michaniskin__
        you can do `lein install` in one of the module directories to just rebuild that module
      • and you can do lein repl in those dirs as well to get a repl
      • Deraen
        Depending on the feature, I might add tests first and then just modify stuff on repl untill tests work
      • tcrawley is now known as tcrawley-away
      • I wonder if instead of using Java Path/File/URI it would be easier to create pure clojure type for this? :D
      • michaniskin__
        yeah i have no idea
      • Deraen
        (deftype Path [parts]) where parts is collection of path parts. It would provide relativize, to-file etc.
      • michaniskin__
      • schmir
        Deraen: I wouldn't do that. too many special cases (on windows).
      • michaniskin__
        schmir: how is windows support for the nio Path class?
      • schmir
        I guess fine. I thought Deraen wanted to do that from scratch!
      • Deraen
        I'm just not very impressed with Javas classes in this case :d
      • NOTICE: [boot] schmir opened pull request #109: return a File object from relative-to (master...fix-relative-to) http://git.io/FgMb
      • michaniskin__
        also i read that windows can understand paths with / as the separator except on the command line of cmd.exe, which uses the / as the option character, like `ls /l` instead of `ls -l`
      • Deraen
        There was some reason I used URI.relativize instead of Path.relativize. But perhaps it can be used still
      • michaniskin__
        Deraen: i've been using File objects as a way to manipulate paths
      • which i guess was wrong
      • schmir
        yes, / works fine on windows as a path separator
      • Deraen
        Yeah I think files should be used when you are pointing to some file which might exist. But if your are taking File and using that as path and manipulating path to get relative path, File doesn't point to anything anymore.
      • NOTICE: [boot] micha closed issue #85: Illegal character error when invoking getting started boot command-line in Windows http://git.io/BaZLQQ
      • NOTICE: [boot] micha closed pull request #109: return a File object from relative-to (master...fix-relative-to) http://git.io/FgMb
      • NOTICE: [boot] micha pushed 2 new commits to master: http://git.io/Fgyv
      • NOTICE: boot/master 056931d Ralf Schmitt: return a File object from relative-to...
      • NOTICE: boot/master 51f7ed4 Micha Niskin: Merge pull request #109 from schmir/fix-relative-to...
      • michaniskin__
        yeah so i guess lesson #1 is to use Path objects for path manipulation
      • ?
      • schmir
        Deraen: but that shouldn't be a problem?
      • michaniskin__: I hope you did test that pull request?
      • bsima joined the channel
      • Deraen
        Using Paths sounds like proper solution
      • michaniskin__
        schmir: i will test everything before making a release :)
      • but i think str vs .getPath is ok
      • i think they return the same thing for a file
      • i mean "for a File"
      • Deraen
        Looks like relative-to tests are still passing
      • michaniskin__
        schmir: is anything else majorly broken in windows?
      • and which version of windows are you on?
      • schmir
        michaniskin__: yes
      • win 7 pro
      • and server 2008
      • hard-linking doesn't work, the color codes should also be off by default
      • michaniskin__
        what are you doing instead of hardlinks?
      • schmir
        uberjar doesn't work, since it's trying to copy a file that doesn't exist..
      • michaniskin__: I turned it off, there's a dynamic var somewhere...
      • michaniskin__
        ah ok, so you're just copying files
      • that's what happens when the dynavar is off
      • schmir
        windows is such a pain...but I spent the day with boot on linux and only later realized that it doesn't work on windows
      • michaniskin__
        hahaha the ole bait and switch!
      • well if you tell us what we're doing wrong on windows we can fix it
      • schmir
        anyway, martinklepsch is guilty. he spoke at clojured on boot and that made me try it
      • michaniskin__
        so the Paths thing is #1 lesson learned
      • schmir
        michaniskin__: I think I'll be able to contribute some more pull requests...
      • michaniskin__
        i read that windows did support hard links
      • it would be a shame if we couldn't use them
      • schmir
        yes, it does. but I got an error message that the file exists. unlinking the target path somehow didn't help...
      • NOTICE: [boot] schmir opened pull request #110: use deterministic compile order and show progress in aot (master...aot-compile-order) http://git.io/Fg5A
      • aot compilation doesn't work with the watch task. I'm going to open a pull request in the next days on that one...
      • NOTICE: [boot] micha closed pull request #110: use deterministic compile order and show progress in aot (master...aot-compile-order) http://git.io/Fg5A
      • NOTICE: [boot] micha pushed 2 new commits to master: http://git.io/FgFZ
      • NOTICE: boot/master dff2154 Ralf Schmitt: use deterministic compile order and show progress in aot
      • NOTICE: boot/master 6030c48 Micha Niskin: Merge pull request #110 from schmir/aot-compile-order...
      • michaniskin__
        awesome! thanks for the PRs :)
      • schmir
        thanks for merging that fast and thanks for boot!
      • enough for today. good night!
      • michaniskin__
        no problem!
      • good night
      • i am going to see about moving CI to this new service that provides windows test servers
      • schmir has quit
      • NOTICE: [boot] micha closed issue #107: Possible improvement to boot Bash header http://git.io/Fuhz
      • NOTICE: [boot] micha pushed 1 new commit to master: http://git.io/FgAk
      • NOTICE: boot/master 3054984 Micha Niskin: Improve bash header (fixes #107)
      • brucehauman has quit
      • brucehauman joined the channel
      • brucehauman has quit
      • alandipert
        man the boot client thing would be killer
      • michaniskin__
      • i wonder about this
      • onetom_ has quit