EKEY Event Record

[ RfDs/CfVs | Other proposals ]

Poll Standings

See below for voting instructions.
Systems
[ ] conforms to ANS Forth.
bigForth (Bernd Paysan)
[ ] already implements the proposal in full since release [ ].
[ ] implements the proposal in full in a development version.
[ ] will implement the proposal in full in release [ ].
[ ] will implement the proposal in full in some future release.
SwiftForth (Leon Wagner)
SwiftX (Leon Wagner)
[ ] There are no plans to implement the proposal in full in [ ].
4tH (Hans Bezemer)
[ ] will never implement the proposal in full.
bigForth (Bernd Paysan)
Programmers
[ ] I have used (parts of) this proposal in my programs.
[ ] I would use (parts of) this proposal in my programs if the systems I am interested in implemented it.
Leon Wagner
[ ] I would use (parts of) this proposal in my programs if this proposal was in the Forth standard.
Bernd Paysan
[ ] I would not use (parts of) this proposal in my programs.
Hans Bezemer

Informal Results

Problem

The rationale for EKEY allows for an "event record" being returned but the word has a signature of ( -- u ) which forbids the address of such a record being returned.

Solution

Correct the stack signature of EKEY to ( -- x ) in order to allow an address to be returned. The stack descriptions of both EKEY>CHAR and EKEY>FKEY must also be changed to allow them to accept an address (x) rather than a value (u).

Proposal

  1. Replace u with x in the definition of 10.6.2.1305 EKEY.
    ( -- u ) becomes ( -- x )
  2. Replace the u with x in the definition of 10.6.2.1306 EKEY>CHAR.
    ( u -- u false | char true ) becomes ( x -- x false | char true ).
  3. Change the definition of 10.6.2.xxxx EKEY>FKEY from
    ( u1 -- u2 f ) to ( x -- u flag ).
  4. Define the lifetime of the "event record" by adding the following to the definition of 10.6.2.1305 EKEY:
    x is valid until the next call to EKEY or EKEY?.

Change History

2010-02-24
Minor revisions
2009-09-03
Separated from KEY/EKEY proposal.
2009-03-31
Original Text

Author

Peter Knaggs
Engineering, Mathematics and Physical Sciences,
University of Exeter, Exeter, Devon EX4 7QF, England

Voting Instructions

Fill out the appropriate ballot(s) below and mail it/them to <vote@forth200x.org>. Your vote will be published (including your name (without email address) and/or the name of your system) here. You can vote (or change your vote) at any time, and the results will be published here.

Note that you can be both a system implementor and a programmer, so you can submit both kinds of ballots.

Ballot for systems
If you maintain several systems, please mention the systems separately in the ballot. Insert the system name or version between the brackets. Multiple hits for the same system are possible (if they do not conflict).
[ ] conforms to ANS Forth.
[ ] already implements the proposal in full since release [ ].
[ ] implements the proposal in full in a development version.
[ ] will implement the proposal in full in release [ ].
[ ] will implement the proposal in full in some future release.
[ ] There are no plans to implement the proposal in full in [ ]
.
[ ] will never implement the proposal in full.
If you want to provide information on partial implementation, please do so informally, and I will aggregate this information in some way.
Ballot for programmers
Just mark the statements that are correct for you (e.g., by putting an "x" between the brackets). If some statements are true for some of your programs, but not others, please mark the statements for the dominating class of programs you write.
[ ] I have used (parts of) this proposal in my programs.
[ ] I would use (parts of) this proposal in my programs if the systems I am interested in implemented it.
[ ] I would use (parts of) this proposal in my programs if this proposal was in the Forth standard.
[ ] I would not use (parts of) this proposal in my programs.
If you feel that there is closely related functionality missing from the proposal (especially if you have used that in your programs), make an informal comment, and I will collect these, too. Note that the best time to voice such issues is the RfD stage.

Credits

Proponent: Peter Knaggs
Votetaker: Peter Knaggs