Open r-k-o opened 7 years ago
That means there are over 1024 export types in your module. If you want more, just change the const MaxExpTypes in Base module of the compiler, however, I don't recommend doing so because compiling time may be high.
i did: MaxExpTypes* = 16384;
i did not help. i can compile a few lines more but it will bring up "file pos xxxxxxx: No :". maybe there is an other place that has to changed too. so i changed MaxRecTypes* = 16384 - but that did not help either.
doubled the 2 constants again and now i get:
file pos 524287: param section?
and position being in line "CharToOemBuffW*: PROCEDURE(lpszSrc: PtrWSTR; lpszDst: PtrSTR; cchDstLength: INTEGER): BOOL;"
position at "PtrSTR" which is
PtrSTR* = INTEGER;
after trippling the constants values the error persists
This is due to Parser module, not Base, so could you attach the source code?
Ah, I remember that I also limit the size of input source code, just change the buffer array in Scanner module. Also the size of code array in Generator too.
And why don't you break the WinAPI module into smaller modules, because not every program will use all of Win32 API, and the interface cost will be large.
yes, i should split, but for learning that stuff i thought it would be easier going this way first.
i know i am pestering you, but now i have a different error. i user the version before the "New Mark and Sweep algorithm". i compile the winapi, where i commented out huge portions. i compile the wintest and start the exe. a messagebox pops up showing "Error code: 8; Source pos 700104". this position is the end of file? WinApi.mod.txt wintest.mod.txt
No problem at all =) Error Code 8 means this module cannot find RTL.DLL You should add the pragma (*$RTL-*) to both WinApi.mod and Wintest.mod, because they didn't need Oberon Run Time Library. For example, check Oberon07.Rtl.mod in my compiler, that module run on bare Win32.
thanx for the help and also for the new integers.
How can I start using the compiler on my windows
@stepchuks9 To start using it, just create your sourcefile in test folder, for example MyModule.mod, edit the Buildfile in test folder to add your module into it, and run the buildtest.bat
See the examples in test folder!
thanks
How do I write an array of strings. VAR a: ARRAY 10 OF ARRAY 12 OF CHAR; gives me a 2-dimensional array of char. Is there a way to get something simpler than VAR a: ARRAY 10 OF RECORD b: ARRAY 12 OF CHAR END;
@stepchuks9 I believe VAR a: ARRAY 10 OF ARRAY 12 OF CHAR also counted as array of strings, for example, this code:
VAR a: ARRAY 10 OF ARRAY 12 OF CHAR;
PROCEDURE ReadString(VAR str: ARRAY OF CHAR);
BEGIN (* do something *)
END ReadString;
BEGIN
ReadString(a[0])
END Module.
works.
Thanks again.
the compiler quits on winapi
with
Compile winapi.mod file pos 401631: Too many exported types
adding some more exports brings: file pos 524287: No :