[ANN] Mirah 0.1.1 Released
Hey everybody, Mirah 0.1.1 has been released! This release has been a long time coming, 383 commits. Considering the repository only has had 1627 commits so far, that's a lot of changes.
Ryan Brown's work on self-hosting continues:
- The typer has moved further into Mirah
- The new self-hosted backend
- The new mirror type system
To try out the new backend, run Mirah with -N, to test the new mirrors use -T.
- lambda macro - allows you to create closures without having to pass them to a method call. run_me = lambda(Runnable) { puts "running" }
- beginnings of better generics support
- Move map macro from List to Collection.
- Add zip, map, and reduce macros.
- Java 8 bytecode support
- Array literals are no longer immutable
- macro lookup looks in implemented interfaces as well as classes
- improved loop detection in the typer
- static field and method lookup now checks up the inheritance hierarchy #134, #150
- better boxing of varargs values
- type conversion of assignable return types
- Fix varargs method called with array.
- dynamic type -- currently dynamic support requires the dynalink jar, which is a runtime dependency. I've started a project for converting it into an extension (https://github.com/mirah/mirah-dynamic).
- fixnum has been renamed to int
Visibility: the new ast changes removed public/protected/private. We're going to add them back in the next
- change ruby version - check
- change pom versions - check
- update history - check
- commit -check
- build artifacts - check
rake clean clobber dist
- test
- install gem
- run basic test w/ gem binary
- run MirahCommand from jar
- TODO find out whether you can run the test suite w/ released gem in an automatic way
Ran into some problems w/ jar -- path issues ultimately $ java -cp dist/mirah-complete.jar org.mirah.MirahCommand run examples/tak.mirah Exception in thread "main" java.lang.NoClassDefFoundError: org/jruby/runtime/Helpers at org.mirah.MirahCommand.main(MirahCommand.java:118) Caused by: java.lang.ClassNotFoundException: org.jruby.runtime.Helpers at java.net.URLClassLoader$1.run(URLClassLoader.java:202) at java.security.AccessController.doPrivileged(Native Method) at java.net.URLClassLoader.findClass(URLClassLoader.java:190) at java.lang.ClassLoader.loadClass(ClassLoader.java:306) at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301) at java.lang.ClassLoader.loadClass(ClassLoader.java:247) ... 1 more
Hmmm
JRuby 1.7.4 changed some internal APIs so classfiles generated with it are not backwards compatible
dl new jruby-complete & cp into javalib
now java -cp dist/mirah-complete.jar org.mirah.MirahCommand run examples/simple_class.mirah
- [TypeFactory] Error initializing builtins: Unable to find class mirah.lang.ast.Block
jar:file:/Users/nick/hacking/mirah_hacking/mirah/dist/mirah-complete.jar!/mirah/jvm/types/intrinsics.rb:186:in
read_macrodef_annotation' org/jruby/java/proxies/ArrayJavaProxy.java:138:ineach'
I'm going to try downgrading to 1.7.2
nope
the problem was that the base classpaths were wrong for the in a jar case
hmm
mvn gpg:sign-and-deploy-file -Durl=https://oss.sonatype.org/service/local/staging/deploy/maven2/ -DrepositoryId=sonatype-nexus-staging -DpomFile=maven/mirah-complete/pom.xml -Dfile=dist/mirah-complete-*.jar
mvn gpg:sign-and-deploy-file -Durl=https://oss.sonatype.org/service/local/staging/deploy/maven2/ -DrepositoryId=sonatype-nexus-staging -DpomFile=maven/mirah/pom.xml -Dfile=dist/mirah*.jar
mvn gpg:sign-and-deploy-file -Durl=https://oss.sonatype.org/service/local/staging/deploy/maven2/ -DrepositoryId=sonatype-nexus-staging -DpomFile=pom.xml -Dfile=pom.xml
mvn clean deploy
login close staging repo
- tag
- write release notes