This is the mail archive of the kawa@sourceware.org mailing list for the Kawa project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

various Kawa improvements and changes


Here are some significant changes I've checked into Kawa recently,
plus some that go back a bit that I may not have announced:

* When evaluating or loading a source file, we now always compile to
bytecode, rather than interpreting simple expressions. This makes
semantics and performance more consistent, and gives us better
exception stack traces.

* The Scheme type specifier <integer> now handles automatic conversion
from java.math.BigInteger and the java.lang classes Long, Integer,
Short, and Byte. The various standard functions that work on <integer>
(for example gcd and arithmetic-shift) can be passed (say) a
java.lang.Integer. The generic functions such as + and the real function modulo should also work. (The result is still a gnu.math.IntNum.)


* If a name such as (java.util) is lexically unbound, and there is a
known package with that name, return the java.lang.Package instance.
Also, the colon operator is extended so that package:name evaluates
to the Class for package.name.

* `prefix:,expression works - it finds a symbol in prefix's package
(aka namespace), whose local-name is the value of expression.

* A quantity 3.0cm is now syntactic sugar for (* 3.0 unit:cm).
Similarly:
(define-unit name value)
is equivalent to:
(define-constant unit:name value)
This means that unit names follow normal name-lookup rules (except
being in the unit package), so for example you can have local unit
definitions.

* You can specify whether a class has public or package access,
and whether it is translated to an interface or class.

* You can declare an abstract method by writing #!abstract as its body.

* If a name of the form type? is undefined, but type is defined, then
treat the former as (lambda (x) (instance? x type)).

See file:///home/bothner/Kawa/web/kawa/news.html for more changes.
--
	--Per Bothner
per@bothner.com   http://per.bothner.com/


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]