Modify

Ticket #221 (assigned defect)

Opened 8 years ago

Last modified 8 years ago

Assert keyword not supported

Reported by: hauma Owned by: moschny
Priority: normal Milestone:
Component: gjc Version: 1.07h
Severity: normal Keywords:
Cc:

Description

Java 1.4 adds an assert keyword to the language. This new keyword should be accepted by the compiler. Otherwise, existing code cannot be used easily.

Attachments

Change History

comment:1 Changed 8 years ago by moschny

  • Status changed from new to assigned

It should be relatively easy to fix the compiler to accept code with the assert keyword, however, it will be completely ignored then.

True assert support will not be there very soon.

comment:2 Changed 8 years ago by moschny

As described in

http://java.sun.com/docs/books/jls/assert-spec.html

the Java compiler does a relatively trivial transformation to wrap assert statements into if clauses guarded by a static final boolean variable that decides whether assertions are turned on or off.

View

Add a comment

Modify Ticket

Change Properties
<Author field>
Action
as assigned
as The resolution will be set. Next status will be 'closed'
to The owner will be changed from moschny. Next status will be 'new'
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.