Clojure 1.8.0-alpha5 is now available. Try it via
- Download: https://repo1.maven.org/maven2/org/clojure/clojure/1.8.0-alpha5 - Leiningen: [org.clojure/clojure "1.8.0-alpha5"] The 1.8.0-alpha5 release reverts the change made for CLJ-1250 <http://dev.clojure.org/jira/browse/CLJ-1250> in 1.8.0-alpha3 due to issues covered in CLJ-1793 <http://dev.clojure.org/jira/browse/CLJ-1793>. String Functions Several new string functions were added to increase portability with ClojureScript and reduce the need for Java interop calls: - clojure.string/index-of - search for the index of a char or string in a string - clojure.string/last-index-of - search for the index of a char or string backwards in a string - clojure.string/starts-with? - true if string starts with a substring - clojure.string/ends-with? - true if string ends with a substring - clojure.string/includes? - true if string includes a substring For more info: - CLJ-1449 <http://dev.clojure.org/jira/browse/CLJ-1449> *Server Socket and REPL * *This feature is a work in progress, and feedback is appreciated!* The Clojure runtime now has the ability to start a socket server at initialization based on system properties. One expected use for this is serving a socket-based REPL, but it also has many other potential uses for dynamically adding server capability to existing programs without code changes. A socket server will be started for each JVM system property like "clojure.server.<server-name>". The value for this property is an edn map representing the configuration of the socket server with the following properties: - server-daemon - defaults to true, socket server thread doesn't block exit - address - host or address, defaults to loopback - port - positive integer, required - accept - namespaced symbol of function to invoke on socket accept, required - args - sequential collection of args to pass to accept - bind-err - defaults to true, binds `*err*` to socket out stream - client-daemon - defaults to true, socket client thread doesn't block exit Additionally, there is a repl function provided that is slightly customized for use with the socket server in clojure.core.server/repl. Following is an example of starting a socket server with a repl listener. This can be added to any existing Clojure program to allow it to accept external REPL clients via a local connection to port 5555. -Dclojure.server.repl="{:port 5555 :accept clojure.core.server/repl}" An example client you can use to connect to this socket repl is telnet: $ telnet 127.0.0.1 5555 Trying 127.0.0.1... Connected to localhost. Escape character is '^]'. user=> (println "hello") hello See: * CLJ-1671 <http://dev.clojure.org/jira/browse/CLJ-1671> * Socket REPL design page <http://dev.clojure.org/display/design/Socket+Server+REPL> *Other changes* Below is a list of the other changes included in alpha5. See the full change log here: https://github.com/clojure/clojure/blob/master/changes.md. - CLJ-1319 <http://dev.clojure.org/jira/browse/CLJ-1319> array-map fails lazily if passed an odd number of arguments - CLJ-1766 <http://dev.clojure.org/jira/browse/CLJ-1766> Serializing+deserializing lists breaks their hash - CLJ-1609 <http://dev.clojure.org/jira/browse/CLJ-1609> Edge case in Reflector's search for a public method declaration - CLJ-1586 <http://dev.clojure.org/jira/browse/CLJ-1586> Compiler doesn't preserve metadata for LazySeq literals - CLJ-1232 <http://dev.clojure.org/jira/browse/CLJ-1232> Functions with non-qualified return type hints will now work without import from other namespace - Records and types without fields eval to empty map - CLJ-1812 <http://dev.clojure.org/jira/browse/CLJ-1812> Recently-added test fails on Windows - CLJ-1778 <http://dev.clojure.org/jira/browse/CLJ-1778> let-bound namespace-qualified bindings should throw (if not map destructuring) -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegroups.com Note that posts from new members are moderated - please be patient with your first post. To unsubscribe from this group, send email to clojure+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/clojure?hl=en --- You received this message because you are subscribed to the Google Groups "Clojure" group. To unsubscribe from this group and stop receiving emails from it, send an email to clojure+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.