![]() |
||
| Home | SwiftForth Archive | SwiftX Archive | |

Date: Fri, 16 Apr 1999 13:14:09 +6
From: "Gene LeFave" <gene_at_tekdata.com>
>Rick,
>
>It is my understanding that the only times call backs are nested is
>as a result of calling the DefWinProc or else by originating the
>message itself. In both these cases I would think that the same
>user table would actually be preferred.
>> it is not the case that callbacks are not nested. They
Gene,
Unless you can provide conclusive documentation from windows that
indicates that callbacks do not need to be re-entrant, I (as an
implementer) will have to leave them where they are fully re-entrant.
For what it is worth, using the user area does not make arbitrary
code automatically re-entrant, unless each invocation of the code
is running in a separate task with its own user area.
The overhead for creating the user area in the callback is not
great -- and the intent is not for long-term stable data, but
for a virtual dictionary that the callback routine can reference.
The next version of SwiftForth will be an integrated object model,
where each window (which amounts to each callback) can have local
persistent data. You can also easily do this by allocating memory
during WM_CREATE and disposing of it during WM_DESTROY, which is
the preferred windows method for having window-persistent data.
The address can be kept in windows extra bytes, or as a named
property. The named property method is what will be used (I think!)
in the next release.
Rick
.
Received on Fri Apr 16 1999 - 13:14:09 PDT
This archive was generated by hypermail 2.2.0 : Thu Nov 20 2008 - 03:04:26 PST