среда, 31 марта 2021 г. в 20:31:59 UTC+3, Андрей Никитин:was to remove some additional features that were missing in the Hi-Tech C version. That helped. The programs compiled normally. Perhaps part of the code needs to be moved into a separate function and the remaining little-demanded features should be
среда, 31 марта 2021 г. в 19:30:24 UTC+3, fred_...@hotmail.com:
On Sunday, March 28, 2021 at 6:51:15 PM UTC-4, nikiti...@gmail.com wrote:
Today on github.com I posted the decompiled code
CPP.COM programs from the Hi-Tech C compiler v3.09 for CP/M and a new preprocessor for this compiler with support for C++ comments and compatible with the former. The code can be downloaded from the following link
https://github.com/nikitinprior/dcppVery Welcome Change!
Thanks for your work! Much appreciated. Less changes to C code to bring to Z80. As a PS. The new CPP cannot
be built on a "real box" -- it needs more than 63k CP/M (I guess zxc provides 64k environment, or maybe even
larger). Not a serious issue....
Thanks Again!Thank you for your kind wishes.
FredW
I compiled the new preprocessor using zxc. At first I tried to leave all the functions that were present in the file with the source code of the J. Schilling program. However, I ran into a lack of memory while optimizing the program. The next step
In addition to handling C++ comments, it is important to be able to compile the program on real hardware. This is one of my tasks.
RegardsI installed a new preprocessor on my computer in the Hi-Tech C environment and in the process I will check the correctness of its work. I would be grateful to everyone who can help with testing and finding bugs. Together w can bring it to a good sta
Andrey Nikitin
On Wednesday, March 31, 2021 at 4:38:57 PM UTC-4, nikiti...@gmail.com wrote:was to remove some additional features that were missing in the Hi-Tech C version. That helped. The programs compiled normally. Perhaps part of the code needs to be moved into a separate function and the remaining little-demanded features should be
среда, 31 марта 2021 г. в 20:31:59 UTC+3, Андрей Никитин:
среда, 31 марта 2021 г. в 19:30:24 UTC+3, fred_...@hotmail.com:
On Sunday, March 28, 2021 at 6:51:15 PM UTC-4, nikiti...@gmail.com wrote:
Today on github.com I posted the decompiled code
CPP.COM programs from the Hi-Tech C compiler v3.09 for CP/M and a new preprocessor for this compiler with support for C++ comments and compatible with the former. The code can be downloaded from the following link
https://github.com/nikitinprior/dcppVery Welcome Change!
Thanks for your work! Much appreciated. Less changes to C code to bring to Z80. As a PS. The new CPP cannot
be built on a "real box" -- it needs more than 63k CP/M (I guess zxc provides 64k environment, or maybe even
larger). Not a serious issue....
Thanks Again!Thank you for your kind wishes.
FredW
I compiled the new preprocessor using zxc. At first I tried to leave all the functions that were present in the file with the source code of the J. Schilling program. However, I ran into a lack of memory while optimizing the program. The next step
In addition to handling C++ comments, it is important to be able to compile the program on real hardware. This is one of my tasks.
RegardsI installed a new preprocessor on my computer in the Hi-Tech C environment and in the process I will check the correctness of its work. I would be grateful to everyone who can help with testing and finding bugs. Together w can bring it to a good sta
Andrey Nikitin
Andrey
Hope you get this -- I have been using HI-TECH C 3.09 with your new CPP. So far, everything is great!
But note the following:
1 - #pragma, #error, #ident are... useless. just copied through. Can these be discarded? Or, just let them be
bad preproc directives (saves space). HI-TECH z80 implements NO pragmas.
2 - It would be VERY useful to have "#warning message" -- just display file: line: warning: message on the console
and continue. Do NOT copy through to output!
This would allow better compatibility with gcc. Right now, we can get a warning from GCC but NOT hi-tech
#ifdef z80
... something
#else
#pragma GCC warning "gcc not good here"
#endif
does it. But... we cannot warn on z80 compile for anything... #pragma is copied through, and will
cause an error in P1 We cannot use #warning, as that will cause CPP to fail. And that is why I
would love to have #warning on the HI-TECH CPP. #error COULD be coded to exit(1) the preprocessor.
That would be useful.
FredW
суббота, 26 июня 2021 г. в 01:34:38 UTC+3, fridtjof.ma...@gmail.com:step was to remove some additional features that were missing in the Hi-Tech C version. That helped. The programs compiled normally. Perhaps part of the code needs to be moved into a separate function and the remaining little-demanded features should be
On Wednesday, March 31, 2021 at 4:38:57 PM UTC-4, nikiti...@gmail.com wrote:
среда, 31 марта 2021 г. в 20:31:59 UTC+3, Андрей Никитин:
среда, 31 марта 2021 г. в 19:30:24 UTC+3, fred_...@hotmail.com:
On Sunday, March 28, 2021 at 6:51:15 PM UTC-4, nikiti...@gmail.com wrote:
Today on github.com I posted the decompiled code
CPP.COM programs from the Hi-Tech C compiler v3.09 for CP/M and a new preprocessor for this compiler with support for C++ comments and compatible with the former. The code can be downloaded from the following link
https://github.com/nikitinprior/dcppVery Welcome Change!
Thanks for your work! Much appreciated. Less changes to C code to bring to Z80. As a PS. The new CPP cannot
be built on a "real box" -- it needs more than 63k CP/M (I guess zxc provides 64k environment, or maybe even
larger). Not a serious issue....
Thanks Again!Thank you for your kind wishes.
FredW
I compiled the new preprocessor using zxc. At first I tried to leave all the functions that were present in the file with the source code of the J. Schilling program. However, I ran into a lack of memory while optimizing the program. The next
staIn addition to handling C++ comments, it is important to be able to compile the program on real hardware. This is one of my tasks.
RegardsI installed a new preprocessor on my computer in the Hi-Tech C environment and in the process I will check the correctness of its work. I would be grateful to everyone who can help with testing and finding bugs. Together w can bring it to a good
Andrey Nikitin
Andrey
Hope you get this -- I have been using HI-TECH C 3.09 with your new CPP. So far, everything is great!
But note the following:
1 - #pragma, #error, #ident are... useless. just copied through. Can these be discarded? Or, just let them be
bad preproc directives (saves space). HI-TECH z80 implements NO pragmas.
2 - It would be VERY useful to have "#warning message" -- just display file: line: warning: message on the console
and continue. Do NOT copy through to output!
This would allow better compatibility with gcc. Right now, we can get a warning from GCC but NOT hi-tech
#ifdef z80
... something
#else
#pragma GCC warning "gcc not good here"
#endif
does it. But... we cannot warn on z80 compile for anything... #pragma is copied through, and will
cause an error in P1 We cannot use #warning, as that will cause CPP to fail. And that is why I
would love to have #warning on the HI-TECH CPP. #error COULD be coded to exit(1) the preprocessor.
That would be useful.
FredWFirst you write:
"#pragma, #error, #ident are... Can these be discarded?",
and at the end you offer:
"#error COULD be coded to exit(1) the preprocessor."
this is not entirely logical.
I am not the author of this program, but only adapted it for compiling HI-TECH C 3.09.
The code for processing the "#error message " directive was already present in the program and it only needs to be activated. I have made the appropriate changes to the program and I express my gratitude for the comment made.
As for other directives, they do not interfere and do not require a lot of memory.
The "#warning message " directive can be added, but in GCC it is implemented via #pragma. Therefore, compatibility with GCC will not be achieved.
Thank you for your comments
Andrey Nikitin
Sysop: | Keyop |
---|---|
Location: | Huddersfield, West Yorkshire, UK |
Users: | 286 |
Nodes: | 16 (2 / 14) |
Uptime: | 87:50:03 |
Calls: | 6,496 |
Calls today: | 7 |
Files: | 12,100 |
Messages: | 5,277,252 |