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]

Re: proper use of define-alias


On 06/22/2012 08:33 AM, Alcides Flores Pineda wrote:
According to Kawa's documentation, (despite it  may not be very clear
here to newbie programmers) define-alias is for aliasing Java Classes
or Java Packages (aka "locations") NOT numerical constants.

That's the primary use, but it seems a bug that this doesn't work:


#|kawa:1|# (define-alias vert-sb-always javax.swing.ScrollPaneConstants:VERTICAL_SCROLLBAR_ALWAYS)
#|kawa:2|# vert-sb-always
22


However, using define-constant may be preferable as a matter of style.
That also seems to avoid the VerifyError you mentioned when using define.
(Though a VerifyError is of course definitely a compiler bug.)
--
	--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]