- if (parts & (TPRT|VPRT))
- error("Constant declarations must precede type and variable declarations");
- if (parts & CPRT)
- error("All constants must be declared in one const part");
- parts |= CPRT;
+/*
+ * this allows for multiple declaration
+ * parts, unless the "standard" option
+ * has been specified.
+ * If a routine segment is being compiled,
+ * do level one processing.
+ */
+
+ if (!progseen)
+ level1();
+ if (parts[ cbn ] & (TPRT|VPRT|RPRT)) {
+ if ( opt( 's' ) ) {
+ standard();
+ } else {
+ warning();
+ }
+ error("Constant declarations should precede type, var and routine declarations");
+ }
+ if (parts[ cbn ] & CPRT) {
+ if ( opt( 's' ) ) {
+ standard();
+ } else {
+ warning();
+ }
+ error("All constants should be declared in one const part");
+ }
+ parts[ cbn ] |= CPRT;