Hi folks:
I'm using
GNU Pascal version 20000707, based on gcc-2.95.2 19991024 (release). Copyright (C) 1987, 1989, 1992-2000 Free Software Foundation, Inc.
while my student Ryan is using:
GNU Pascal version 2.1 (20020510), based on gcc-2.95.3 20010315 (release). Copyright (C) 1987-2002 Free Software Foundation, Inc.
I have no problem compiling with
gpc --standard-pascal \ --transparent-file-names \ --no-mixed-comments \ -O0 \ -Wall \ $program.p -o $program
but Ryan has trouble compiling a program that has a call to the page() function:
alist.p:3960: undeclared identifier `Page' (first use in this routine)
To my surprise, this is listed:
http://www.gnu-pascal.de/gpc/Page.html
as "Page is an ISO 10206 Extended Pascal extension."
Did GPC change between these compilers? Does the use of page() mean I cannot use --standard-pascal ? page() was in the original book! It is listed on page 105 (Appendix A) as a standard procedure!
Tom
Dr. Thomas D. Schneider National Cancer Institute Laboratory of Experimental and Computational Biology Frederick, Maryland 21702-1201 toms@ncifcrf.gov permanent email: toms@alum.mit.edu (use only if first address fails) http://www.lecb.ncifcrf.gov/~toms/
On Thu, Jul 08, 2004 at 06:29:05PM -0400, Tom Schneider wrote:
Hi folks:
I'm using
GNU Pascal version 20000707, based on gcc-2.95.2 19991024 (release). Copyright (C) 1987, 1989, 1992-2000 Free Software Foundation, Inc.
while my student Ryan is using:
GNU Pascal version 2.1 (20020510), based on gcc-2.95.3 20010315 (release). Copyright (C) 1987-2002 Free Software Foundation, Inc.
I have no problem compiling with
gpc --standard-pascal \ --transparent-file-names \ --no-mixed-comments \ -O0 \ -Wall \ $program.p -o $program
but Ryan has trouble compiling a program that has a call to the page() function:
alist.p:3960: undeclared identifier `Page' (first use in this routine)
To my surprise, this is listed:
http://www.gnu-pascal.de/gpc/Page.html
as "Page is an ISO 10206 Extended Pascal extension."
Did GPC change between these compilers? Does the use of page() mean I cannot use --standard-pascal ? page() was in the original book! It is listed on page 105 (Appendix A) as a standard procedure!
Yes, the GPC docs are wrong, `page' is ISO 7185.
GPC 20020510 is outdated. The problem with `page' is apparently fixed in newer versions (tested with 20040516), so Ryan may consider upgrading. Some incompatible syntax changes happened meanwhile (e.g. asmname), but they shouldn't affect ISO compliant code which you seem to be using.
Emil Jerabek
Tom Schneider wrote:
I'm using
GNU Pascal version 20000707, based on gcc-2.95.2 19991024 (release). Copyright (C) 1987, 1989, 1992-2000 Free Software Foundation, Inc.
while my student Ryan is using:
GNU Pascal version 2.1 (20020510), based on gcc-2.95.3 20010315 (release). Copyright (C) 1987-2002 Free Software Foundation, Inc.
I have no problem compiling with
gpc --standard-pascal \ --transparent-file-names \ --no-mixed-comments \ -O0 \ -Wall \ $program.p -o $program
but Ryan has trouble compiling a program that has a call to the page() function:
alist.p:3960: undeclared identifier `Page' (first use in this routine)
To my surprise, this is listed:
http://www.gnu-pascal.de/gpc/Page.html
as "Page is an ISO 10206 Extended Pascal extension."
Did GPC change between these compilers? Does the use of page() mean I cannot use --standard-pascal ? page() was in the original book! It is listed on page 105 (Appendix A) as a standard procedure!
I don't remember why it was changed, but apparently it was wrong in 2.1, indeed. In the current releases it's correct (again).
If you can recompile 2.1, here's a fix.
Frank