Search found 10 matches

by jackD
Sun Feb 20, 2022 7:52 am
Forum: BlackBox Framework
Topic: Computing Fundamentals -- Errors in module
Replies: 8
Views: 5902

Re: Computing Fundamentals -- Errors in module

Replace

Code: Select all

PROCEDURE PrintLine (x: REAL; IN f: PboxMappers.Formatter);
To

Code: Select all

PROCEDURE PrintLine (x: REAL; VAR f: PboxMappers.Formatter);
Now it's compiling without error. Thanks Ivan.
by jackD
Sat Feb 19, 2022 8:03 pm
Forum: BlackBox Framework
Topic: Computing Fundamentals -- Errors in module
Replies: 8
Views: 5902

Re: Computing Fundamentals -- Errors in module

Ivan, thanks. I guess the book is showing its age.

But when I make the change I get a new error at the line which calls the procedure:

Code: Select all

PrintLine(dataValue, fm);
The error is "incompatible assignment", after fm.
by jackD
Sat Feb 19, 2022 2:58 pm
Forum: BlackBox Framework
Topic: Computing Fundamentals -- Errors in module
Replies: 8
Views: 5902

Computing Fundamentals -- Errors in module

I'm working through the book Computing Fundamentals and the module on page 257 is giving me errors at the f.Write statements in the PrintLine procedure. The error messages are that the variables (fields) are read only. I haven't got far enough yet in the book to understand why this is happening, or ...
by jackD
Thu Feb 10, 2022 11:59 am
Forum: Component Pascal
Topic: Sets with more than 32 elements?
Replies: 7
Views: 7921

Re: Sets with more than 32 elements?

Helmut, thanks for the heads up regarding Coco. I've adapted the Ulm Sets library I linked to previously and it works fine, although it's a bit clunky and more work to initialize a set with known elements because you can't just do mySet := {....}. It would be nice to be able to do something like: CO...
by jackD
Wed Feb 09, 2022 7:50 am
Forum: Component Pascal
Topic: Sets with more than 32 elements?
Replies: 7
Views: 7921

Re: Sets with more than 32 elements?

Thanks guys for the responses. I'm still learning and haven't quite grasped how OOP works in CP, so I don't fully understand the code, but I'll get there. I found a module for sets here :

https://www.mathematik.uni-ulm.de/obero ... s.mod.html
by jackD
Tue Feb 08, 2022 2:37 pm
Forum: Component Pascal
Topic: Sets with more than 32 elements?
Replies: 7
Views: 7921

Sets with more than 32 elements?

In CP the largest element of a set is 31, which is too restrictive for my application. Is there an efficient way to create sets with up to 100 elements? (actually, 0-63 would be enough). I'm aware that there is way to do it using boolean arrays, but haven't been able to figure out exactly how. Thanks!
by jackD
Mon Feb 07, 2022 11:35 am
Forum: BlackBox Framework
Topic: CpcDropDown not found
Replies: 2
Views: 3022

Re: CpcDropDown not found

Thanks Ivan.
by jackD
Mon Feb 07, 2022 9:44 am
Forum: BlackBox Framework
Topic: CpcDropDown not found
Replies: 2
Views: 3022

CpcDropDown not found

Hi, I've downloaded the CpcPreprocessor file from zinnamturm.eu but when trying to run the command "StdMenuTool.UpdateAllMenus; CpcDropDown.MakeDropDowns" in the quick-start Docu I get an error telling me CpcDropDown can't be found (side note: I'm assuming when the text is red it means the...
by jackD
Sun Oct 31, 2021 3:22 pm
Forum: Component Pascal
Topic: Oberon & writing files
Replies: 2
Views: 4117

Re: Oberon & writing files

Thanks for the reply. I haven't used OBNC but presumably you can redirect the output to a file? Duh, I never thought of that! Yes, it works fine, so I needn't use the file module at all, unless I need to read/write binary files. And thanks for the link to the ETH mailing list. If I have any more pro...
by jackD
Sun Oct 31, 2021 10:56 am
Forum: Component Pascal
Topic: Oberon & writing files
Replies: 2
Views: 4117

Oberon & writing files

Not sure if it's ok to post here because my query is about Oberon (specifically Oberon-07) rather than C.P., but as they are so similar I thought it would be ok, and I haven't found any other forums or mailing lists for Oberon related questions (comp.lang.oberon seems to be defunct). I'm new to Ober...