Path: utzoo!utgpu!news-server.csri.toronto.edu!rutgers!usc!samsung!uakari.primate.wisc.edu!dali.cs.montana.edu!milton!toby!spellbinder From: spellbinder@uwav1.u.washington.edu Newsgroups: comp.sys.mac.programmer Subject: Message-ID: <13955.268a81d4@uwav1.u.washington.edu> Date: 29 Jun 90 05:16:52 GMT Organization: University of Washington, Seattle WA Lines: 38 Here is a compiler question for those programmers out in net-land. I'm writing a Pascal procedure which performs some mathematical computations. The procedure gets passed handles to the data, which look like this type ArrayRecord = record arraySize : longint; signal : array [ 0..1 ] of real; end; ArrayRecordPtr = ^ArrayRecord; ArrayRecordHdl = ^ArrayRecordPtr; The procedure knows how much data there is by getting the arraySize variable. Now I'm writing this code in THINK Pascal version 2.03. It works fine when the amount of memory dedicated to the signal array is less than 32K, but when it gets bigger than this, then things start to mess up. So basically, for array sizes less than 8K data points, everything's fine. My idea is that THINK Pascal has a problem getting a value at an offset greater than 32K from the start of the variable. I have verified my idea by changing signal to become an array of double and an array of extended and each time the procedure craps out when the data exceeds 32K. My feeling is that the compiler is not generating the correct code to access values beyond 32K. My questions are this: 1) Is there another explanation for the problem? 2) Are there any work arounds in THINK Pascal version 2.03? 3) Will THINK Pascal 3.01 avoid the problem? Thanks in advance. Blair Zajac Zajac@phast.phys.washington.edu Physics Dept. University of Washington