CompuServe Thread

#AppMaker TCL Problem

3 messages in this thread
#7129From: Tony MannJul 18, 1993 9:55 PM
Pardon my jumping in, but I am having the EXACT same problem that Burt is having using AM 1.5.4X. Just to verify that the bug is AM's fault, I did the following using your AMReminder app: (1) Duplicate AMReminder folder (2) In the TCL folder, remove all source code. (3) Generate source code. (4) Open AMReminder++.~ in TPM. (5) Update project and run. Works fine. (6) Now change Extensions so ".cp" uses SC++. (7) Remove oopsDebug and add oopsDebug++. (8) Add ANSI++-small and CPLusLib. (9) Update project and run. (10) An alert appears: OS error -111. Tracing reveals that the bug is the one you are aware of:in the MakeClipboard() method in the IApp method. So what I deduce is this: AM does not work correctly with SC++! I hope that I am wrong about this, since I was planning on using AM on a major C++ project in the very near future. Please let me know ASAP whether there is a workaround, and if not, when the problem will be fixed. Tony Mann
#7154From: Spec BowersJul 19, 1993 11:43 AM
Tony, The problem that Burt had and that you are having is that CPlusLib must be in a resident segment. It's not an AppMaker problem or a TCL problem or a compiler problem. It's just that there are some libraries (CPlusLib and oopsDebug++, possibly others) that must be resident. In Burt's case, and yours is apparently exactly the same problem, the compiled TCL code was causing a segment load which was moving memory. An object handle was dereferenced and pointed to garbage after its memory was moved out from underneath it. The simple cure is to move CPlusLib and oopsDebug++ to a segment that is guaranteed to have been loaded already – e.g. the segment that has "main" or that has CApplication or MacTraps, etc. Spec
#7193From: Tony MannJul 20, 1993 2:48 AM
Spec, Bravo! I moved CPlusLib to the MacTraps segment, and everything worked peachily! Thanks for solving this perplexing problem for me. In any case, to avoid these problems, I suggest that you do the following: * Provide a Starter++ project with all the segments set up properly and the extensions mapped for C++. * Mark the project as stationery. This avoids the tedious duplicating and renaming process whenever you make a new project. –Tony Mann