1#[derive(Clone, Copy, Debug, PartialEq, Eq)]
2pub enum Oracle {
3 Hercules,
5 EnterpriseCobol,
7 Db2,
9}
10
11#[derive(Clone, Copy, Debug, PartialEq, Eq)]
12pub enum Basis {
13 Documented,
15 Recalled,
17 Chosen,
19 Observed,
22}
23
24#[derive(Clone, Copy, Debug)]
25pub struct Assumption {
26 pub id: &'static str,
27 pub claim: &'static str,
28 pub basis: Basis,
29 pub oracle: Oracle,
30}
31
32pub const HFP_EXTENDED_LOW_HALF: &str = "M1";
33pub const HFP_FROM_FIXED_TRUNCATES: &str = "M2";
34pub const INTERMEDIATE_TABLE: &str = "C1";
35pub const TRUNC_OPT_IS_BINARY: &str = "C2";
36pub const PFD_MOVES_BYTES: &str = "C3";
37pub const PFD_COMPARES_LOGICALLY: &str = "C4";
38pub const FLOAT_FROM_DECIMAL: &str = "C5";
39pub const FLOAT_TO_DECIMAL: &str = "C6";
40pub const FLOAT_NARROWING_ROUNDS: &str = "C7";
41pub const LE_MASKS_UNDERFLOW: &str = "C8";
42pub const PREFERRED_RESULT_SIGNS: &str = "C9";
43pub const ZONED_BY_PACK: &str = "C10";
44pub const CCSID_TABLES: &str = "C11";
45pub const WORKING_STORAGE_LAYOUT: &str = "C12";
46pub const NOPFD_REPAIRS_UNSIGNED_INPUT: &str = "C13";
47pub const DISPLAY_OF_NONDISPLAY_NUMERIC: &str = "C14";
48pub const ACCEPT_AT_END: &str = "C15";
49pub const CONTENT_LITERAL_ZONED: &str = "C16";
50pub const KEYED_FILE_STATUS: &str = "C17";
51pub const ALTERNATE_KEY_ORDER: &str = "C18";
52pub const FAILED_READ_LOSES_POSITION: &str = "C19";
53pub const START_COMPARES_SHORTER: &str = "C20";
54pub const REWRITE_SHARED_ALTERNATE: &str = "C21";
55pub const CICS_FRESH_STORAGE: &str = "C22";
56pub const CICS_CALEN_RESTORED: &str = "C23";
57pub const CICS_HANDLE_ABEND_CATCHES_CONDITIONS: &str = "C24";
58pub const CICS_LENGTH_DEFAULTS_TO_INTO: &str = "C25";
59pub const CICS_PROGRAM_CHECK_IS_ASRA: &str = "C26";
60pub const CICS_BROWSE_SKIP: &str = "C27";
61pub const BMS_RECEIVE_NULLS: &str = "C28";
62pub const BMS_INPUT_JUSTIFY: &str = "C29";
63pub const BMS_EXTENDED_ORDER: &str = "C30";
64pub const BMS_CONSTANTS_UNVERIFIED: &str = "C31";
65pub const BMS_SEND_DATA_CHOICE: &str = "C32";
66pub const CICS_INITIAL_AID: &str = "C33";
67pub const LONG_ZONED_BY_PACKS: &str = "C34";
68pub const ASCII_COLLATION: &str = "C35";
69pub const TABLE_SORT_COLLATION: &str = "C36";
70pub const ALPHABET_LITERALS: &str = "C37";
71pub const LE_SERVICE_AFTER_PROGRAMS: &str = "L1";
72pub const LE_ARGUMENTS_BY_ADDRESS: &str = "L2";
73pub const LE_FEEDBACK_TOKEN: &str = "L3";
74pub const LE_FEEDBACK_NO_INSTANCE_INFO: &str = "L4";
75pub const LE_OMITTED_FC_ABENDS: &str = "L5";
76pub const LE_CEE3ABD: &str = "L6";
77pub const LE_LOCAL_TIME_IS_UTC: &str = "L7";
78pub const LE_SECONDS_HFP: &str = "L8";
79pub const LE_PICTURE_OUTPUT: &str = "L9";
80pub const LE_PICTURE_INPUT: &str = "L10";
81pub const LE_CENTURY_WINDOW: &str = "L11";
82pub const LE_RETURN_CODE_UNCHANGED: &str = "L12";
83pub const LE_MESSAGE_AND_DUMP_FILES: &str = "L13";
84pub const LE_HEAP: &str = "L14";
85pub const LE_UNDER_CICS: &str = "L15";
86pub const LE_CEEIGZCT: &str = "L16";
87pub const LE_CEEIGZCT_DISAGREEMENTS: &str = "L17";
88pub const LE_SHORT_ARGUMENT_LIST: &str = "L18";
89pub const LE_SSRANGE_U4038: &str = "L19";
90pub const REPORT_WRITER_PRECOMPILER: &str = "RW1";
91pub const REPORT_TOTALS_BEFORE_PAGE_FIT: &str = "RW2";
92pub const REPORT_SOURCE_SUM_CORRELATION: &str = "RW3";
93pub const REPORT_PAGE_REGION_DEFAULTS: &str = "RW4";
94pub const REPORT_LINE_WRITES: &str = "RW5";
95pub const REPORT_CARRIAGE_CONTROL: &str = "RW6";
96pub const REPORT_RECORD_LENGTH: &str = "RW7";
97pub const REPORT_SUM_OVERFLOW: &str = "RW8";
98pub const REPORT_SOURCE_OVERFLOW: &str = "RW9";
99pub const REPORT_SUPPRESS_PRINTING: &str = "RW10";
100pub const REPORT_NEW_PAGES: &str = "RW11";
101pub const REPORT_OUT_OF_ORDER: &str = "RW12";
102pub const REPORT_CONTROL_AREA: &str = "RW13";
103pub const OBJECT_REFERENCE_VALUE: &str = "J1";
104pub const LOCAL_REFERENCES_EXPIRE: &str = "J2";
105pub const OBJECTS_NEVER_FREED: &str = "J3";
106pub const INSTANCE_DATA_START: &str = "J4";
107pub const FACTORY_DATA_START: &str = "J5";
108pub const METHOD_LOOKUP: &str = "J6";
109pub const METHOD_NAME_ITEM: &str = "J7";
110pub const INVOKE_NULL: &str = "J8";
111pub const NO_METHOD_ABEND: &str = "J9";
112pub const FACTORY_SELF: &str = "J10";
113pub const CLASS_SEARCH: &str = "J11";
114pub const INVOKE_KEEPS_RETURN_CODE: &str = "J12";
115pub const OO_OPTIONS_REQUIRED: &str = "J13";
116pub const CHAR_FROM_DISPLAY: &str = "J14";
117pub const LOCAL_REFERENCES_OUTSIDE_METHODS: &str = "J15";
118pub const SELF_IS_LOCAL: &str = "J16";
119pub const EXPIRED_REFERENCE_ABENDS: &str = "J17";
120pub const LOCAL_FRAMES: &str = "J18";
121pub const OO_OPTIONS_SEVERITY: &str = "J19";
122pub const REFERENCES_KEPT: &str = "J20";
123pub const SQL_COMMIT_AT_NORMAL_END: &str = "SQ1";
124pub const SQL_WHENEVER_ORDER: &str = "SQ2";
125pub const SQL_TRUNCATED_INDICATOR: &str = "SQ3";
126pub const SQL_POSTGRES_ERRORS: &str = "SQ4";
127pub const SQL_DIALECT_REWRITES: &str = "SQ5";
128pub const SQL_INTO_WITHOUT_COLONS: &str = "SQ7";
129pub const SQL_DECLARATIONS_CROSS_NESTED_PROGRAMS: &str = "SQ8";
130pub const SQL_DOUBLE_TO_HFP_TRUNCATES: &str = "SQ9";
131pub const SQL_ZONED_IS_DECIMAL: &str = "SQ10";
132pub const SQL_ISO_DATETIME: &str = "SQ11";
133pub const SQL_TRAILING_BLANKS_SENT: &str = "SQ12";
134pub const SQL_FETCH_ROW_COUNT: &str = "SQ13";
135pub const SORT_EQUAL_KEYS_IN_ORDER: &str = "S1";
136pub const MERGE_EQUAL_KEYS_BY_FILE: &str = "S2";
137pub const MERGE_OUT_OF_SEQUENCE_FAILS: &str = "S3";
138pub const SORT_FILE_FAILURE: &str = "S4";
139pub const SORT_DECIMAL_KEYS: &str = "S5";
140pub const SORT_RECORD_LENGTHS: &str = "S6";
141pub const SORT_RETURN_STOPS: &str = "S7";
142pub const RETURN_AFTER_END: &str = "S8";
143pub const SORT_KEY_INVALID_DIGITS: &str = "S9";
144pub const SORT_NEGATIVE_ZERO: &str = "S10";
145pub const FASTSRT_FILES: &str = "S11";
146pub const FASTSRT_STATUS: &str = "S12";
147pub const FASTSRT_FAILURE: &str = "S13";
148pub const SAME_AREA_VSAM: &str = "S14";
149pub const FASTSRT_PRINT_RECORDS: &str = "S15";
150pub const FASTSRT_RECORD_LENGTHS: &str = "S16";
151pub const FASTSRT_ADV_PRINT: &str = "S17";
152pub const PRINT_CONTROL_CHARACTER: &str = "C40";
153pub const PRINT_SPACING_RECORDS: &str = "C41";
154pub const PRINT_CONTROL_RUN_TIME: &str = "C42";
155pub const TEXT_PRINT_LINES: &str = "C43";
156pub const COMPILER_SEVERITIES: &str = "C44";
157pub const REFUSALS_ARE_SEVERE: &str = "C45";
158pub const REFUSED_FROM_S: &str = "C46";
159pub const NOCOMPILE: &str = "C47";
160pub const COMMENT_ENTRY_EXTENT: &str = "C80";
161pub const COMMENT_ENTRY_HEADERS: &str = "C81";
162pub const COMMENT_ENTRY_REMARKS: &str = "C82";
163pub const CONTINUED_LITERAL_QUOTES: &str = "C83";
164pub const COPY_SEARCH_ROUNDS: &str = "C85";
165pub const COPY_NOT_THE_PROGRAM: &str = "C86";
166pub const COPY_LITERAL_AS_WRITTEN: &str = "C87";
167pub const COPY_DOUBLED_PERIOD: &str = "C88";
168pub const LINAGE_COUNTER: &str = "C70";
169pub const LINAGE_PAGE_MOVEMENT: &str = "C71";
170pub const LINAGE_END_OF_PAGE: &str = "C72";
171pub const LINAGE_VALUES: &str = "C73";
172pub const LINAGE_EXTEND: &str = "C74";
173pub const LINAGE_COUNTER_BETWEEN_WRITES: &str = "C75";
174pub const PRINT_FILE_UPDATE: &str = "C76";
175pub const ENTRY_IN_SEQUENCE: &str = "C50";
176pub const ENTRY_CALLS: &str = "C51";
177pub const ALTERED_GO_TO_RESET: &str = "C52";
178pub const DISPLAY_STREAM: &str = "C53";
179pub const RANDOM_GENERATOR: &str = "C54";
180pub const ZERO_DIVISOR_CHECK: &str = "C55";
181pub const ERROR_DECLARATIVE_MODE: &str = "C60";
182pub const ERROR_DECLARATIVE_STATUSES: &str = "C61";
183pub const SORT_FILE_DECLARATIVE: &str = "C62";
184pub const DEBUG_RUNTIME_OPTION: &str = "C63";
185pub const DEBUG_LINE_NUMBER: &str = "C64";
186pub const DEBUG_LINE_STATEMENT: &str = "C65";
187pub const DEBUG_CONTENTS_LENGTH: &str = "C66";
188pub const DEBUG_NAME_FORM: &str = "C67";
189pub const DEBUGGING_SECTION_REFERENCES: &str = "C68";
190pub const GLOBAL_DECLARATIVES: &str = "C69";
191pub const SYNC_SUBORDINATE_GROUP: &str = "C90";
192pub const SYNC_ONLY_WHEN_WRITTEN: &str = "C91";
193pub const SYNC_SLACK_OWNER: &str = "C92";
194pub const SYNC_REDEFINES_REFUSED: &str = "C93";
195pub const DECIMAL_COMMA_SEPARATOR: &str = "C94";
196pub const DECIMAL_COMMA_DISPLAY_LITERAL: &str = "C95";
197pub const ARITH_DIGIT_LIMITS: &str = "C96";
198pub const MULTIPLE_RESULTS: &str = "C97";
199pub const ALTER_DEBUGGING: &str = "C98";
200pub const PERFORM_RETURN_POINTS: &str = "C99";
201pub const FLOAT_FUNCTION_ARGUMENTS: &str = "C100";
202pub const FLOAT_FUNCTION_ROUNDING: &str = "C110";
203pub const FLOATING_POINT_FUNCTIONS: &str = "C111";
204pub const FUNCTION_DOMAIN: &str = "C112";
205pub const NUMVAL_TEST_RULES: &str = "C113";
206pub const FUNCTION_CLOCK: &str = "C114";
207pub const UUID4_SOURCE: &str = "C115";
208pub const FORMATTED_DATETIME_RULES: &str = "C116";
209pub const ROUNDED_EXTRA_PLACE: &str = "C101";
210pub const CURRENCY_SIGNS: &str = "C102";
211pub const JSON_GENERATE_RULES: &str = "C117";
212pub const XML_PARSE_RULES: &str = "C118";
213pub const XML_GENERATE_RULES: &str = "C119";
214pub const JSON_PARSE_RULES: &str = "C200";
215pub const DLI_TRANSLATION: &str = "C201";
216pub const CORRESPONDING_PAIRS: &str = "C130";
217pub const CORRESPONDING_CHOICES: &str = "C131";
218pub const STOP_LITERAL: &str = "C132";
219pub const NUMPROC_MIG_WARNS: &str = "C120";
220pub const INVALID_OPTION_DISCARDED: &str = "C121";
221pub const OPTIONS_WITHOUT_EFFECT: &str = "C122";
222pub const NON_COBOL_CHARACTERS: &str = "C123";
223pub const NO_PROGRAM_END: &str = "C124";
224pub const USE_WITHOUT_PARAGRAPH: &str = "C125";
225pub const PICTURE_ENDS_AT_ITS_SEPARATOR: &str = "C195";
226pub const ZONED_COMPARED_AS_BYTES: &str = "C221";
227pub const APOST_EVERYWHERE: &str = "C210";
228pub const CURRENCY_OPTION: &str = "C211";
229pub const NSYMBOL_DBCS: &str = "C212";
230pub const INITIAL_UNDER_THREAD: &str = "C217";
231pub const VLR_WITHOUT_VARYING: &str = "C218";
232pub const VLR_RECORDS_CHECKED: &str = "C219";
233pub const VSAM_OPEN_NEVER_VERIFIED: &str = "C220";
234pub const DISPSIGN_SEPARATE: &str = "C213";
235pub const LILIAN_INTEGER_DATES: &str = "C214";
236pub const CEECBLDY_UNDER_LILIAN: &str = "C215";
237pub const COMPLETE_SET_OF_QUALIFIERS: &str = "C216";
238pub const INSPECT_FUNCTION_SUBJECT: &str = "C190";
239pub const INSPECT_NATIONAL_FUNCTION_RESULT: &str = "C191";
240pub const NATIONAL_CASE_AND_REVERSE: &str = "C192";
241pub const INVDATA_CLEANSIGN: &str = "C222";
242pub const INVDATA_ZONES_COMPARED: &str = "C223";
243
244pub const ASSUMPTIONS: &[Assumption] = &[
245 Assumption {
246 id: HFP_EXTENDED_LOW_HALF,
247 claim: "An extended HFP result's low half carries the high characteristic minus 14, modulo 128, and is all zero when the value is all zero bits (SA22-7832-14, HFP extended format, p. 18-4)",
248 basis: Basis::Documented,
249 oracle: Oracle::Hercules,
250 },
251 Assumption {
252 id: HFP_FROM_FIXED_TRUNCATES,
253 claim: "CONVERT FROM FIXED to HFP truncates the hexadecimal digits the precision cannot hold",
254 basis: Basis::Recalled,
255 oracle: Oracle::Hercules,
256 },
257 Assumption {
258 id: INTERMEDIATE_TABLE,
259 claim: "Intermediate results carry i and d places up to 30 digits (31 under ARITH(EXTEND)); beyond that, N-d and d when d <= dmax, else i and N-i when i+dmax <= N, else N-dmax and dmax; digits beyond are truncated",
260 basis: Basis::Recalled,
261 oracle: Oracle::EnterpriseCobol,
262 },
263 Assumption {
264 id: TRUNC_OPT_IS_BINARY,
265 claim: "Under TRUNC(OPT) a binary receiver whose value exceeds its PICTURE is truncated at the halfword, fullword or doubleword, as under TRUNC(BIN)",
266 basis: Basis::Chosen,
267 oracle: Oracle::EnterpriseCobol,
268 },
269 Assumption {
270 id: PFD_MOVES_BYTES,
271 claim: "Under NUMPROC(PFD) a MOVE between packed items of the same length and scale copies the bytes, so a non-preferred sign passes through; under NOPFD the receiver gets the preferred sign",
272 basis: Basis::Chosen,
273 oracle: Oracle::EnterpriseCobol,
274 },
275 Assumption {
276 id: PFD_COMPARES_LOGICALLY,
277 claim: "Under NUMPROC(PFD) two packed items of the same length and scale compare byte by byte, so X'1F' and X'1C' differ",
278 basis: Basis::Chosen,
279 oracle: Oracle::EnterpriseCobol,
280 },
281 Assumption {
282 id: FLOAT_FROM_DECIMAL,
283 claim: "A fixed-point decimal m with s decimal places becomes HFP as CONVERT FROM FIXED of m, then an HFP divide by 10^s",
284 basis: Basis::Chosen,
285 oracle: Oracle::EnterpriseCobol,
286 },
287 Assumption {
288 id: FLOAT_TO_DECIMAL,
289 claim: "An HFP value moved or stored into a fixed-point receiver is rounded in the receiver's low-order position, with or without ROUNDED, and keeps at most 9 significant digits from short precision and 18 from long, the rest zero (Programming Guide SC27-8714-03, p. 52); the Language Reference's COMBINED-DATETIME example, 143951.1886781248 from a long value of 143951.18867812478..., shows a COMPUTE rounding (SC27-8713-03, p. 542). Rounding is half away from zero; an extended value keeps every digit the receiver holds",
290 basis: Basis::Documented,
291 oracle: Oracle::EnterpriseCobol,
292 },
293 Assumption {
294 id: FLOAT_NARROWING_ROUNDS,
295 claim: "A floating-point value moved or stored into a narrower COMP-1 or COMP-2 is rounded in the low-order position, as LOAD ROUNDED rounds (Programming Guide SC27-8714-03, p. 52)",
296 basis: Basis::Documented,
297 oracle: Oracle::EnterpriseCobol,
298 },
299 Assumption {
300 id: LE_MASKS_UNDERFLOW,
301 claim: "Language Environment runs COBOL with the HFP exponent-underflow and significance masks off, so both yield a true zero",
302 basis: Basis::Chosen,
303 oracle: Oracle::EnterpriseCobol,
304 },
305 Assumption {
306 id: PREFERRED_RESULT_SIGNS,
307 claim: "Arithmetic results take the preferred sign under either NUMPROC setting: C or D for a signed item, F for an unsigned one",
308 basis: Basis::Recalled,
309 oracle: Oracle::EnterpriseCobol,
310 },
311 Assumption {
312 id: ZONED_BY_PACK,
313 claim: "A zoned operand enters arithmetic as PACK leaves it: zones other than the sign's are discarded, so an embedded space is a zero digit",
314 basis: Basis::Chosen,
315 oracle: Oracle::EnterpriseCobol,
316 },
317 Assumption {
318 id: CCSID_TABLES,
319 claim: "The compiler's conversion to UTF-16 for each carried CCSID is ICU's ibm-* table for it, byte for byte",
320 basis: Basis::Chosen,
321 oracle: Oracle::EnterpriseCobol,
322 },
323 Assumption {
324 id: WORKING_STORAGE_LAYOUT,
325 claim: "Each 01 and 77 item of WORKING-STORAGE starts on an 8-byte boundary in source order, and storage without a VALUE starts as X'00'",
326 basis: Basis::Chosen,
327 oracle: Oracle::EnterpriseCobol,
328 },
329 Assumption {
330 id: NOPFD_REPAIRS_UNSIGNED_INPUT,
331 claim: "Under NUMPROC(NOPFD) an unsigned packed or zoned operand's sign is forced to X'F' before use, so no sign makes it a data exception; under PFD it is used as it stands",
332 basis: Basis::Chosen,
333 oracle: Oracle::EnterpriseCobol,
334 },
335 Assumption {
336 id: DISPLAY_OF_NONDISPLAY_NUMERIC,
337 claim: "DISPLAY shows a packed or binary item as zoned digits of its PICTURE, a negative value's sign overpunched on the last digit and a positive value's digits unsigned (Programming Guide SC27-8714-03, p. 363, Table 48; Language Reference SC27-8713-03, p. 334); a COMP-5 item, or any binary item under TRUNC(BIN), shows its whole binary value in 5, 10, or 19 (signed) or 20 digits for a halfword, fullword or doubleword",
338 basis: Basis::Chosen,
339 oracle: Oracle::EnterpriseCobol,
340 },
341 Assumption {
342 id: ACCEPT_AT_END,
343 claim: "ACCEPT from SYSIN at its end leaves the receiving item unchanged and the run continues",
344 basis: Basis::Chosen,
345 oracle: Oracle::EnterpriseCobol,
346 },
347 Assumption {
348 id: CONTENT_LITERAL_ZONED,
349 claim: "A numeric literal passed BY CONTENT arrives as zoned decimal of its own digits, the sign overpunched when negative",
350 basis: Basis::Chosen,
351 oracle: Oracle::EnterpriseCobol,
352 },
353 Assumption {
354 id: KEYED_FILE_STATUS,
355 claim: "Indexed and relative files report 02 for a shared alternate key, 14 for a record number too long for the RELATIVE KEY on sequential READ, 21 for a sequential WRITE whose key is not above the last (equal included) or a REWRITE that changed the key, 22 duplicate, 23 not found, 24 a record number below 1 or too long for the RELATIVE KEY on WRITE, 43 REWRITE or DELETE with no READ just before, 46 READ NEXT with no next record, and 47, 48, 49 for the wrong open mode",
356 basis: Basis::Recalled,
357 oracle: Oracle::EnterpriseCobol,
358 },
359 Assumption {
360 id: ALTERNATE_KEY_ORDER,
361 claim: "Records sharing an alternate key come back in the order they were written; a record REWRITTEN with a new alternate key goes after the others with it",
362 basis: Basis::Recalled,
363 oracle: Oracle::EnterpriseCobol,
364 },
365 Assumption {
366 id: FAILED_READ_LOSES_POSITION,
367 claim: "A random READ that finds no record leaves no next record, so READ NEXT then gives 46",
368 basis: Basis::Chosen,
369 oracle: Oracle::EnterpriseCobol,
370 },
371 Assumption {
372 id: START_COMPARES_SHORTER,
373 claim: "START compares the key with its operand over the shorter of the two, left to right, as bytes",
374 basis: Basis::Recalled,
375 oracle: Oracle::EnterpriseCobol,
376 },
377 Assumption {
378 id: CICS_FRESH_STORAGE,
379 claim: "A COBOL program reached by EXEC CICS LINK or XCTL starts with fresh WORKING-STORAGE each time, unlike one reached by CALL",
380 basis: Basis::Recalled,
381 oracle: Oracle::EnterpriseCobol,
382 },
383 Assumption {
384 id: CICS_CALEN_RESTORED,
385 claim: "EIBCALEN is the linked program's COMMAREA length while it runs and the caller's again after the LINK returns",
386 basis: Basis::Chosen,
387 oracle: Oracle::EnterpriseCobol,
388 },
389 Assumption {
390 id: CICS_HANDLE_ABEND_CATCHES_CONDITIONS,
391 claim: "HANDLE ABEND LABEL receives control when a condition nothing handles would abend the task (AEIx), and is cancelled by being taken",
392 basis: Basis::Recalled,
393 oracle: Oracle::EnterpriseCobol,
394 },
395 Assumption {
396 id: CICS_LENGTH_DEFAULTS_TO_INTO,
397 claim: "READ, READNEXT, READPREV, READQ TS and READQ TD without LENGTH take the INTO item's length as the limit, so a longer record raises LENGERR",
398 basis: Basis::Recalled,
399 oracle: Oracle::EnterpriseCobol,
400 },
401 Assumption {
402 id: CICS_PROGRAM_CHECK_IS_ASRA,
403 claim: "A program check (S0C4, S0C7 and the like) in a CICS task ends it with transaction abend ASRA",
404 basis: Basis::Recalled,
405 oracle: Oracle::EnterpriseCobol,
406 },
407 Assumption {
408 id: CICS_BROWSE_SKIP,
409 claim: "READNEXT after the program changed RIDFLD to a key the browse is not at continues from the first record at or after the new RIDFLD (skip-sequential)",
410 basis: Basis::Recalled,
411 oracle: Oracle::EnterpriseCobol,
412 },
413 Assumption {
414 id: BMS_RECEIVE_NULLS,
415 claim: "RECEIVE MAP sets the input map to nulls, then fills only the fields the operator modified; a field erased to empty gets F = X'80' and L = 0",
416 basis: Basis::Recalled,
417 oracle: Oracle::EnterpriseCobol,
418 },
419 Assumption {
420 id: BMS_INPUT_JUSTIFY,
421 claim: "Input data lands left-justified and blank-filled unless JUSTIFY says otherwise, and a NUM field right-justified and zero-filled, the defaults IBM documents for JUSTIFY",
422 basis: Basis::Recalled,
423 oracle: Oracle::EnterpriseCobol,
424 },
425 Assumption {
426 id: BMS_EXTENDED_ORDER,
427 claim: "A field's extended attribute bytes in the symbolic map follow its A byte in the order COLOR, PS, HILIGHT, VALIDN, OUTLINE, SOSI, TRANSP",
428 basis: Basis::Chosen,
429 oracle: Oracle::EnterpriseCobol,
430 },
431 Assumption {
432 id: BMS_CONSTANTS_UNVERIFIED,
433 claim: "DFHNULL is X'00', and DFHBMPEM, DFHBMPNL, DFHBMPFF and DFHBMPCR are X'19', X'15', X'0C' and X'0D'",
434 basis: Basis::Recalled,
435 oracle: Oracle::EnterpriseCobol,
436 },
437 Assumption {
438 id: BMS_SEND_DATA_CHOICE,
439 claim: "SEND MAP without MAPONLY or DATAONLY sends a field's symbolic data when its first byte is not X'00', else the map's INITIAL, and a non-null A byte replaces ATTRB",
440 basis: Basis::Recalled,
441 oracle: Oracle::EnterpriseCobol,
442 },
443 Assumption {
444 id: CICS_INITIAL_AID,
445 claim: "A task started by terminal input sees that input's AID in EIBAID before any RECEIVE",
446 basis: Basis::Recalled,
447 oracle: Oracle::EnterpriseCobol,
448 },
449 Assumption {
450 id: REWRITE_SHARED_ALTERNATE,
451 claim: "REWRITE gives 02 whenever another record shares one of the record's alternate keys that allow duplicates, whether or not that key changed",
452 basis: Basis::Chosen,
453 oracle: Oracle::EnterpriseCobol,
454 },
455 Assumption {
456 id: LE_SERVICE_AFTER_PROGRAMS,
457 claim: "A CALL that finds no program of its name in the run unit or its program libraries reaches the Language Environment callable service of that name, as a link-edit that finds the name in no user library resolves it from SCEELKED; a user program of the same name comes first",
458 basis: Basis::Chosen,
459 oracle: Oracle::EnterpriseCobol,
460 },
461 Assumption {
462 id: LE_ARGUMENTS_BY_ADDRESS,
463 claim: "A callable service reads and stores each parameter at its argument's address for the length SA38-0683-60 gives it (fullword, halfword-prefixed string, 8-byte COMP-2, 17- or 80-byte string, 12-byte feedback code), whatever the argument's own length; an OMITTED parameter other than fc is a protection exception (S0C4), and a store past the end of the run unit's storage is lost",
464 basis: Basis::Chosen,
465 oracle: Oracle::EnterpriseCobol,
466 },
467 Assumption {
468 id: LE_FEEDBACK_TOKEN,
469 claim: "A feedback code is 12 bytes: severity and message number as halfwords, a byte of case 1, severity and control 001 (X'59' at severity 3), the facility CEE in EBCDIC, then the instance-specific word; twelve zero bytes are CEE000, success (SA38-0683-60, _FEEDBACK in Table 20; so CEE2EB, severity 3 and message 2507, is X'000309CB59C3C5C5')",
470 basis: Basis::Documented,
471 oracle: Oracle::EnterpriseCobol,
472 },
473 Assumption {
474 id: LE_FEEDBACK_NO_INSTANCE_INFO,
475 claim: "The instance-specific word of every feedback code the provided services return is zero",
476 basis: Basis::Chosen,
477 oracle: Oracle::EnterpriseCobol,
478 },
479 Assumption {
480 id: LE_OMITTED_FC_ABENDS,
481 claim: "With fc OMITTED a failing service signals its condition (SA38-0683-60, Invoking callable services); nothing handles it, so one of severity 2 or more ends the run as the default ABTERMENC(ABEND) does, with user abend U4038, and one of severity 1 lets the run continue",
482 basis: Basis::Recalled,
483 oracle: Oracle::EnterpriseCobol,
484 },
485 Assumption {
486 id: LE_CEE3ABD,
487 claim: "CEE3ABD ends the run with user abend abcode modulo 4096, the ABEND macro's user completion code, to which SA38-0683-60 says abcode passes unchecked; every clean-up value ends it alike: open files are closed as at any ironwork abend, and neither a CEEDUMP nor a system dump is written",
488 basis: Basis::Chosen,
489 oracle: Oracle::EnterpriseCobol,
490 },
491 Assumption {
492 id: LE_LOCAL_TIME_IS_UTC,
493 claim: "Local time is UTC: CEELOCT and CEEGMT read the clock that ACCEPT FROM DATE and TIME and CURRENT-DATE read, and CEEGMTO reports a zero offset, as CURRENT-DATE reports +0000",
494 basis: Basis::Chosen,
495 oracle: Oracle::EnterpriseCobol,
496 },
497 Assumption {
498 id: LE_SECONDS_HFP,
499 claim: "Lilian seconds are the whole number of milliseconds converted to long HFP and divided by 1000, truncating as FLOAT_FROM_DECIMAL does, so a MOVE of CEESECS's result to a decimal item can show a millisecond less; seconds given to CEEDATM are taken to the nearest millisecond",
500 basis: Basis::Chosen,
501 oracle: Oracle::EnterpriseCobol,
502 },
503 Assumption {
504 id: LE_PICTURE_OUTPUT,
505 claim: "CEEDATE and CEEDATM write the terms of SA38-0683-60 Table 34 and copy anything else as it stands, with English month and day names; MM after an hour term is minutes (Table 28); CEEDATE writes time terms as zero and AP as AM (Table 27, where Table 35 says blank); the eras <JJJJ>, <CCCC> and YYY are not provided and give CEE2EM; a null or blank picture is the COUNTRY(US) default of Table 33",
506 basis: Basis::Chosen,
507 oracle: Oracle::EnterpriseCobol,
508 },
509 Assumption {
510 id: LE_PICTURE_INPUT,
511 claim: "CEEDAYS and CEESECS read a numeric term followed by a delimiter as up to its width of digits (6/2/88 for MM/DD/YY) and any other as exactly its width, leading blanks allowed; a delimiter takes one character, whatever it is; a month name is three or more of its letters; input that ends before the date is complete is CEE2EB, before the time is complete, zeros; a non-digit is CEE2EO (CEE2ET for CEESECS)",
512 basis: Basis::Chosen,
513 oracle: Oracle::EnterpriseCobol,
514 },
515 Assumption {
516 id: LE_CENTURY_WINDOW,
517 claim: "A two-digit year falls in the hundred years starting 80 years before the current year (SA38-0683-60, CEEDAYS and CEESECS); CEESCEN, which moves the window, is not provided",
518 basis: Basis::Documented,
519 oracle: Oracle::EnterpriseCobol,
520 },
521 Assumption {
522 id: LE_RETURN_CODE_UNCHANGED,
523 claim: "A CALL of a callable service leaves RETURN-CODE as it was; SA38-0683-60 leaves register 15 undefined on return",
524 basis: Basis::Chosen,
525 oracle: Oracle::EnterpriseCobol,
526 },
527 Assumption {
528 id: LE_MESSAGE_AND_DUMP_FILES,
529 claim: "CEEMOUT writes to DD SYSOUT, MSGFILE's default ddname, and CEE3DMP to DD CEEDUMP or the ddname FNAME gives, as UTF-8 text lines, the run's first write replacing the file, or to standard error without the DD; CEE3DMP writes its title, date and time, options and the active programs, not storage or control blocks",
530 basis: Basis::Chosen,
531 oracle: Oracle::EnterpriseCobol,
532 },
533 Assumption {
534 id: LE_HEAP,
535 claim: "CEEGTST gives zeroed run-unit storage on a doubleword from heap 0 only, refuses a request above 256 MiB with CEE0PD, and keeps the storage until the run ends; CEEFRST marks it free, and it is not reused",
536 basis: Basis::Chosen,
537 oracle: Oracle::EnterpriseCobol,
538 },
539 Assumption {
540 id: LE_UNDER_CICS,
541 claim: "In a CICS task, CEE3ABD ends the task as EXEC CICS ABEND CANCEL would, with abcode modulo 4096 as a four-digit decimal ABCODE, so HANDLE ABEND does not catch it; CEEMOUT and CEE3DMP write each line as one item on transient data queue CESE, as MSGFILE and any DD are ignored under CICS (SA38-0683-60), without the terminal, transaction and time prefix CICS may put on a CESE record",
542 basis: Basis::Chosen,
543 oracle: Oracle::EnterpriseCobol,
544 },
545 Assumption {
546 id: REPORT_WRITER_PRECOMPILER,
547 claim: "Enterprise COBOL takes the REPORT SECTION, the FD REPORT clause, INITIATE, GENERATE, TERMINATE, PAGE-COUNTER, LINE-COUNTER, PRINT-SWITCH and USE BEFORE REPORTING only through the COBOL Report Writer Precompiler, 5798-DYR (Migration Guide GC27-8715-04, pp. 69-70); a Report Writer program runs as the precompiler's generated COBOL runs, with the precompiler as supplied, option OSVS on (SC26-4301-04, 1.1.3)",
548 basis: Basis::Documented,
549 oracle: Oracle::EnterpriseCobol,
550 },
551 Assumption {
552 id: REPORT_TOTALS_BEFORE_PAGE_FIT,
553 claim: "Under OSVS a report group's totalling (cross-footing, subtotalling, rolling forward) comes before its USE BEFORE REPORTING procedure and its page-fit test, so a group that forces a new page is already in the totals the PAGE FOOTING shows (SC26-4301-04, 4.2.4)",
554 basis: Basis::Documented,
555 oracle: Oracle::EnterpriseCobol,
556 },
557 Assumption {
558 id: REPORT_SOURCE_SUM_CORRELATION,
559 claim: "Under OSVS a SUM of an item outside the REPORT SECTION that a DETAIL group has as a SOURCE is added only when such a DETAIL is generated, and once for each such DETAIL on GENERATE report-name; UPON names the DETAILs outright; any other such operand is added on every GENERATE (SC26-4301-04, 3.23.5 and 4.2.3)",
560 basis: Basis::Documented,
561 oracle: Oracle::EnterpriseCobol,
562 },
563 Assumption {
564 id: REPORT_PAGE_REGION_DEFAULTS,
565 claim: "With no FOOTING, LAST CONTROL FOOTING is LAST DETAIL when that is written, else the line before the PAGE FOOTING (for a relative PAGE FOOTING, the line that puts its last line on PAGE LIMIT), else PAGE LIMIT; the standard would take PAGE LIMIT. With no LAST DETAIL it is FOOTING; a PAGE LIMIT below either is raised to it (SC26-4301-04, 2.9.3 and message RW-031)",
566 basis: Basis::Documented,
567 oracle: Oracle::EnterpriseCobol,
568 },
569 Assumption {
570 id: REPORT_LINE_WRITES,
571 claim: "Each report line is one WRITE AFTER ADVANCING: the first line of a page AFTER ADVANCING PAGE when it is line 1, otherwise after a record of spaces, with no CODE, written AFTER ADVANCING PAGE; every other line after the distance from the last; a report with no PAGE LIMIT never skips to a new page. The manual shows this for its file handlers and says the direct output also writes line 1 at the top of the page (SC26-4301-04, 5.3.8 and 6.3)",
572 basis: Basis::Chosen,
573 oracle: Oracle::EnterpriseCobol,
574 },
575 Assumption {
576 id: REPORT_CARRIAGE_CONTROL,
577 claim: "A report file is written AFTER ADVANCING, so each report record carries an ASA control character (PRINT_CONTROL_CHARACTER): under ADV a byte before the record, under NOADV the record's first byte, which the precompiler leaves for it (SC26-4301-04, 2.2.3 rules 7 to 9, 2.7.2 rule 3). The CODE comes after the control character, as 5.3.2 says of the PRNT handler, which prints as no handler does, though 2.5.3 rule 2 puts it before",
578 basis: Basis::Chosen,
579 oracle: Oracle::EnterpriseCobol,
580 },
581 Assumption {
582 id: REPORT_RECORD_LENGTH,
583 claim: "A report file whose FD has no RECORD CONTAINS has records as long as the longest line of its reports, rounded up to a multiple of 4, plus the CODE and the control character (SC26-4301-04, 2.2.3 rule 7), the FD's record holding the control character only under NOADV (rule 8, 2.7.2 rule 3), so that under ADV a RECORD CONTAINS length is the line and CODE alone; under RECORDING MODE V each record ends after its last printed field (rule 9)",
584 basis: Basis::Documented,
585 oracle: Oracle::EnterpriseCobol,
586 },
587 Assumption {
588 id: REPORT_SUM_OVERFLOW,
589 claim: "A SUM total is a signed binary item with the integer and decimal places of its SUM entry, widened to those of a REPORT SECTION item it totals, and packed decimal beyond 18 digits (SC26-4301-04, 3.23.4); an addition that would overflow it is not made and run-time error 11 is logged, as 2.8.3 says for SUM OVERFLOW STANDARD, though 3.23.8 says the field then prints blank",
590 basis: Basis::Chosen,
591 oracle: Oracle::EnterpriseCobol,
592 },
593 Assumption {
594 id: REPORT_SOURCE_OVERFLOW,
595 claim: "A SOURCE arithmetic expression that overflows its field or divides by zero leaves the field blank and logs run-time error 10, OVERFLOW PROCEDURE IS STANDARD being the default (SC26-4301-04, 2.8.3)",
596 basis: Basis::Documented,
597 oracle: Oracle::EnterpriseCobol,
598 },
599 Assumption {
600 id: REPORT_SUPPRESS_PRINTING,
601 claim: "SUPPRESS PRINTING, or PRINT-SWITCH left non-zero by a USE BEFORE REPORTING procedure, stops the group's lines, page-fit test and NEXT GROUP, but its totals are still reset; 4.5.3 and 4.7.3 of SC26-4301-04 say so, while 4.2.4 step 9 says no further action is taken",
602 basis: Basis::Chosen,
603 oracle: Oracle::EnterpriseCobol,
604 },
605 Assumption {
606 id: REPORT_NEW_PAGES,
607 claim: "LINE ... NEXT PAGE skips to a new page only when a body group is already on the page; a REPORT FOOTING on a page of its own gets no PAGE HEADING or PAGE FOOTING; a page holding the REPORT HEADING alone gets no PAGE FOOTING (SC26-4301-04, 3.24.3)",
608 basis: Basis::Chosen,
609 oracle: Oracle::EnterpriseCobol,
610 },
611 Assumption {
612 id: REPORT_OUT_OF_ORDER,
613 claim: "GENERATE for a report not initiated logs run-time error 14 and initiates it (SC26-4301-04, message RW-142); INITIATE of an active report starts it afresh; TERMINATE of an inactive report does nothing",
614 basis: Basis::Chosen,
615 oracle: Oracle::EnterpriseCobol,
616 },
617 Assumption {
618 id: REPORT_CONTROL_AREA,
619 claim: "PAGE-COUNTER, LINE-COUNTER and PRINT-SWITCH are S9(9) COMP items (PAGE-COUNTER's PICTURE is in SC26-4301-04, 3.15.2); each report's control area, fields and totals are WORKING-STORAGE after the program's own items, so CANCEL and IS INITIAL start the report afresh",
620 basis: Basis::Chosen,
621 oracle: Oracle::EnterpriseCobol,
622 },
623 Assumption {
624 id: OBJECT_REFERENCE_VALUE,
625 claim: "An object reference is four bytes, as under LP(32): zero for NULL, otherwise the number of the local or global reference it holds, never reused in the run unit; each NEW, RETURNING value, argument received, SELF and reference a JNI service makes is a new number, so two references to one object can differ byte for byte, and = compares the objects they identify (Language Reference SC27-8713-03, p. 282)",
626 basis: Basis::Chosen,
627 oracle: Oracle::EnterpriseCobol,
628 },
629 Assumption {
630 id: LOCAL_REFERENCES_EXPIRE,
631 claim: "The object references a method receives as arguments, gets back as INVOKE RETURNING values or from JNI services, and makes with INVOKE ... NEW are local references, valid until the method returns, whatever kind the invoked method returned; NewGlobalRef makes a global reference, valid until DeleteGlobalRef, and DeleteLocalRef frees a local reference at once (Programming Guide SC27-8714-03, pp. 702-703 and 721-723; Language Reference SC27-8713-03, p. 365). SET copies a reference and converts nothing (Language Reference p. 451), so the Guide's 'use a SET statement to convert' (p. 722) is read as the CALL of NewGlobalRef it shows on p. 702, and a local reference kept in OBJECT, FACTORY or method WORKING-STORAGE expires, which p. 722 calls an error",
632 basis: Basis::Documented,
633 oracle: Oracle::EnterpriseCobol,
634 },
635 Assumption {
636 id: OBJECTS_NEVER_FREED,
637 claim: "Objects are never freed, and a run unit that creates more than 1,000,000 of them abends, where Java's garbage collector reclaims objects no longer referred to",
638 basis: Basis::Chosen,
639 oracle: Oracle::EnterpriseCobol,
640 },
641 Assumption {
642 id: INSTANCE_DATA_START,
643 claim: "INVOKE class NEW gives each COBOL class in the new object's hierarchy its own copy of its OBJECT WORKING-STORAGE, set to X'00' and then to its VALUE clauses; IBM documents only the VALUE clauses",
644 basis: Basis::Chosen,
645 oracle: Oracle::EnterpriseCobol,
646 },
647 Assumption {
648 id: FACTORY_DATA_START,
649 claim: "A class's FACTORY WORKING-STORAGE is set to X'00' and then to its VALUE clauses when the run unit first uses the class, and its one copy serves every INVOKE of the class's factory methods, through a subclass too",
650 basis: Basis::Chosen,
651 oracle: Oracle::EnterpriseCobol,
652 },
653 Assumption {
654 id: METHOD_LOOKUP,
655 claim: "INVOKE selects the method by its name, case kept, and the Java types of its arguments and RETURNING item (void without one), a universal object reference counting as java.lang.Object; the search starts at the class of the object itself, not the class its reference is typed with, and goes up the INHERITS chain; SUPER starts at the parent of the class that defines the running method",
656 basis: Basis::Chosen,
657 oracle: Oracle::EnterpriseCobol,
658 },
659 Assumption {
660 id: METHOD_NAME_ITEM,
661 claim: "A method name held in a data item is the item's content without its trailing spaces",
662 basis: Basis::Chosen,
663 oracle: Oracle::EnterpriseCobol,
664 },
665 Assumption {
666 id: INVOKE_NULL,
667 claim: "INVOKE on a NULL object reference, or on four bytes that name no object, ends the run with an abend; IBM leaves the result undefined",
668 basis: Basis::Chosen,
669 oracle: Oracle::EnterpriseCobol,
670 },
671 Assumption {
672 id: NO_METHOD_ABEND,
673 claim: "An INVOKE without ON EXCEPTION that finds no method raises IBM's severity-3 Language Environment condition, which ends the run with abend U4038",
674 basis: Basis::Chosen,
675 oracle: Oracle::EnterpriseCobol,
676 },
677 Assumption {
678 id: FACTORY_SELF,
679 claim: "SELF in a factory method is the factory object of the class that defines the method, and INVOKE on a reference to a factory object runs factory methods",
680 basis: Basis::Chosen,
681 oracle: Oracle::EnterpriseCobol,
682 },
683 Assumption {
684 id: CLASS_SEARCH,
685 claim: "A class is a COBOL class when a class definition with its external name is among the programs read or in the program libraries, as a member named with its simple name or its full name with periods as underscores, as IBM names the class's DLL; any other class is a Java class",
686 basis: Basis::Chosen,
687 oracle: Oracle::EnterpriseCobol,
688 },
689 Assumption {
690 id: INVOKE_KEEPS_RETURN_CODE,
691 claim: "INVOKE leaves the invoking program's RETURN-CODE as it was (Language Reference, INVOKE statement, RETURNING phrase)",
692 basis: Basis::Documented,
693 oracle: Oracle::EnterpriseCobol,
694 },
695 Assumption {
696 id: OO_OPTIONS_REQUIRED,
697 claim: "A class definition, and a program with INVOKE or an object reference, is compiled with THREAD, DLL, RENT and DBCS (Programming Guide SC27-8714-03, pp. 291, 295, 363, 588, 591, 694; Language Reference SC27-8713-03, p. 89), and NORENT with THREAD or DLL is a conflict IBM resolves as RENT (Guide pp. 344-345). Under THREAD a program is RECURSIVE ('an error will occur', Guide p. 591; Language Reference p. 103), and INITIAL, nested programs, SORT of a file and MERGE are diagnosed as errors (Guide p. 418; Language Reference pp. 85, 103, 400, 452); a table SORT is allowed (p. 453), and a method is recursive without it (p. 94). The options are the CBL and PROCESS cards' over IBM's defaults NOTHREAD, NODLL, RENT and DBCS",
698 basis: Basis::Documented,
699 oracle: Oracle::EnterpriseCobol,
700 },
701 Assumption {
702 id: CHAR_FROM_DISPLAY,
703 claim: "A one-byte reference modification of a display item passed to INVOKE becomes a Java char through the program's code page",
704 basis: Basis::Chosen,
705 oracle: Oracle::EnterpriseCobol,
706 },
707 Assumption {
708 id: SORT_EQUAL_KEYS_IN_ORDER,
709 claim: "Records with equal keys leave a SORT in the order they entered it whether or not WITH DUPLICATES IN ORDER is written, as under DFSORT's EQUALS; a table SORT keeps equal elements in their order too",
710 basis: Basis::Chosen,
711 oracle: Oracle::EnterpriseCobol,
712 },
713 Assumption {
714 id: MERGE_EQUAL_KEYS_BY_FILE,
715 claim: "Records with equal keys leave a MERGE in the order of the USING files, and each file's in its own order",
716 basis: Basis::Chosen,
717 oracle: Oracle::EnterpriseCobol,
718 },
719 Assumption {
720 id: MERGE_OUT_OF_SEQUENCE_FAILS,
721 claim: "A MERGE input file whose records are out of the merge order makes the MERGE fail with SORT-RETURN 16 before any record is output, as DFSORT's ICE068A ends a merge",
722 basis: Basis::Recalled,
723 oracle: Oracle::EnterpriseCobol,
724 },
725 Assumption {
726 id: SORT_FILE_FAILURE,
727 claim: "An I/O failure on a USING or GIVING file with a FILE STATUS sets the status and makes the SORT or MERGE fail with SORT-RETURN 16, leaving the rest undone; without a FILE STATUS it ends the run as the same failure on OPEN, READ, WRITE or CLOSE does",
728 basis: Basis::Chosen,
729 oracle: Oracle::EnterpriseCobol,
730 },
731 Assumption {
732 id: SORT_DECIMAL_KEYS,
733 claim: "A file SORT or MERGE compares a zoned or packed key as DFSORT compares ZD, PD, CLO, CSL and CST fields (z/OS DFSORT Application Programming Guide SC23-6878-50, Appendix C, pp. 825-828): sign nibbles F, E, C, A, 8, 6, 4, 2 and 0 are positive and D, B, 9, 7, 5, 3 and 1 negative, a separate sign is negative only when it is '-', the zones of the other digits are ignored, and no key is a data exception; a binary key compares at its full width (BI, FI) and a floating-point one by value (FL). -strict-sort-keys reads the key as the program would, so an invalid one is S0C7; a table SORT always compares as a relation condition does",
734 basis: Basis::Documented,
735 oracle: Oracle::EnterpriseCobol,
736 },
737 Assumption {
738 id: SORT_RECORD_LENGTHS,
739 claim: "A record shorter than a fixed-length SD or GIVING record is padded with spaces and a longer one cut to that length; a variable-length record that ends inside a key makes the SORT or MERGE fail with SORT-RETURN 16, as DFSORT does without VLSHRT",
740 basis: Basis::Chosen,
741 oracle: Oracle::EnterpriseCobol,
742 },
743 Assumption {
744 id: SORT_RETURN_STOPS,
745 claim: "SORT-RETURN is 0 when a SORT or MERGE starts; 16 moved to it in an input or output procedure stops the operation at the next RELEASE or RETURN, which does nothing, or when the input procedure ends",
746 basis: Basis::Chosen,
747 oracle: Oracle::EnterpriseCobol,
748 },
749 Assumption {
750 id: RETURN_AFTER_END,
751 claim: "A RETURN after the AT END condition takes the AT END phrase again",
752 basis: Basis::Chosen,
753 oracle: Oracle::EnterpriseCobol,
754 },
755 Assumption {
756 id: SORT_KEY_INVALID_DIGITS,
757 claim: "A digit nibble A to F in a zoned or packed sort key collates above 9 in its place; DFSORT does not say where such a key collates",
758 basis: Basis::Chosen,
759 oracle: Oracle::EnterpriseCobol,
760 },
761 Assumption {
762 id: SORT_NEGATIVE_ZERO,
763 claim: "A zoned or packed sort key of -0 collates before +0 in ascending order, as under DFSORT's SZERO=YES (Installation and Customization SC23-6881-70, p. 99), the IBM-supplied default",
764 basis: Basis::Recalled,
765 oracle: Oracle::EnterpriseCobol,
766 },
767 Assumption {
768 id: FASTSRT_FILES,
769 claim: "Under FASTSRT DFSORT does the I/O of a SORT's only USING file and its only GIVING file, except a MERGE's, a line-sequential or variable-length relative file, a GIVING file whose FD has LINAGE (p. 233), a print file under ADV unless --fastsrt-adv-print=include, one whose records differ from the SD's in format (fixed or variable) or largest length, and a GIVING file that is also the USING file; COBOL does the rest as under NOFASTSRT (Programming Guide SC27-8714-03, pp. 232-233, 369). The Guide does not name a print file under ADV. By default, --fastsrt-adv-print=exclude, it is left to COBOL, because ADV adds a byte to its record length for the printer control character (p. 346), which the DD's LRECL counts (p. 185): p. 233 wants the SD's and the FD's largest records the same length and p. 232 the DD to match the FD, so with the FD's record as long as the SD's the data set's records are a byte longer than DFSORT's, and with it a byte shorter the FD's and the SD's differ. --fastsrt-adv-print=include reads p. 233 as the FD's length alone and gives the file to DFSORT, as FASTSRT_ADV_PRINT says. Under NOADV the character is inside the FD's record and the lengths rule alone applies",
770 basis: Basis::Documented,
771 oracle: Oracle::EnterpriseCobol,
772 },
773 Assumption {
774 id: FASTSRT_STATUS,
775 claim: "A file whose I/O DFSORT does keeps the FILE STATUS it had through the SORT, and a GIVING relative file's RELATIVE KEY is not set (Programming Guide SC27-8714-03, pp. 232-233)",
776 basis: Basis::Documented,
777 oracle: Oracle::EnterpriseCobol,
778 },
779 Assumption {
780 id: FASTSRT_FAILURE,
781 claim: "A failure on a file whose I/O DFSORT does, including an empty VSAM input file, fails the SORT with SORT-RETURN 16 and the run goes on, with or without a FILE STATUS",
782 basis: Basis::Chosen,
783 oracle: Oracle::EnterpriseCobol,
784 },
785 Assumption {
786 id: SAME_AREA_VSAM,
787 claim: "SAME AREA makes the VSAM (indexed and relative) files it names share one record area, as SAME RECORD AREA does, and is documentation for the others (Language Reference SC27-8713-03, p. 156)",
788 basis: Basis::Documented,
789 oracle: Oracle::EnterpriseCobol,
790 },
791 Assumption {
792 id: LONG_ZONED_BY_PACKS,
793 claim: "A zoned item of more than 16 digits, too long for one PACK (SA22-7832-14: each operand at most 16 bytes), enters arithmetic through two or three PACKs, the high-order part first and each lower PACK overwriting the byte the part above it ended in, so it packs as ZONED_BY_PACK says one PACK would: every zone but the sign's discarded and no digit checked until the arithmetic uses it. An alphanumeric sender longer than 31 characters moved to a numeric item is packed from its rightmost 31, the most any receiver holds",
794 basis: Basis::Chosen,
795 oracle: Oracle::EnterpriseCobol,
796 },
797 Assumption {
798 id: ASCII_COLLATION,
799 claim: "STANDARD-1 and STANDARD-2 put the characters of 7-bit ASCII in its order (Language Reference SC27-8713-03, Table 82, p. 754; Programming Guide SC27-8714-03, p. 7), each found in the program's code page; the characters that are not 7-bit ASCII follow them in EBCDIC order, as the characters an ALPHABET literal leaves out do",
800 basis: Basis::Chosen,
801 oracle: Oracle::EnterpriseCobol,
802 },
803 Assumption {
804 id: TABLE_SORT_COLLATION,
805 claim: "A table SORT without a COLLATING SEQUENCE phrase orders alphanumeric keys in EBCDIC, as the SORT statement's format 2 rules say (SC27-8713-03, p. 450), though its rules for the phrase in both formats put the PROGRAM COLLATING SEQUENCE in the phrase's place (p. 451)",
806 basis: Basis::Chosen,
807 oracle: Oracle::EnterpriseCobol,
808 },
809 Assumption {
810 id: ALPHABET_LITERALS,
811 claim: "Among an ALPHABET clause's literals HIGH-VALUE, LOW-VALUE, SPACE, ZERO and QUOTE are the EBCDIC characters X'FF', X'00', X'40', X'F0' and X'7F', whatever the alphabet makes HIGH-VALUE and LOW-VALUE, and a numeric literal n is the character at ordinal n of EBCDIC, whose ordinals SC27-8713-03 points to (p. 128)",
812 basis: Basis::Chosen,
813 oracle: Oracle::EnterpriseCobol,
814 },
815 Assumption {
816 id: LE_CEEIGZCT,
817 claim: "A COPY CEEIGZCT that no library answers gives a level-88 condition name for each of the 723 conditions whose entry in the Language Environment Runtime Messages (SA38-0686-60, chapter 1) shows a symbolic feedback code, severity from its message's I, W, E, S or C; the name is CEE and the message number in base 32 (Programming Guide SA38-0682-60, CEEBLDTX :msgname.), the value the token's first 8 bytes as LE_FEEDBACK_TOKEN lays them out (Programming Reference SA38-0683-60, CEENCOD), and CEE000 is all zeros (SA38-0682-60, testing a condition token for success); it is meant to follow the 8-byte group the token starts with (SA38-0682-60, Figure 76). It is written from those manuals alone, not from IBM's CEEIGZCT",
818 basis: Basis::Documented,
819 oracle: Oracle::EnterpriseCobol,
820 },
821 Assumption {
822 id: LE_CEEIGZCT_DISAGREEMENTS,
823 claim: "Where the manuals disagree CEEIGZCT follows the message: its severity letter over a service's table in SA38-0683-60 (CEE07V, CEE317, CEE35S, CEE36V to CEE374), and its number over the code SA38-0686-60 prints beside it (CEE0356C shows CEE0BA, CEE5722I CEE5IP, CEE5771S CEE5KC); the eight messages printed with no code (CEE3252E, CEE3257E to CEE3259E, CEE3596S, CEE3796I to CEE3798I) have no name",
824 basis: Basis::Chosen,
825 oracle: Oracle::EnterpriseCobol,
826 },
827 Assumption {
828 id: LE_SHORT_ARGUMENT_LIST,
829 claim: "A CALL of a service with fewer arguments than its syntax lists, CEE3ABD with no USING among them, ends the run with ironwork's own abend, not a modelled one: IBM calls a short list invalid with unpredictable results (SA38-0683-60, General usage notes for callable services) and says nothing of register 1 at a CALL without USING, whose own CALL and CEEPCALL macros leave it unaltered when no parameter is coded (MVS Assembler Services Reference SA22-7606-13, CALL; SA38-0682-60, CEEPCALL); the service then reads its arguments through whatever register 1 and the storage past the list hold, so neither S0C4 nor any other result follows. A missing fc is not taken as OMITTED, nor a missing clean-up as none",
830 basis: Basis::Chosen,
831 oracle: Oracle::EnterpriseCobol,
832 },
833 Assumption {
834 id: LE_SSRANGE_U4038,
835 claim: "A reference SSRANGE finds out of range signals a severity-3 LE condition; nothing handles it, so the run ends with user abend U4038 under the default ABTERMENC(ABEND). The message ids, from memory of the Enterprise COBOL messages: IGZ0006S for a subscript or index outside its table, IGZ0072S for a reference-modification start outside its item, IGZ0073S for a length below 1, and IGZ0074S for a start and length that reach past the item's end. An OCCURS DEPENDING ON object outside its range gives IGZ0007S, IBM's message for a variable-length group longer than its maximum or shorter than zero (IBM Support, 'Executing a CICS generated application results in abend'); IBM checks the group's composite length, and ironwork checks each object's count",
836 basis: Basis::Recalled,
837 oracle: Oracle::EnterpriseCobol,
838 },
839 Assumption {
840 id: PRINT_CONTROL_CHARACTER,
841 claim: "A sequential file that a WRITE with ADVANCING in the program names, or whose FD has LINAGE, is a print file: every record written to it carries a printer control character, a WRITE without ADVANCING being AFTER ADVANCING 1 LINE; ASA characters when every WRITE ... ADVANCING of the file says AFTER, machine codes when any says BEFORE (Language Reference SC27-8713-03, p. 479). Under ADV, the default, the character is a byte before the record; under NOADV it is the record's own first byte; a LINAGE file is ADV whatever the option (p. 480; Programming Guide SC27-8714-03, pp. 178-179, 346). ASA ' ', '0' and '-' space 1 to 3 lines before printing, '+' none, '1' to '9' and 'A' to 'C' skip to channels 1 to 12, PAGE and C01 being channel 1, except that PAGE moves a LINAGE file's paper in lines (LINAGE_PAGE_MOVEMENT), and CSP '+'; machine codes print then space, X'01', X'09', X'11', X'19', or skip, X'89' + 8(n-1) for channel n; AFP-5A is X'5A' (z/OS DFSMS Macro Instructions for Data Sets SC23-6852-60, pp. 397-398; Language Reference pp. 126-127, 483). SPECIAL-NAMES of a program apply to the programs it contains (p. 13)",
842 basis: Basis::Documented,
843 oracle: Oracle::EnterpriseCobol,
844 },
845 Assumption {
846 id: PRINT_SPACING_RECORDS,
847 claim: "A movement one control character cannot give is made with records that only move the paper, each as long as the line's record and blank after its control character: in an ASA file AFTER ADVANCING n lines above 3 is preceded by (n-1)/3 records with '-', the line taking the rest; in a machine-code file BEFORE ADVANCING n above 3 prints with X'19' and is followed by records spacing the rest without printing, three lines at a time (X'1B', then X'0B' or X'13'), and AFTER ADVANCING is such records, or X'8B' + 8(n-1) for channel n, then the line with X'01'",
848 basis: Basis::Chosen,
849 oracle: Oracle::EnterpriseCobol,
850 },
851 Assumption {
852 id: PRINT_CONTROL_RUN_TIME,
853 claim: "Under NOADV the control character is stored in the first byte of the record area, where the program sees it after the WRITE; an ADVANCING count below zero spaces no lines; under ADV a READ of a print file in the program that writes it skips the added byte",
854 basis: Basis::Chosen,
855 oracle: Oracle::EnterpriseCobol,
856 },
857 Assumption {
858 id: TEXT_PRINT_LINES,
859 claim: "A text DD shows a print file's records without the control character, which it reads as line spacing, as the POSIX asa utility does: ' ', '0' and '-' put the line one, two or three lines below the last, the DD's first line starting on its first; '+' and X'01' overprint, after a carriage return when both lines show something; a skip to channel 1 is a form feed before the line; a skip to channels 2 to 12, or AFP-5A page mode data, is one line, a text DD having no forms control buffer; a machine code moves the paper after its line. Any other file's records are a line each",
860 basis: Basis::Chosen,
861 oracle: Oracle::EnterpriseCobol,
862 },
863 Assumption {
864 id: LOCAL_REFERENCES_OUTSIDE_METHODS,
865 claim: "A local reference made by a program that is not a method belongs to the method running when it runs, freed when that method returns; with no method running it belongs to the run unit and stays valid until the run ends, as the JNI keeps a thread's local references outside any native method, and the Guide asks for NewGlobalRef only 'if the client code is within a method' (Programming Guide SC27-8714-03, p. 703)",
866 basis: Basis::Chosen,
867 oracle: Oracle::EnterpriseCobol,
868 },
869 Assumption {
870 id: SELF_IS_LOCAL,
871 claim: "SELF is a local reference of the method's own frame, made with the invocation, as the JNI passes a native method its object, and it expires when the method returns; the Guide's list of local references names arguments, RETURNING values, JNI results and NEW only (Programming Guide SC27-8714-03, p. 721)",
872 basis: Basis::Recalled,
873 oracle: Oracle::EnterpriseCobol,
874 },
875 Assumption {
876 id: EXPIRED_REFERENCE_ABENDS,
877 claim: "Using a reference after it was freed ends the run with abend IRONWORK naming the item that holds it, how the reference was made and where it was freed: INVOKE on it, passing it to INVOKE or a JNI service, a method's RETURNING it, and comparing it with another object reference or SELF use it; SET, MOVE and CALL between programs copy its bytes without looking, and a comparison with NULL tests only its bytes. On z/OS a freed reference's slot is reused, and the Guide says only that 'an error occurs' (Programming Guide SC27-8714-03, p. 722)",
878 basis: Basis::Chosen,
879 oracle: Oracle::EnterpriseCobol,
880 },
881 Assumption {
882 id: LOCAL_FRAMES,
883 claim: "The JNI reference services run as the JNI specification defines them: NewLocalRef and NewGlobalRef make a new reference to the object, NULL for NULL; DeleteLocalRef and DeleteGlobalRef free one and ignore NULL, and one given the other kind of reference ends the run; IsSameObject compares objects; GetObjectRefType answers 0 for NULL, 1 for local and 2 for global; PushLocalFrame opens a frame whose local references PopLocalFrame frees, giving back a local reference in the frame below to its argument's object, and EnsureLocalCapacity succeeds. PopLocalFrame with no frame of PushLocalFrame's open ends the run, and a method's return frees the frames it left open. The Guide documents NewGlobalRef, DeleteGlobalRef and DeleteLocalRef only (Programming Guide SC27-8714-03, pp. 722-723)",
884 basis: Basis::Recalled,
885 oracle: Oracle::EnterpriseCobol,
886 },
887 Assumption {
888 id: OO_OPTIONS_SEVERITY,
889 claim: "IBM names no message for object-oriented syntax compiled without THREAD, DLL, RENT or DBCS, nor for THREAD without RECURSIVE, which it calls an error (Messages and Codes SC27-4648-02, p. v, lists only some messages), so the severity of each rule of J13 is chosen. A missing option is a warning (W, return code 4), and the program runs as if compiled with it. NORENT with THREAD or DLL is a warning too: IBM forces RENT and 'generates an error message' (Programming Guide SC27-8714-03, p. 344), and the message it gives for an option dropped in conflict resolution is W, IGYOS4020-W, return code 4, in Enterprise COBOL job output quoted in the corpus (Delvoie_Mainframe, A5 instructions). THREAD without RECURSIVE, and INITIAL, a nested program, SORT of a file or MERGE under THREAD, are errors (S), as IBM diagnoses them as errors (J13). A program that reaches Java through JNIENVPTR alone, with no INVOKE or object reference, is held to none of them, as IBM builds its Bank-of-Z IBTRAN with DLL and without THREAD",
890 basis: Basis::Chosen,
891 oracle: Oracle::EnterpriseCobol,
892 },
893 Assumption {
894 id: REFERENCES_KEPT,
895 claim: "Every reference made is kept for the rest of the run, so that an expired one can say where it expired, and a run unit that makes more than 8,388,608 of them abends; the JVM reuses a freed reference's slot",
896 basis: Basis::Chosen,
897 oracle: Oracle::EnterpriseCobol,
898 },
899 Assumption {
900 id: SQL_COMMIT_AT_NORMAL_END,
901 claim: "A batch run unit commits at a normal end and rolls back at an abend: \"In all Db2 environments, the normal termination of a process is an implicit commit operation\" (Db2 12 for z/OS SQL Reference, COMMIT). Db2 for Linux rolls back instead",
902 basis: Basis::Documented,
903 oracle: Oracle::Db2,
904 },
905 Assumption {
906 id: SQL_WHENEVER_ORDER,
907 claim: "WHENEVER tests SQLERROR (SQLCODE < 0), NOT FOUND (100) and SQLWARNING (SQLWARN0 W, or > 0 and not 100); the precompiler tests warning before not-found, and the three exclude one another (Db2 12.1.5 for Linux, tools/db2-probe)",
908 basis: Basis::Observed,
909 oracle: Oracle::Db2,
910 },
911 Assumption {
912 id: SQL_TRUNCATED_INDICATOR,
913 claim: "A string cut to fit its host variable sets the indicator to its original length, SQLWARN0 and SQLWARN1, and SQLSTATE 01004; trailing blanks cut from a CHAR count (Db2 12.1.5 for Linux, tools/db2-probe)",
914 basis: Basis::Observed,
915 oracle: Oracle::Db2,
916 },
917 Assumption {
918 id: SQL_POSTGRES_ERRORS,
919 claim: "PostgreSQL's SQLSTATEs map to Db2 SQLCODEs as sql-runtime.md §9 tabulates; Db2 for Linux agrees except -433 for -404 and -801 for -802, where the table keeps z/OS's documented codes (Db2 12.1.5 for Linux, tools/db2-probe)",
920 basis: Basis::Observed,
921 oracle: Oracle::Db2,
922 },
923 Assumption {
924 id: SQL_DIALECT_REWRITES,
925 claim: "Db2 SQL is rewritten for PostgreSQL by the table in sql-runtime.md §9, and any other text runs unchanged",
926 basis: Basis::Chosen,
927 oracle: Oracle::Db2,
928 },
929 Assumption {
930 id: SQL_INTO_WITHOUT_COLONS,
931 claim: "A name in an INTO list written without its colon is a host variable, as older precompilers read it",
932 basis: Basis::Recalled,
933 oracle: Oracle::Db2,
934 },
935 Assumption {
936 id: SQL_DECLARATIONS_CROSS_NESTED_PROGRAMS,
937 claim: "WHENEVER and cursor declarations carry on in listing order across nested programs, as the precompiler reads the source in order",
938 basis: Basis::Chosen,
939 oracle: Oracle::Db2,
940 },
941 Assumption {
942 id: SQL_DOUBLE_TO_HFP_TRUNCATES,
943 claim: "An IEEE double stored into COMP-1 or COMP-2 drops the low-order bits that do not fit, rather than rounding",
944 basis: Basis::Chosen,
945 oracle: Oracle::Db2,
946 },
947 Assumption {
948 id: SQL_ZONED_IS_DECIMAL,
949 claim: "A zoned DISPLAY host variable without SIGN SEPARATE is DECIMAL to Db2, as SIGN LEADING SEPARATE is",
950 basis: Basis::Chosen,
951 oracle: Oracle::Db2,
952 },
953 Assumption {
954 id: SQL_ISO_DATETIME,
955 claim: "Dates and times reach character host variables as YYYY-MM-DD, HH.MM.SS and YYYY-MM-DD-HH.MM.SS.NNNNNN, DSNHDECP's DATE(ISO) and TIME(ISO); the forms are as seen under DATETIME(ISO), and the default is an installation's (Db2 12.1.5 for Linux, tools/db2-probe)",
956 basis: Basis::Observed,
957 oracle: Oracle::Db2,
958 },
959 Assumption {
960 id: SQL_TRAILING_BLANKS_SENT,
961 claim: "Character inputs are sent with their trailing blanks, since Db2 compares strings as if blank-padded (Db2 12.1.5 for Linux, tools/db2-probe)",
962 basis: Basis::Observed,
963 oracle: Oracle::Db2,
964 },
965 Assumption {
966 id: SQL_FETCH_ROW_COUNT,
967 claim: "A single-row FETCH that returns a row sets SQLERRD(3) to 1; Db2 for z/OS documents SQLERRD(3) for a rowset FETCH only (Db2 12.1.5 for Linux, tools/db2-probe)",
968 basis: Basis::Observed,
969 oracle: Oracle::Db2,
970 },
971 Assumption {
972 id: FASTSRT_PRINT_RECORDS,
973 claim: "Under FASTSRT DFSORT, not COBOL, does the I/O of the USING and GIVING files (Programming Guide SC27-8714-03, p. 232), and DFSORT adds a printer control character only to the lines of an OUTFIL report (DFSORT Application Programming Guide SC23-6878-50, p. 225), which needs control statements ironwork does not read. So DFSORT writes a GIVING print file's records as the SD holds them, with no control character, where COBOL writes each as a WRITE without phrases (Language Reference SC27-8713-03, p. 453), which for a print file is AFTER ADVANCING 1 LINE (Programming Guide pp. 178-179), the character over the record's first byte under NOADV; and DFSORT reads a USING print file's records as its data set holds them, where COBOL's READ skips the byte ADV adds (PRINT_CONTROL_RUN_TIME). Under NOADV the two read a USING print file alike",
974 basis: Basis::Documented,
975 oracle: Oracle::EnterpriseCobol,
976 },
977 Assumption {
978 id: FASTSRT_RECORD_LENGTHS,
979 claim: "DFSORT takes the length of the records it sorts from the SORTIN data set, not from the RECORD statement (DFSORT Application Programming Guide SC23-6878-50, p. 420). A fixed-length record shorter than SORTOUT's LRECL is padded on the right with X'00', and a longer one cut on the right, with message ICE171I and return code 0 (pp. 14-15, 200, 209) under PAD=RC0 and TRUNC=RC0, the IBM-supplied defaults (DFSORT Installation and Customization SC23-6881-70, pp. 91, 102); padding needs the Blockset technique and a sort or copy, DFSORT checks neither padding nor truncation without both a SORTIN and a SORTOUT data set (pp. 200, 209), and it neither pads nor cuts the records an E15 or E35 exit returns (p. 15). A variable-length record longer than SORTOUT's LRECL ends DFSORT with ICE217A under NOVLLONG (p. 210), the IBM-supplied default (Installation and Customization p. 103; DFSORT Messages, Codes and Diagnosis SC23-6879-50, p. 76)",
980 basis: Basis::Documented,
981 oracle: Oracle::EnterpriseCobol,
982 },
983 Assumption {
984 id: FASTSRT_ADV_PRINT,
985 claim: "With --fastsrt-adv-print=include a print file under ADV is FASTSRT's as any other file is, and DFSORT meets its data set's records, a byte longer than the FD's. A USING file's data set stands as DFSORT's SORTIN and a GIVING file's as its SORTOUT, as the Programming Guide implies by keeping DFSORT's SORTIN and SORTOUT options from a FASTSRT program (SC27-8714-03, p. 232) without saying so, and COBOL gives DFSORT each key's place in the SD's record; so, by FASTSRT_PRINT_RECORDS and FASTSRT_RECORD_LENGTHS, a USING print file's records keep the control character as their first byte, each key being read a byte before where the FD has it, and a GIVING file's fixed-length records are padded with X'00' or cut to its data set's length. With no USING data set of DFSORT's own, as with an INPUT PROCEDURE or a USING file COBOL reads, a GIVING print file's longer fixed-length records fail the SORT before its input phase, as ICE043A reason 9 says of fixed-length output records longer than the input's (DFSORT Messages, Codes and Diagnosis SC23-6879-50, pp. 29-30). COBOL takes a record from DFSORT, for an OUTPUT PROCEDURE or a GIVING file it writes, at the SD's length at most, and a VSAM GIVING file takes it at its own. A text DD holds no control character, so on it a print file's records are the FD's length, and each record DFSORT writes is a line",
986 basis: Basis::Chosen,
987 oracle: Oracle::EnterpriseCobol,
988 },
989 Assumption {
990 id: COMPILER_SEVERITIES,
991 claim: "A compiler message has one of five severities, each with a return code: I (informational) 0, the program runs correctly; W (warning) 4, a possible error; E (error) 8, an error the compiler attempted to correct; S (severe) 12, one it could not, and the program should not be run; U (unrecoverable) 16, the compilation ended. A compilation's return code is generally the highest of its messages' (Programming Guide SC27-8714-03, Table 38, p. 282), and the letter ends each message's identifier, as in IGYPS2121-S (p. 281). ironwork check exits with that return code, 0 when there is no message",
992 basis: Basis::Documented,
993 oracle: Oracle::EnterpriseCobol,
994 },
995 Assumption {
996 id: REFUSALS_ARE_SEVERE,
997 claim: "Every refusal ironwork made before its messages had severities is S, return code 12, and none is E: IBM's E is an error the compiler corrects, still producing object code under the default NOCOMPILE(S) (Programming Guide SC27-8714-03, pp. 282, 355), and ironwork corrects nothing, so a program it refuses has no code to run. Where IBM documents a lower severity ironwork now follows it: NUMPROC(MIG) is W with the default NUMPROC, an invalid suboption is E with the option discarded, and a non-COBOL character is IGYLI0163-E (C120 onward). U is not used: ironwork's reader stops at the first syntax error, which IBM reports and reads past",
998 basis: Basis::Chosen,
999 oracle: Oracle::EnterpriseCobol,
1000 },
1001 Assumption {
1002 id: REFUSED_FROM_S,
1003 claim: "ironwork run and cics run a program whose compile's return code is 0, 4 or 8, printing its messages first, and refuse one at 12 or more, exiting with that return code, as IBM's IGYWCLG procedure runs one: its GO step is bypassed only when 8 is less than the compile step's return code, COND=((8,LT,COBOL),(4,LT,LKED)) (Programming Guide SC27-8714-03, pp. 259-260), and the default NOCOMPILE(S) produces object code after E-level messages, stopping it at the first S-level one (p. 355). A card's COMPILE or NOCOMPILE, or -warnings-block, moves the refusal (NOCOMPILE). No message of ironwork's is E yet (REFUSALS_ARE_SEVERE)",
1004 basis: Basis::Documented,
1005 oracle: Oracle::EnterpriseCobol,
1006 },
1007 Assumption {
1008 id: NOCOMPILE,
1009 claim: "COMPILE, abbreviated C, produces object code whatever the messages; NOCOMPILE(W), NOCOMPILE(E) or NOCOMPILE(S), abbreviated NOC, stops it at the first message of that severity or higher, NOCOMPILE(S) being the default; and NOCOMPILE alone is a syntax check with no object code (Programming Guide SC27-8714-03, p. 355). ironwork reads them from a CBL or PROCESS card, the last one given winning (p. 344): run and cics refuse a program with a message at or above the level, under NOCOMPILE whatever its messages, and under COMPILE from S as under NOCOMPILE(S): COMPILE's object code after an S-level message runs with results IBM calls unpredictable (p. 355), and IGYWCLG's COND bypasses its GO step above 8 whatever the object code (REFUSED_FROM_S). A program ironwork cannot parse or lay out is refused under any of them. -warnings-block is ironwork's command-line NOCOMPILE(W), and a card's COMPILE or NOCOMPILE wins over it, as options on a PROCESS or CBL statement take precedence over the compiler invocation's (p. 273). None of them changes the return code, the highest of the messages' (p. 282), so check exits as it would without them. IBM has no option that turns a warning into an error: FLAG(x,y) chooses only which messages are listed (pp. 369-370), and a MSGEXIT user exit of the EXIT option can raise a W or I message to any severity up to S, one message at a time, which changes the return code (pp. 836-837)",
1010 basis: Basis::Chosen,
1011 oracle: Oracle::EnterpriseCobol,
1012 },
1013 Assumption {
1014 id: COMMENT_ENTRY_EXTENT,
1015 claim: "The comment-entry of AUTHOR, INSTALLATION, DATE-WRITTEN, DATE-COMPILED or SECURITY is any characters at all, written in Area B on one or more lines and never in Area A (Language Reference SC27-8713-03, p. 117), and a COPY or REPLACE in it, or where it can appear, is part of it (pp. 700, 708). So a comment-entry runs from its paragraph header's period to the next line, not a comment or blank line, with a character in Area A, whatever the lines between hold; NIST's OBNC1M tests this with a whole program written in Area B inside a SECURITY comment-entry",
1016 basis: Basis::Documented,
1017 oracle: Oracle::EnterpriseCobol,
1018 },
1019 Assumption {
1020 id: COMMENT_ENTRY_HEADERS,
1021 claim: "ironwork takes a line in an IDENTIFICATION DIVISION as a comment-entry paragraph's header when its first word is the paragraph's name and a period follows, in whatever column the name starts, though a paragraph header belongs in Area A (Language Reference SC27-8713-03, p. 55); with no period the paragraph's text is read as program text. A line with a hyphen in column 7 inside a comment-entry, which p. 117 does not permit, is taken as more of the comment-entry rather than refused: the manual does not say how severe Enterprise COBOL's message for either is",
1022 basis: Basis::Chosen,
1023 oracle: Oracle::EnterpriseCobol,
1024 },
1025 Assumption {
1026 id: COMMENT_ENTRY_REMARKS,
1027 claim: "Enterprise COBOL has no REMARKS paragraph: the Language Reference SC27-8713-03 names neither the paragraph (pp. 101, 117) nor the word anywhere. ironwork reads a REMARKS paragraph in an IDENTIFICATION DIVISION as it reads a comment-entry paragraph, as OS/VS COBOL did, where Enterprise COBOL presumably refuses the program",
1028 basis: Basis::Chosen,
1029 oracle: Oracle::EnterpriseCobol,
1030 },
1031 Assumption {
1032 id: CONTINUED_LITERAL_QUOTES,
1033 claim: "A continuation line of an alphanumeric or national literal left open at column 72 has a hyphen in column 7 and a quotation mark as its first nonblank character, and the literal resumes after that mark. When a literal's closing quotation mark is in column 72 and the continuation line starts with two, the pair stands for one quotation mark in one literal; otherwise, a quotation mark that starts a continuation line after a closed literal starts a second literal (Language Reference SC27-8713-03, p. 58). The rules hold for apostrophes alike, and ironwork gives the pair precedence where both could apply",
1034 basis: Basis::Documented,
1035 oracle: Oracle::EnterpriseCobol,
1036 },
1037 Assumption {
1038 id: COPY_SEARCH_ROUNDS,
1039 claim: "A COPY member is looked for in three rounds, each through every copy library in order (the program's own directory, then each -I directory) before the next begins: as NAME.cpy, .CPY, .copy and .COPY; then as .cbl, .CBL, .cob and .COB; then as the name alone; each extension with the name as written, then upper-cased, then lower-cased. In one z/OS UNIX directory IBM tries .cpy, .CPY, .cbl, .CBL, .cob and .COB, each with the name upper- and lower-cased (Language Reference SC27-8713-03, p. 705), and the name alone last (Programming Guide SC27-8714-03, p. 440), searching the current directory, the -I directories and SYSLIB's in turn (LR p. 705, PG p. 441); it does not say whether an earlier directory's .cbl comes before a later one's .cpy. A compile from JCL searches SYSLIB's data sets, then COPYLOC's (LR p. 705), which hold copybooks and not the library the program is read from, so the rounds take a copybook in any library before a program source. .copy is not IBM's, and the name as written, which IBM folds to upper case (PG p. 440), comes first, so that on a file system that ignores case a message names the member as the program spells it; the order differs from IBM's only where two files' names differ only in case",
1040 basis: Basis::Chosen,
1041 oracle: Oracle::EnterpriseCobol,
1042 },
1043 Assumption {
1044 id: COPY_NOT_THE_PROGRAM,
1045 claim: "The file being compiled is never a COPY member of its own compilation, at any depth of nesting: a compile from JCL reads the program from SYSIN and looks for members in SYSLIB and COPYLOC (Language Reference SC27-8713-03, p. 705), so a member named as the program comes from another file or is not found. The program's own directory is a copy library only as ironwork's stand-in for the current directory cob2 searches first (p. 705). Any other member a chain of COPY statements reaches while it is still being copied is refused, as a nested COPY cannot cause recursion (p. 697)",
1046 basis: Basis::Chosen,
1047 oracle: Oracle::EnterpriseCobol,
1048 },
1049 Assumption {
1050 id: COPY_LITERAL_AS_WRITTEN,
1051 claim: "A text-name written as a literal is looked for as written first, through every library, and then with extensions as a user-defined word is (COPY_SEARCH_ROUNDS). IBM takes a literal as the file name, relative path or absolute path it spells (Programming Guide SC27-8714-03, p. 440) and adds extensions only to a name that is not a literal (Language Reference SC27-8713-03, p. 705); the extensions are ironwork's, for sources written for compilers that add them",
1052 basis: Basis::Chosen,
1053 oracle: Oracle::EnterpriseCobol,
1054 },
1055 Assumption {
1056 id: COPY_DOUBLED_PERIOD,
1057 claim: "COPY X.. is refused, naming X.: a COPY statement ends with a separator period (Language Reference SC27-8713-03, p. 697), which is a period followed by a space (pp. 49-50), so the name is X., not X. A text-name or library-name for a data set holds only letters, digits and hyphens (p. 696); in z/OS UNIX directories any COBOL character may appear (p. 697), and X. would then name X..cpy and the like, not X's file. The manuals do not say whether Enterprise COBOL instead reads X and a separator period, leaving the second period in the text, as GnuCOBOL 3.2 does",
1058 basis: Basis::Chosen,
1059 oracle: Oracle::EnterpriseCobol,
1060 },
1061 Assumption {
1062 id: LINAGE_COUNTER,
1063 claim: "LINAGE IS n LINES [WITH FOOTING AT f] [LINES AT TOP t] [LINES AT BOTTOM b] describes a logical page of t + n + b lines, each page following the last with no spacing; TOP and BOTTOM default to 0, and each value is an unsigned integer, at most 99,999,999, or an unsigned integer data item (Language Reference SC27-8713-03, pp. 189-190, 747). OPEN OUTPUT or EXTEND takes all four for the first page, and a WRITE ... ADVANCING PAGE or a page overflow takes the data items' values again for the next page (p. 190). LINAGE-COUNTER, one for each LINAGE file and qualified by its file-name when there are two, has the PICTURE and USAGE of the page body's data item, or is binary with as many digits as its integer; OPEN sets it to 1, it is the line of the page body the printer is at, and no statement may change it (pp. 23-24, 70). A WRITE adds its ADVANCING lines to it, 1 without ADVANCING; a WRITE that would take it past the page body puts its line on the next page's first line, after the printer moves there (AFTER) or before (BEFORE), as ADVANCING PAGE does, and sets it to 1 (pp. 474-475). END-OF-PAGE, which needs LINAGE, runs once the line is written when LINAGE-COUNTER has reached the footing line or the page overflowed, only an overflow counting when FOOTING is not given, and NOT END-OF-PAGE otherwise, neither after a WRITE that failed (p. 475; Programming Guide SC27-8714-03, p. 178). LINAGE takes effect only for a file opened OUTPUT or EXTEND (p. 189), and an SD's does nothing (p. 190)",
1064 basis: Basis::Documented,
1065 oracle: Oracle::EnterpriseCobol,
1066 },
1067 Assumption {
1068 id: LINAGE_PAGE_MOVEMENT,
1069 claim: "A WRITE to a LINAGE file moves the paper in lines, never by a skip to a channel, the logical page not being the printer's form (Language Reference SC27-8713-03, p. 190). When OPEN ends the printer is at the first page's first line, t lines of top margin above line 1 of its page body, so the first WRITE moves those t lines besides its own; a WRITE that starts a new page, by overflow or ADVANCING PAGE, moves the lines left in the page body, the bottom margin, the next page's top margin and one line more, to that page's line 1. The lines are written as any WRITE ... ADVANCING writes them, as control characters and spacing records (PRINT_CONTROL_CHARACTER, PRINT_SPACING_RECORDS), so the margins are blank lines, and a text DD shows them as line feeds (TEXT_PRINT_LINES). OPEN and CLOSE write nothing: a file closed with no WRITE is empty, and the last page is not spaced out",
1070 basis: Basis::Chosen,
1071 oracle: Oracle::EnterpriseCobol,
1072 },
1073 Assumption {
1074 id: LINAGE_END_OF_PAGE,
1075 claim: "The end-of-page condition is judged by LINAGE-COUNTER once the WRITE is done, as the Language Reference words it (SC27-8713-03, p. 475): a WRITE ... ADVANCING PAGE, which leaves LINAGE-COUNTER at 1, raises it only when the next page's FOOTING is 1, whatever line it printed on, and a WRITE ... ADVANCING 0 LINES in the footing area raises it again",
1076 basis: Basis::Chosen,
1077 oracle: Oracle::EnterpriseCobol,
1078 },
1079 Assumption {
1080 id: LINAGE_VALUES,
1081 claim: "A page body under 1 line, a footing line outside the page body or a margin below 0 that data items give at OPEN or at a new page ends the run with ironwork's own abend naming the file: the Language Reference states the rule (SC27-8713-03, p. 189) but no file status for breaking it (Table 34, pp. 300-303), and the Language Environment Runtime Messages (SA38-0686-60) have no message for it. Integers that break it are compile errors",
1082 basis: Basis::Chosen,
1083 oracle: Oracle::EnterpriseCobol,
1084 },
1085 Assumption {
1086 id: LINAGE_EXTEND,
1087 claim: "OPEN EXTEND of a LINAGE file starts a new logical page as OPEN OUTPUT does, top margin first and LINAGE-COUNTER at 1 (Language Reference SC27-8713-03, p. 24), whatever line the data set's last page ended on",
1088 basis: Basis::Chosen,
1089 oracle: Oracle::EnterpriseCobol,
1090 },
1091 Assumption {
1092 id: LINAGE_COUNTER_BETWEEN_WRITES,
1093 claim: "LINAGE-COUNTER is zero until the file is first opened and keeps its value after CLOSE; a WRITE that fails leaves it and the page where they were; OPEN INPUT and I-O set it to 1 as OPEN OUTPUT does, since the Language Reference says so of any OPEN (SC27-8713-03, p. 24)",
1094 basis: Basis::Chosen,
1095 oracle: Oracle::EnterpriseCobol,
1096 },
1097 Assumption {
1098 id: PRINT_FILE_UPDATE,
1099 claim: "A print file opened I-O under ADV holds the control character a byte before each FD record, as it was written (PRINT_CONTROL_CHARACTER): READ skips the byte as PRINT_CONTROL_RUN_TIME says, REWRITE writes the record behind the byte it was read with, REWRITE having no ADVANCING phrase, and WRITE, with or without ADVANCING, fails with file status 48, a sequential file's WRITE needing OUTPUT or EXTEND (Language Reference SC27-8713-03, pp. 471, 476; Table 34, p. 302); LINAGE has no effect on it (p. 189). IBM does not say what REWRITE does with the byte",
1100 basis: Basis::Chosen,
1101 oracle: Oracle::EnterpriseCobol,
1102 },
1103 Assumption {
1104 id: ENTRY_IN_SEQUENCE,
1105 claim: "Control that reaches an ENTRY statement in the program's own sequence passes it as it passes CONTINUE: nothing is bound and no storage changes. The Language Reference says only where a CALL of the entry begins, at the first executable statement after it (SC27-8713-03, pp. 339-340)",
1106 basis: Basis::Chosen,
1107 oracle: Oracle::EnterpriseCobol,
1108 },
1109 Assumption {
1110 id: ENTRY_CALLS,
1111 claim: "A CALL of an ENTRY name begins at the statement after the ENTRY and binds the entry's USING list alone, so a LINKAGE item only the PROCEDURE DIVISION USING names has no address (Language Reference SC27-8713-03, pp. 264, 320, 339-340). A static CALL, of a literal under NODYNAM, enters the one copy of the program that its PROGRAM-ID enters, in its last-used state (Programming Guide SC27-8714-03, pp. 548, 553-554); a dynamic CALL, of an identifier or of a literal under DYNAM, gets for each entry name a copy of the program with WORKING-STORAGE of its own, as if a separate compile unit were called (p. 560), which a CANCEL of that name resets, where p. 549 says only that a second entry point must not be called dynamically without a CANCEL between. CALL finds an entry name among the programs of the source and those already loaded, then in a program library as a member of that name, an alias, as NAME(ALIAS) or binder ALIAS statements make one (pp. 548, 560)",
1112 basis: Basis::Chosen,
1113 oracle: Oracle::EnterpriseCobol,
1114 },
1115 Assumption {
1116 id: ALTERED_GO_TO_RESET,
1117 claim: "Altered GO TOs are put back as written whenever the program's WORKING-STORAGE is initialized: its first CALL, the first after a CANCEL of it, and every CALL of an INITIAL program (Language Reference SC27-8713-03, pp. 103, 318), and not on another CALL (Programming Guide SC27-8714-03, p. 548). Those of an independent segment, priority 50 to 99, are put back when control reaches the segment from a paragraph of another priority by falling into it, GO TO, PERFORM or a SORT or MERGE procedure, but not when a PERFORM made from it returns, nor when a CALL of the program begins in it: p. 265 says 'from a segment with a different priority-number', p. 318 'from another independent segment', and neither names a PERFORM's return",
1118 basis: Basis::Chosen,
1119 oracle: Oracle::EnterpriseCobol,
1120 },
1121 Assumption {
1122 id: DISPLAY_STREAM,
1123 claim: "DISPLAY writes to standard output as a program under z/OS UNIX does with its OUTDD ddname unallocated and _IGZ_SYSOUT unset: one stream of characters, a newline after each DISPLAY except one WITH NO ADVANCING (Programming Guide SC27-8714-03, pp. 36-37; Language Reference SC27-8713-03, pp. 333-335), and UPON any device writes to the same stream. To a ddname IBM writes a record for each DISPLAY, whose first byte is ' ', or '+' after one WITH NO ADVANCING (Programming Guide p. 37); that route is not modelled",
1124 basis: Basis::Chosen,
1125 oracle: Oracle::EnterpriseCobol,
1126 },
1127 Assumption {
1128 id: RANDOM_GENERATOR,
1129 claim: "FUNCTION RANDOM is Park and Miller's minimal standard generator. An argument n starts a sequence at state n mod 2147483646 + 1, a first reference without one starts it as 0 does, and each reference sets the state s to 16807 s mod 2147483647 and returns the new state divided by 2147483647 in long HFP, which is exclusively between zero and one; so the arguments 0 to 2,147,483,645 give distinct sequences and larger ones repeat them. IBM documents the interface (Language Reference SC27-8713-03, p. 629), a long floating-point result under either ARITH (Programming Guide SC27-8714-03, p. 58), and that its generator is not CEERAN0's, 950706376 s mod 2147483647 (Programming Reference SA38-0683-60, pp. 343-344), but not the generator. A fractional argument is truncated to an integer, and a negative one ends the run with abend IRONWORK",
1130 basis: Basis::Chosen,
1131 oracle: Oracle::EnterpriseCobol,
1132 },
1133 Assumption {
1134 id: ZERO_DIVISOR_CHECK,
1135 claim: "A zero divisor that no ON SIZE ERROR phrase takes, in an arithmetic statement without one or in an expression outside an arithmetic statement (a condition, a subscript, a reference modifier), is the program check of the instruction the compiler divides with: HFP divide, S0CF, when the expression is evaluated in floating point; fixed-point divide, S0C9, when the dividend and the divisor are made only of integer binary items and integer literals, at least one an item; decimal divide, S0CB, otherwise. The size error condition belongs to the arithmetic statements alone, and with ON SIZE ERROR any zero divisor, floating-point too, is one (Language Reference SC27-8713-03, p. 296; Programming Guide SC27-8714-03, p. 242); the manuals do not say which instructions the compiler divides with",
1136 basis: Basis::Chosen,
1137 oracle: Oracle::EnterpriseCobol,
1138 },
1139 Assumption {
1140 id: ERROR_DECLARATIVE_MODE,
1141 claim: "An EXCEPTION/ERROR procedure for an open mode serves a file open in that mode, and for OPEN one being opened in it, an OPEN of a file already open included (Language Reference SC27-8713-03, pp. 417, 714). A file that is not open, as for a READ, WRITE or CLOSE before its OPEN, is in no mode, so only a procedure that names it serves it. A procedure that names the file comes first (p. 714), and two procedures for one file, or for one open mode, are refused, as p. 714 forbids simultaneous requests for two",
1142 basis: Basis::Chosen,
1143 oracle: Oracle::EnterpriseCobol,
1144 },
1145 Assumption {
1146 id: ERROR_DECLARATIVE_STATUSES,
1147 claim: "Every I/O status whose first digit is not 0 runs the file's EXCEPTION/ERROR procedure once FILE STATUS holds it, unless the statement's AT END or INVALID KEY phrase takes a 1x or 2x status, and then no procedure runs (Language Reference SC27-8713-03, pp. 299, 303-304, 432, 714); a 0x status runs none. The procedure returns control to the end of the statement, and NOT AT END and NOT INVALID KEY are not run: none of ironwork's statuses is a critical error, after which p. 714 says control does not return. The implicit CLOSE at the end of the run or at CANCEL runs no procedure (Programming Guide SC27-8714-03, pp. 179, 204, 219)",
1148 basis: Basis::Chosen,
1149 oracle: Oracle::EnterpriseCobol,
1150 },
1151 Assumption {
1152 id: SORT_FILE_DECLARATIVE,
1153 claim: "An EXCEPTION/ERROR procedure serves the OPEN, READ, WRITE and CLOSE a SORT or MERGE does of its USING and GIVING files (Language Reference SC27-8713-03, pp. 457-458); the end of a USING file runs none. After it, that file's processing ends: a USING file gives the records read before the failure and is closed, a GIVING file is closed, and the operation goes on with SORT-RETURN 0, unless the procedure moved 16 to SORT-RETURN, which stops it at once with SORT-RETURN 16, as the Programming Guide has the procedure do to report the failure (SC27-8714-03, pp. 232, 234-235). A file with no procedure fails as SORT_FILE_FAILURE says. Under FASTSRT a USING or GIVING file that an INPUT, OUTPUT or file-specific procedure serves is COBOL's (p. 233), which FASTSRT_FILES does not list",
1154 basis: Basis::Chosen,
1155 oracle: Oracle::EnterpriseCobol,
1156 },
1157 Assumption {
1158 id: DEBUG_RUNTIME_OPTION,
1159 claim: "USE FOR DEBUGGING procedures run only in a program compiled WITH DEBUGGING MODE and run under the Language Environment runtime option DEBUG, which -debug stands for; NODEBUG, the default, keeps them from running, and debugging lines, once compiled, run under either (Language Reference SC27-8713-03, pp. 771-772; Programming Guide SC27-8714-03, pp. 431, 446). Without WITH DEBUGGING MODE both are comments, and a contained program has the mode of the program containing it (LR pp. 121, 772)",
1160 basis: Basis::Documented,
1161 oracle: Oracle::EnterpriseCobol,
1162 },
1163 Assumption {
1164 id: DEBUG_LINE_NUMBER,
1165 claim: "DEBUG-LINE holds, in six digits with leading zeros, the number of the line the statement starts on in its own source file. Under NONUMBER, the default, IBM puts the compiler-generated number there (Language Reference SC27-8713-03, p. 19), the listing's line number, which counts the lines of COPY members too: a statement after a COPY, or in a member, is numbered otherwise by IBM",
1166 basis: Basis::Chosen,
1167 oracle: Oracle::EnterpriseCobol,
1168 },
1169 Assumption {
1170 id: DEBUG_LINE_STATEMENT,
1171 claim: "The statement DEBUG-LINE names is the one that sent control to the procedure (Language Reference SC27-8713-03, p. 20): the PERFORM on each repetition, the GO TO, the SORT or MERGE, the input-output statement whose condition ran a USE procedure; for fall through, the statement last started in the procedure before, or the section header control passed through. CONTINUE, EXIT, NEXT SENTENCE and a separator period carry no position in ironwork, so after one of them DEBUG-LINE names the statement before it",
1172 basis: Basis::Chosen,
1173 oracle: Oracle::EnterpriseCobol,
1174 },
1175 Assumption {
1176 id: DEBUG_CONTENTS_LENGTH,
1177 claim: "DEBUG-CONTENTS is 30 characters, so DEBUG-ITEM is 86 bytes. The Language Reference gives it as PICTURE X(n) (SC27-8713-03, p. 19), and the procedures Enterprise COBOL debugs put at most 13 characters in it (p. 20)",
1178 basis: Basis::Chosen,
1179 oracle: Oracle::EnterpriseCobol,
1180 },
1181 Assumption {
1182 id: DEBUG_NAME_FORM,
1183 claim: "DEBUG-NAME is the procedure-name as the USE FOR DEBUGGING sentence writes it, a section that qualifies it joined by OF (Language Reference SC27-8713-03, p. 19); under ALL PROCEDURES it is the procedure's own name, unqualified. Control entering a section runs the section's debugging procedure, then, by fall through, that of its first paragraph",
1184 basis: Basis::Chosen,
1185 oracle: Oracle::EnterpriseCobol,
1186 },
1187 Assumption {
1188 id: DEBUGGING_SECTION_REFERENCES,
1189 claim: "A debugging section may PERFORM or GO TO a procedure of another debugging section, and of an EXCEPTION/ERROR section: p. 771 of the Language Reference (SC27-8713-03) forbids referring to a procedure in a debugging section from a statement outside of the debugging section, read here as outside every debugging section, as the CCVS85 DB tests assume, and p. 716 forbids references to nondeclarative procedures only. Without WITH DEBUGGING MODE a debugging section is a comment in full, header and USE sentence included, so its names are not defined and its text is not checked (p. 772)",
1190 basis: Basis::Chosen,
1191 oracle: Oracle::EnterpriseCobol,
1192 },
1193 Assumption {
1194 id: GLOBAL_DECLARATIVES,
1195 claim: "A program's declaratives run for its own statements only. USE GLOBAL AFTER EXCEPTION/ERROR for an open mode, and USE GLOBAL BEFORE REPORTING for a report group of a contained program without its own procedure for it, would serve another program's statements (Language Reference SC27-8713-03, p. 715; Report Writer Precompiler SC26-4301-04, 4.7.2 rule 5 and 4.7.3 rule 4), and are refused in a program that contains others; elsewhere GLOBAL changes nothing. A GLOBAL procedure for a named file is kept, since a contained program cannot name another program's file in ironwork, which has no GLOBAL files",
1196 basis: Basis::Chosen,
1197 oracle: Oracle::EnterpriseCobol,
1198 },
1199 Assumption {
1200 id: SYNC_SUBORDINATE_GROUP,
1201 claim: "SYNCHRONIZED on a group at level 02 to 49 synchronizes each elementary item within it, as the clause does on a level-01 group; the Language Reference allows it on elementary items and level-01 groups (SC27-8713-03, p. 231) and says nothing of other groups",
1202 basis: Basis::Chosen,
1203 oracle: Oracle::EnterpriseCobol,
1204 },
1205 Assumption {
1206 id: SYNC_ONLY_WHEN_WRITTEN,
1207 claim: "A binary, COMP-1, COMP-2, POINTER or INDEX item is aligned only when SYNCHRONIZED applies to it. Table 15 of the Language Reference says a subordinate binary item is aligned on 2 or 4 bytes 'when the synchronized clause is not specified', and in the same row that 'when SYNCHRONIZED is not specified for binary items, no space is reserved for slack bytes' (SC27-8713-03, p. 232); ironwork takes the second, and the first as a slip for 'specified'. A synchronized binary item of 10 to 18 digits is aligned on 4 bytes, as the slack-byte algorithm gives (p. 233), not on 8",
1208 basis: Basis::Chosen,
1209 oracle: Oracle::EnterpriseCobol,
1210 },
1211 Assumption {
1212 id: SYNC_SLACK_OWNER,
1213 claim: "Slack bytes before a synchronized item belong to the group of the elementary item before it (Language Reference SC27-8713-03, p. 234), so a group that ended just before them grows by them; but when that group is a table or a redefinition, or ends earlier than the slack begins, the slack bytes stay in the group that holds it and the table's occurrences keep their length",
1214 basis: Basis::Chosen,
1215 oracle: Oracle::EnterpriseCobol,
1216 },
1217 Assumption {
1218 id: SYNC_REDEFINES_REFUSED,
1219 claim: "A synchronized item that starts a redefinition where its boundary would need slack bytes stops the compile. The Language Reference says such an item must not need them and that the redefined item must be aligned for it (SC27-8713-03, pp. 232-233), but not what the compiler does when a program breaks the rule",
1220 basis: Basis::Chosen,
1221 oracle: Oracle::EnterpriseCobol,
1222 },
1223 Assumption {
1224 id: DECIMAL_COMMA_SEPARATOR,
1225 claim: "Under DECIMAL-POINT IS COMMA a comma between digits, or after a space, parenthesis or sign and before a digit, is a numeric literal's decimal point, and a comma after any other word is a separator even with a digit after it, so T(1,2) has the one subscript 1,2 and T(I,2) has two. The Language Reference says only that a separator comma is a comma followed by a space (SC27-8713-03, p. 49) and that the clause exchanges the comma's and the period's functions in numeric literals (p. 131); a period before a digit is then an error",
1226 basis: Basis::Chosen,
1227 oracle: Oracle::EnterpriseCobol,
1228 },
1229 Assumption {
1230 id: DECIMAL_COMMA_DISPLAY_LITERAL,
1231 claim: "DISPLAY of a numeric literal writes it as the program wrote it, so under DECIMAL-POINT IS COMMA its decimal point is a comma; the Language Reference says nothing of how DISPLAY shows a numeric literal (SC27-8713-03, pp. 333-334)",
1232 basis: Basis::Chosen,
1233 oracle: Oracle::EnterpriseCobol,
1234 },
1235 Assumption {
1236 id: ARITH_DIGIT_LIMITS,
1237 claim: "A numeric or numeric-edited PICTURE whose digit positions, scaling positions P included, exceed 18 under ARITH(COMPAT) or 31 under ARITH(EXTEND), and a numeric literal with more digits than that, stop the compile (Language Reference SC27-8713-03, pp. 45, 209, 217-218; Programming Guide SC27-8714-03, p. 349). Neither manual gives the diagnostic's severity, and P is counted for every numeric item, where the Language Reference counts it for numeric-edited items and arithmetic operands (p. 209)",
1238 basis: Basis::Chosen,
1239 oracle: Oracle::EnterpriseCobol,
1240 },
1241 Assumption {
1242 id: MULTIPLE_RESULTS,
1243 claim: "An arithmetic statement with several receivers computes what they share once, before any is stored, and each receiver in turn then takes it or combines it with its own current value, its subscripts evaluated then (Language Reference SC27-8713-03, p. 298). For ADD, SUBTRACT, MULTIPLY and DIVIDE without GIVING the shared part is the operands other than the receiver; for COMPUTE and the GIVING forms it is the whole expression, so a receiver that COMPUTE names twice gets the same result twice",
1244 basis: Basis::Chosen,
1245 oracle: Oracle::EnterpriseCobol,
1246 },
1247 Assumption {
1248 id: ALTER_DEBUGGING,
1249 claim: "Once an ALTER has run, the debugging section that serves each paragraph it alters runs, once for each TO [PROCEED TO] phrase in the order written, with DEBUG-LINE the ALTER, DEBUG-NAME the altered paragraph as DEBUG_NAME_FORM gives it, and DEBUG-CONTENTS the procedure-name after TO PROCEED TO, a qualifier after OF (Language Reference SC27-8713-03, pp. 19-20, 716). A procedure named only after TO PROCEED TO gets no debugging section from the ALTER: p. 716 says an ALTER 'referring to the named procedure', and Table 2 on p. 20 has an ALTER row for procedure-name-1 alone, as CCVS85 DB105A expects under ALL PROCEDURES. Under ALL PROCEDURES an ALTER in the declaratives runs none, as p. 716 says; there an ALTER of a paragraph that a USE FOR DEBUGGING names still runs its section, as p. 716 makes no exception for it",
1250 basis: Basis::Chosen,
1251 oracle: Oracle::EnterpriseCobol,
1252 },
1253 Assumption {
1254 id: PERFORM_RETURN_POINTS,
1255 claim: "An out-of-line PERFORM arms a return point at the end of its range's last paragraph (Language Reference SC27-8713-03, p. 419), one per activation, since a CALL resets return points (Programming Guide SC27-8714-03, p. 547). Control that passes that end by any path, falling through or by GO TO, returns to the PERFORM, so PERFORM B THRU A with A before B returns when control reaches the end of A, and a range that passes the end of another active PERFORM's range returns there to that PERFORM. Neither manual says what a PERFORM that control leaves by GO TO leaves behind: its return point stays armed, as the Programming Guide's warning against ranges that keep control from the end implies (p. 772), until control passes it and returns after that PERFORM, which then puts back the point it displaced; ironwork refuses at run time to return so into a PERFORM that repeats or is inside another statement. EXIT SECTION goes to the end of the section, past the return point of a performed paragraph in it (LR p. 345)",
1256 basis: Basis::Chosen,
1257 oracle: Oracle::EnterpriseCobol,
1258 },
1259 Assumption {
1260 id: FLOAT_FUNCTION_ARGUMENTS,
1261 claim: "A floating-point argument, item or expression, is allowed wherever a function takes a numeric argument and refused where it takes an integer (Language Reference SC27-8713-03, p. 507). INTEGER and INTEGER-PART of one return an integer of 30 digits, 31 under ARITH(EXTEND), and ABS, MAX, MIN and REM with one are evaluated in floating point and return it (Programming Guide SC27-8714-03, pp. 799 and 801). The guide names REM a mixed function where the Language Reference types it numeric (p. 633), and gives the precision only of floating-point functions: a mixed function is evaluated here in long floating point, extended under ARITH(EXTEND), as they are",
1262 basis: Basis::Chosen,
1263 oracle: Oracle::EnterpriseCobol,
1264 },
1265 Assumption {
1266 id: FLOAT_FUNCTION_ROUNDING,
1267 claim: "The floating-point intrinsic functions are computed in binary to 128 bits and rounded to the nearest long HFP value under ARITH(COMPAT), extended under ARITH(EXTEND), ties away from zero; a fixed-point argument is first converted to HFP of that precision (C5). IBM computes SQRT, EXP, EXP10, LOG, LOG10 and the trigonometric functions with Language Environment's math services, CEESDSQT and the rest (Programming Guide SC27-8714-03, p. 58), whose results can differ from the nearest value in the last hexadecimal digit. ANNUITY, PRESENT-VALUE and the statistics functions, which have no such service, are computed the same way, where IBM's generated code may truncate at each HFP step",
1268 basis: Basis::Chosen,
1269 oracle: Oracle::EnterpriseCobol,
1270 },
1271 Assumption {
1272 id: FLOATING_POINT_FUNCTIONS,
1273 claim: "ACOS, ANNUITY, ASIN, ATAN, COS, LOG, LOG10, MEAN, MEDIAN, MIDRANGE, PRESENT-VALUE, RANDOM, SIN, SQRT, STANDARD-DEVIATION, TAN and VARIANCE are floating-point functions, as earlier Programming Guides listed them; E, PI, EXP, EXP10 and NUMVAL-F are, as the Language Reference says (SC27-8713-03, pp. 553-557, 609); SECONDS-FROM-FORMATTED-TIME is, as its example's inexact result shows (p. 507), and SECONDS-PAST-MIDNIGHT with it. ABS, MAX, MIN, RANGE, REM and SUM are floating point when any argument is (Programming Guide, p. 799; C100). An expression holding a floating-point function is evaluated in floating point (pp. 62-63). NUMVAL and NUMVAL-C are too, long under ARITH(COMPAT) and extended under ARITH(EXTEND), as the Programming Guide says (SC27-8714-03, p. 115); COMBINED-DATETIME is long whatever ARITH says (p. 541)",
1274 basis: Basis::Recalled,
1275 oracle: Oracle::EnterpriseCobol,
1276 },
1277 Assumption {
1278 id: FUNCTION_DOMAIN,
1279 claim: "An argument outside a function's domain ends the run with abend IRONWORK: SQRT of a negative number, LOG or LOG10 of zero or less, ASIN or ACOS beyond -1 to +1, ANNUITY with a negative rate or periods that are not a positive integer, PRESENT-VALUE at a rate of -1 or less, FACTORIAL beyond 28 (29 under ARITH(EXTEND)), a century window whose end year is outside 1700 to 9999, HEX-TO-CHAR or BIT-TO-CHAR of other characters or of a length that is not a multiple of 2 or 8. IBM leaves such values undefined (Language Reference SC27-8713-03, p. 500) and Language Environment's math services signal a condition. SIN, COS and TAN of an argument beyond 2^63 times pi/2, which ironwork does not reduce, end the run the same way. A result beyond HFP's range is an exponent overflow, S0CC, and one below it zero (C8)",
1280 basis: Basis::Chosen,
1281 oracle: Oracle::EnterpriseCobol,
1282 },
1283 Assumption {
1284 id: NUMVAL_TEST_RULES,
1285 claim: "TEST-NUMVAL, TEST-NUMVAL-C and TEST-NUMVAL-F follow the formats of NUMVAL, NUMVAL-C and NUMVAL-F (Language Reference SC27-8713-03, pp. 605-609, 651-655), choosing where they are silent: CR and DB in either case; NUMVAL-C's grouping separator only between digits and before the decimal point; NUMVAL-F's E in either case, spaces allowed around it, its exponent sign optional, and the 16-digit mantissa limit with an exponent not checked; a string that stops short, or holds only spaces, gives its length + 1. NUMVAL-C's currency string defaults to $. NUMVAL-F of a string that breaks them returns zero, as NUMVAL does here",
1286 basis: Basis::Chosen,
1287 oracle: Oracle::EnterpriseCobol,
1288 },
1289 Assumption {
1290 id: FUNCTION_CLOCK,
1291 claim: "SECONDS-PAST-MIDNIGHT, FORMATTED-CURRENT-DATE, whose offset is therefore +0000, and the year of execution that YEAR-TO-YYYY, DATE-TO-YYYYMMDD and DAY-TO-YYYYDDD window by, read the run unit's clock as UTC to the hundredth of a second, as CURRENT-DATE does here (+0000); z/OS gives local time, and finer seconds (Language Reference SC27-8713-03, p. 631)",
1292 basis: Basis::Chosen,
1293 oracle: Oracle::EnterpriseCobol,
1294 },
1295 Assumption {
1296 id: UUID4_SOURCE,
1297 claim: "UUID4 takes its 122 random bits from the process's randomly keyed hasher over the clock, not from a cryptographic generator; IBM uses the Message-Security-Assist random number facility where the machine has it (Language Reference SC27-8713-03, p. 669). The version and variant bits are set and the string is lowercase, as IBM's example shows",
1298 basis: Basis::Chosen,
1299 oracle: Oracle::EnterpriseCobol,
1300 },
1301 Assumption {
1302 id: FORMATTED_DATETIME_RULES,
1303 claim: "The FORMATTED functions, INTEGER-OF-FORMATTED-DATE, SECONDS-FROM-FORMATTED-TIME and TEST-FORMATTED-DATETIME take the formats of the Language Reference (SC27-8713-03, pp. 504-506), choosing where it is silent or inconsistent: the decimal separator of a fractional-seconds format appears in the data, as its rules say, though several of its examples omit it (pp. 561, 566, 568, 629); fractional seconds are truncated; a comma may stand for the period; a UTC format moves the date as well as the time by the offset; a week may be 53 where the ISO year has 53 weeks, though p. 506 says 01 to 52; an offset sign of 0 takes only 00 hours and minutes; INTEGER-OF-FORMATTED-DATE reads the date part alone, as p. 579 says the time part does not change its result. TEST-FORMATTED-DATETIME names the first position at which a field can no longer be in range, or a value longer than its format errs at the first extra character. A format that is not one of IBM's, which Enterprise COBOL refuses at compile time, ends the run here",
1304 basis: Basis::Chosen,
1305 oracle: Oracle::EnterpriseCobol,
1306 },
1307 Assumption {
1308 id: ROUNDED_EXTRA_PLACE,
1309 claim: "A receiver named with ROUNDED counts in dmax with one decimal place more than it holds, so a quotient, or an intermediate cut back to dmax places, keeps the digit that rounding reads: DIVIDE 44.1 INTO a PIC 9(4)V9 of 1661.7 ROUNDED gives 37.7, as CCVS85 NC117A and NC171A expect. The Programming Guide says only that under ROUNDED one more decimal place, and one more integer place, might be carried for accuracy if necessary (SC27-8714-03, p. 794); the Language Reference's ROUNDED phrase compares the result's fraction with the receiver's (SC27-8713-03, p. 296)",
1310 basis: Basis::Chosen,
1311 oracle: Oracle::EnterpriseCobol,
1312 },
1313 Assumption {
1314 id: CURRENCY_SIGNS,
1315 claim: "Once a program has a CURRENCY SIGN clause, $ is a currency symbol in its PICTUREs only if a clause names it: the Language Reference says the currency symbol is $ or the character a clause or the CURRENCY option specifies, and that the clause overrides the option (SC27-8713-03, pp. 130, 212), not that $ stays. A floating currency string of a value longer than one character ends in the position left of the first digit shown, the first currency position holding the whole value (p. 210). NUMVAL-C and TEST-NUMVAL-C without argument-2 take as cs the value of the program's only CURRENCY SIGN clause, where p. 616 names the currency symbol, the CURRENCY option's character when there is no clause (p. 212; C141), and $ otherwise. A hexadecimal currency sign literal is refused, since its character depends on the code page",
1316 basis: Basis::Chosen,
1317 oracle: Oracle::EnterpriseCobol,
1318 },
1319 Assumption {
1320 id: JSON_GENERATE_RULES,
1321 claim: "JSON GENERATE (Language Reference SC27-8713-03, pp. 369-382) writes zoned, packed, binary, index and internal floating-point items as JSON numbers and every other elementary item as a string, choosing where the manual is silent: a table element that a SUPPRESS ... WHEN phrase leaves out is left out of its array, and a table all of whose elements are left out is left out; the members of an unnamed group join its parent's object; a COMP-1 or COMP-2 value takes the digits of its exact HFP value rounded to 9 or 18 significant digits; a character an EBCDIC ENCODING cannot hold becomes X'3F'; when the receiver is too small it holds the leading bytes of the document, whole characters for a national receiver, and COUNT names that many character positions; JSON-CODE and JSON-STATUS are declared in each program that has the statement rather than as GLOBAL in the outermost one",
1322 basis: Basis::Chosen,
1323 oracle: Oracle::EnterpriseCobol,
1324 },
1325 Assumption {
1326 id: XML_PARSE_RULES,
1327 claim: "XML PARSE runs as under XMLPARSE(XMLSS); XMLPARSE(COMPAT) and VALIDATING are not supported. Where the manuals are silent: a document that is not well formed gives XML-CODE with z/OS XML System Services' return code 12 and the non-validating parser's reason (SA38-0681-50, Appendix B): 2004 when it ends before the root's end tag, 2019 with no root, 3000 a duplicate attribute, 3008 -- in a comment, 3022 < in an attribute value, 3028 a bad character reference, 3035 a mismatched end tag, 3060 a malformed XML declaration or a later processing instruction named xml, 3061 an undeclared entity, 3062 any other character out of place, text after the root included, 3065 a second root; an undeclared prefix is Enterprise COBOL's warning 00040800 or 00040801, reported before the name's own event, and the parse goes on only when the processing procedure sets XML-CODE to zero, as the Programming Guide's Table 83 shows (pp. 656-658); after any other exception XML-CODE keeps the parser's code whatever the procedure sets. At END-OF-INPUT, XML-CODE 1 takes identifier-1's content, evaluated again, as the next segment, and any other value ends the input, so an unfinished document is then an exception. Markup a segment ends inside is held until it is complete, while content, comments and processing-instruction data are reported in parts, the target again before each later part (Programming Guide SC27-8714-03, pp. 652-653); START-OF-CDATA-SECTION waits for a character after <![CDATA[; namespace declarations are reported after START-OF-ELEMENT and before the attributes; a character reference to a character the document's code page lacks is a NATIONAL-CHARACTER event; XML-TEXT for EXCEPTION holds the document up to the error; the registers' fragments live in run-unit storage released after each event",
1328 basis: Basis::Chosen,
1329 oracle: Oracle::EnterpriseCobol,
1330 },
1331 Assumption {
1332 id: XML_GENERATE_RULES,
1333 claim: "Where the Language Reference (SC27-8713-03, pp. 484-494) and the Programming Guide (SC27-8714-03, pp. 663-669, 817) are silent, XML GENERATE: trims alphanumeric-edited and numeric-edited values of trailing spaces only, as items of class alphanumeric; puts an unnamed group's members in its parent's element; places TYPE CONTENT items in the parent's content in the order of the data description, among its child elements; writes an element with no content as a start and an end tag, never an empty-element tag, as the Programming Guide's examples show, and keeps a group with no attributes and no content unless a SUPPRESS phrase is given; lets an item's own SUPPRESS ... WHEN decide for it in place of every EVERY phrase; writes a value holding a character XML 1.0 cannot hold as the item's storage in upper-case hexadecimal under its name prefixed hex., sets 417 and goes to ON EXCEPTION once the whole document is written, with 400 before 417 and 417 before 418; drops a namespace's trailing spaces, escapes it as an attribute value, gives 416 for a character XML cannot hold, and ignores NAMESPACE-PREFIX when the namespace is empty; names an EBCDIC CCSID in the XML declaration as IBM- and at least three digits, as the Programming Guide's IBM-037 shows; makes a national item in a document in an EBCDIC code page exception 420 at run time, where the manual makes it a compile-time rule, and a character the code page lacks its ? with 418; and leaves the receiver and COUNT unchanged for 411, 414, 415, 416, 419 and 420",
1334 basis: Basis::Chosen,
1335 oracle: Oracle::EnterpriseCobol,
1336 },
1337 Assumption {
1338 id: JSON_PARSE_RULES,
1339 claim: "Where the Language Reference (SC27-8713-03, pp. 382-396) and the Programming Guide (SC27-8714-03, pp. 609-617, 819-822) are silent, JSON PARSE: takes only an object or an array as the outermost value (100 otherwise); gives 104 for an object or array where an elementary item stands, and for any other value where a group or table stands; lets a pair that names a suppressed item pass without status 2; reads an unnamed group's members as its parent's and leaves an unnamed table alone; compares duplicate pairs as parsed values, 4 when equal and 103 when not, the first staying; ends the walk at an exception, leaving what it set, with JSON-STATUS as far as it got, and gives 106 when no value reached an elementary item or a null; sets an INDICATING indicator whenever its item's pair is met, the first value for null and the second otherwise; reads a string for a numeric receiver as spaces, a sign, digits with at most one decimal point, and spaces (the form of APAR PH65883); moves a number into an alphanumeric or national receiver only as an integer, as MOVE moves an integer literal, the sign dropped; truncates fraction digits beyond the receiver's; sets 128 when a numeric receiver loses high-order digits, 256 when a string loses characters other than spaces or an integer loses digits, and 512 with X'3F' for each character the code page lacks; rounds a number once into COMP-1 or COMP-2; accepts WITH DETAIL without issuing the IGZ messages; and, as JSON GENERATE does, takes a table named without its last subscript as the whole table",
1340 basis: Basis::Chosen,
1341 oracle: Oracle::EnterpriseCobol,
1342 },
1343 Assumption {
1344 id: DLI_TRANSLATION,
1345 claim: "EXEC DLI is read as the IMS translator reads it (IMS Application Programming: EXEC DLI Commands for CICS and IMS, SC18-7811-04, chapters 4-6): a command by its name or longer spelling (DELETE, from the book's C sample, for DLET), its options checked against the book's Format diagrams (pp. 35-81), GHU, GHN and GHNP taking their Get command's (p. 102), AIB allowed wherever PCB is (p. 5), and GMSG, ICMD and RCMD, which the book leaves to the Operations Guide, not checked; the data an option names and the right-hand side of each WHERE comparison declared; SEGMENT or PSB in double parentheses naming an area. The book names no relational operators or connectors beyond its examples' =, >=, >, < and AND and OR, so EQ, NE, GT, GE, LT, LE, <=, ¬= and the symbols &, |, * and + are accepted too. The DL/I interface block is declared at the head of WORKING-STORAGE with the book's COBOL labels over the 40 bytes its C declaration gives (p. 6), the unnamed bytes FILLER, unless the program declares DIBSTAT itself; the book does not name the 01 level, so it is DLZDIB, DL/I's name for the block, and the translator's IS GLOBAL is left out. A command is checked, not run: reaching one ends the run",
1346 basis: Basis::Chosen,
1347 oracle: Oracle::EnterpriseCobol,
1348 },
1349 Assumption {
1350 id: CORRESPONDING_PAIRS,
1351 claim: "MOVE, ADD and SUBTRACT CORRESPONDING name one sending and one receiving group, neither reference-modified nor a level-66, 77 or 88 item. Two items under them correspond when they have the same name and the same qualifiers up to the groups, neither is FILLER, and neither is described with RENAMES, REDEFINES, OCCURS or a USAGE of INDEX, POINTER, FUNCTION-POINTER, PROCEDURE-POINTER or OBJECT REFERENCE, which also leaves out everything under such an item; for MOVE at least one is elementary and the move is valid in IBM's table of elementary moves, and for ADD and SUBTRACT both are elementary numeric. Each MOVE pair gives the result of its own MOVE, and ROUNDED and the SIZE ERROR phrases apply to every ADD or SUBTRACT pair, ON SIZE ERROR running once after all of them (Language Reference for Enterprise COBOL 6.4, 'CORRESPONDING phrase', 'MOVE statement', 'ADD statement', 'SUBTRACT statement', 'SIZE ERROR phrases' and 'Valid and invalid elementary moves')",
1352 basis: Basis::Documented,
1353 oracle: Oracle::EnterpriseCobol,
1354 },
1355 Assumption {
1356 id: CORRESPONDING_CHOICES,
1357 claim: "Where the Language Reference leaves CORRESPONDING open: pairs are processed in the order of the sending group's entries; the items of a FILLER group are not considered; an item is alphabetic when its PICTURE holds only A, as ironwork has no alphabetic category of its own; a numeric-edited item is not numeric for ADD and SUBTRACT, following the rule over the manual's example, which adds two; ADD and SUBTRACT evaluate every sending item before storing any receiver (C97), which differs from pair-by-pair only when a receiving item overlaps a later sending one; and no message is given when no items correspond",
1358 basis: Basis::Chosen,
1359 oracle: Oracle::EnterpriseCobol,
1360 },
1361 Assumption {
1362 id: STOP_LITERAL,
1363 claim: "STOP literal communicates the literal to the operator and suspends the program until the operator intervenes, then continues with the next statement (Language Reference for Enterprise COBOL 6.4, 'STOP statement'). ironwork has no operator to wait for: it writes the literal as DISPLAY does and continues at once",
1364 basis: Basis::Chosen,
1365 oracle: Oracle::EnterpriseCobol,
1366 },
1367 Assumption {
1368 id: NUMPROC_MIG_WARNS,
1369 claim: "NUMPROC(MIG) on a CBL or PROCESS card is a warning (W, return code 4), and the compile takes the default NUMPROC, NOPFD, as ironwork has no installation defaults, whatever NUMPROC an earlier option set (Migration Guide GC27-8715-03, Table 23, p. 112, and Table 32, p. 167). The guide gives neither the message's number nor its text: the message is ironwork's own",
1370 basis: Basis::Documented,
1371 oracle: Oracle::EnterpriseCobol,
1372 },
1373 Assumption {
1374 id: INVALID_OPTION_DISCARDED,
1375 claim: "A suboption that an option ironwork reads does not have, such as TRUNC(FAST), ARITH(X), NOCOMPILE(U) or a CODEPAGE that is not a number, is an error (E, return code 8) and the option is discarded, the setting before it staying in force, as the Migration Guide records for removed TEST suboptions: 'Error (Invalid option diagnostic, option discarded)' (GC27-8715-03, Table 34, p. 168); the Programming Guide shows the compiler diagnosing a CBL statement's options and carrying on (SC27-8714-03, pp. 279-280). The message's number and text are not in the manuals ironwork has: the text is ironwork's, unchanged from when the option stopped the compile. A CODEPAGE that is a number but no single-byte EBCDIC page ironwork carries still stops the compile (S), since IBM would compile the program in that page and ironwork cannot read it so; an option name that is in no table of IBM's still passes without a message",
1376 basis: Basis::Documented,
1377 oracle: Oracle::EnterpriseCobol,
1378 },
1379 Assumption {
1380 id: OPTIONS_WITHOUT_EFFECT,
1381 claim: "Options Enterprise COBOL 6.4 no longer has are accepted without effect. LIB, which the compiler now always behaves as having, and SIZE (Migration Guide GC27-8715-03, Table 32, p. 167) are informational (return code 0), as Enterprise COBOL 6.3 gives them for invocation parameters LIB and SIZE(2097152) in job output in the corpus: IGYOS4090-I 'The \"LIB\" option specification is no longer required. COBOL library processing is always in effect.' and IGYOS4013-I 'The \"SIZE\" option is no longer supported.' (SamMoussa961_COBOL, CLHELLO JOB03701); ironwork gives them for a CBL or PROCESS card too, and takes SZ as SIZE's abbreviation. FLAGSAA and NOFDUMP are warnings (W, return code 4), as the guide says IBM warns for each (Table 23, p. 112), with ironwork's text since the guide gives none. FDUMP, which IBM maps to TEST, and NOLIB pass without a message, as TEST does here; no source ironwork has shows IBM's message for NOLIB. The messages are ironwork's own words",
1382 basis: Basis::Observed,
1383 oracle: Oracle::EnterpriseCobol,
1384 },
1385 Assumption {
1386 id: NON_COBOL_CHARACTERS,
1387 claim: "A single-byte character outside the basic COBOL character set (Language Reference SC27-8713-03, Table 1, pp. 3-6), outside a literal, comment or PICTURE string, is accepted with IGYLI0163-E, 'Non-COBOL character \"%\" was found in column 8. The character was accepted.' (Migration Guide GC27-8715-03, p. 127), one message for each such character: an error (E, return code 8), so the program still runs under NOCOMPILE(S). Accepted means it is read as a character of the word it is in, or as a word of its own, which the parse then takes or refuses as it would any word. The guide calls non-COBOL the EBCDIC characters outside the set (p. 125), so control characters count; a character beyond U+00FF, which z/OS would hold in DBCS, is still refused, as are $ and &, whose own messages ironwork keeps. COPY REPLACING works on the text before it is read, so a character that REPLACING removes, which IBM diagnoses in the member, gives no message here",
1388 basis: Basis::Documented,
1389 oracle: Oracle::EnterpriseCobol,
1390 },
1391 Assumption {
1392 id: NO_PROGRAM_END,
1393 claim: "A program with no STOP RUN, GOBACK or EXIT PROGRAM statement anywhere in its PROCEDURE DIVISION, DECLARATIVES included, gets IGYPS2091-W, 'No \"STOP RUN\", \"GOBACK\" or \"EXIT PROGRAM\" was found in the program. Check program logic to verify that the program will exit.' (Migration Guide GC27-8715-03, p. 131): a warning (W, return code 4) with no line, in ironwork's words. A class definition and its methods, which end with EXIT METHOD, get no such warning. One that has an EXEC CICS RETURN or EXEC CICS XCTL is exempt by default, by the operator's choice pending an Enterprise COBOL listing of such a program, and --cics-return-warning says what it gets: once, the default, an informational note (return code 0) in place of the warning; always, the warning; never, nothing. The evidence points the other way: the CICS translator turns EXEC CICS RETURN into Call 'DFHEI1' using by content x'0e0800000600001000' end-call, with no GOBACK after it (CICS TS Application Programming Guide SC34-6433-06, pp. 87-88; IBM's CICS TS COBOL translation-output page shows the same), and the guide names only the three statements, so Enterprise COBOL itself would likely warn. The note is once per ironwork invocation because check, run and cics print the messages of one program, the first in the source",
1394 basis: Basis::Chosen,
1395 oracle: Oracle::EnterpriseCobol,
1396 },
1397 Assumption {
1398 id: USE_WITHOUT_PARAGRAPH,
1399 claim: "A DECLARATIVES section whose USE statement is followed at once by the next section or END DECLARATIVES gets IGYPS2036-I, 'A paragraph-name was missing after the \"USE\" statement.', informational (return code 0), on the line that follows, as Enterprise COBOL 6.3 gives it for CCVS85 IC401M, DB301M, DB302M and DB305M in the compile listings of eclipse-che4z's COBOL language server tests. No manual ironwork has lists the message. A USE statement followed by statements with no paragraph-name, and a debugging section read as a comment without WITH DEBUGGING MODE, get none, as no listing shows what IBM gives for them",
1400 basis: Basis::Observed,
1401 oracle: Oracle::EnterpriseCobol,
1402 },
1403 Assumption {
1404 id: PICTURE_ENDS_AT_ITS_SEPARATOR,
1405 claim: "A PICTURE character-string is delimited only by a separator space, comma, semicolon or period (Language Reference SC27-8713-03, p. 48), and a separator comma, semicolon or period is that character followed by a space (p. 50), so only the last such character before the space is a separator and any before it belong to the string: PIC 9,9,9,. is 9,9,9, with an insertion comma at its end, and PIC 999.. is 999. with its decimal point at its end, as CCVS85 NC125A writes them. As an IBM extension the string so ended may also be followed by a separator comma or semicolon and further clauses, where the 85 standard requires the separator period (p. 744), so PIC 999., VALUE ZERO is 999. too. DECIMAL-POINT IS COMMA exchanges the period's and comma's functions only within PICTURE strings and numeric literals (pp. 131, 208), not as separators, so the same holds under it",
1406 basis: Basis::Documented,
1407 oracle: Oracle::EnterpriseCobol,
1408 },
1409 Assumption {
1410 id: ZONED_COMPARED_AS_BYTES,
1411 claim: "A zoned integer compared with a nonnumeric operand, an alphanumeric, alphanumeric-edited, numeric-edited or group item, an alphanumeric or hexadecimal literal, or a figurative constant other than ZERO, is compared as the bytes it holds, without being read as a number: a numeric integer in such a comparison is treated as moved to an alphanumeric item of its size (Language Reference, comparison of numeric and alphanumeric operands), which for zoned data copies the digits. Under ZWB, IBM's default, a sign it overpunches is removed first (its zone made F); under NOZWB it is kept (Programming Guide SC27-8714-03, p. 431: 'Use NOZWB if you want to test input numeric fields for SPACES'); a separate sign is left out either way. So an unsigned item holding spaces equals SPACES, and a signed one does under NOZWB, where reading it as a number would end in a data exception. A scaled item is compared as its digits, as before",
1412 basis: Basis::Chosen,
1413 oracle: Oracle::EnterpriseCobol,
1414 },
1415 Assumption {
1416 id: APOST_EVERYWHERE,
1417 claim: "Under APOST the figurative constant QUOTE is the apostrophe wherever the program uses it: X'7D' in an alphanumeric item, X'0027' in a national one, and as an entry of an ALPHABET clause. The Programming Guide says only that [ALL] QUOTE and QUOTES represent apostrophes under APOST and quotation marks under QUOTE, and that either may delimit a literal whichever is in effect (SC27-8714-03, p. 347)",
1418 basis: Basis::Chosen,
1419 oracle: Oracle::EnterpriseCobol,
1420 },
1421 Assumption {
1422 id: CURRENCY_OPTION,
1423 claim: "CURRENCY(literal), in a program with no CURRENCY SIGN clause of its own or of a containing program, acts as a CURRENCY SIGN clause whose value is the literal's one character, standing for itself: that character is the PICTURE currency symbol in place of $, and an edited item shows it. The Language Reference says the currency symbol is $ or the one character the CURRENCY option or a CURRENCY SIGN clause gives, and that a CURRENCY SIGN clause makes the option ignored (SC27-8713-03, pp. 130, 211); the Programming Guide lists the characters the literal may not be (SC27-8714-03, p. 358). That the currency sign value is the character itself, and that nothing is said when the option is ignored, are chosen. A hexadecimal literal is read in the program's code page once every card is applied, so CODEPAGE may follow it; one whose character the option may not name is an error and the option is discarded, as an invalid suboption is (C121). NUMVAL-C's default currency string is not changed here",
1424 basis: Basis::Chosen,
1425 oracle: Oracle::EnterpriseCobol,
1426 },
1427 Assumption {
1428 id: NSYMBOL_DBCS,
1429 claim: "Under NSYMBOL(DBCS) an N literal is a DBCS literal and a PICTURE of N alone with no USAGE is USAGE DISPLAY-1 (Programming Guide SC27-8714-03, pp. 387-388). ironwork holds no DBCS data, so the first N literal stops the read and each such item is a severe error, both in ironwork's words; a program with neither compiles as under NSYMBOL(NATIONAL), as IBM's text implies it would. NX literals are not N literals. NSYMBOL(NATIONAL) with NODBCS on the cards, which are one level of precedence, leaves DBCS in effect, as Table 46 forces it (p. 344), with a warning (W, return code 4) in ironwork's words, since the message Enterprise COBOL gives for an option dropped in conflict resolution is IGYOS4020-W (J19), as for INITIAL with THREAD (C217); NODBCS alone, with NSYMBOL(NATIONAL) only as the default, is taken as written",
1430 basis: Basis::Chosen,
1431 oracle: Oracle::EnterpriseCobol,
1432 },
1433 Assumption {
1434 id: INITIAL_UNDER_THREAD,
1435 claim: "The INITIAL option with THREAD, on the same or different CBL and PROCESS cards and in either order, is ignored and NOINITIAL forced, with an error message (Programming Guide SC27-8714-03, p. 344, Table 46); under THREAD IBM diagnoses the INITIAL option as an error (p. 418). ironwork gives a warning (W, return code 4) in its own words, as for NORENT with THREAD, since the message Enterprise COBOL gives for an option dropped in conflict resolution is IGYOS4020-W (J19), and the program, its nested programs and the options in its load module are NOINITIAL. An IS INITIAL clause under THREAD keeps J13's error. A class definition gets the warning once and its methods none; the option makes no method initial, as INITIAL is an attribute of a program and its nested programs (p. 374; Language Reference SC27-8713-03, p. 103)",
1436 basis: Basis::Chosen,
1437 oracle: Oracle::EnterpriseCobol,
1438 },
1439 Assumption {
1440 id: VLR_WITHOUT_VARYING,
1441 claim: "VLR(STANDARD) checks the length of a variable-length record a READ returns against the least and greatest of the file's level-01 records, and VLR(COMPAT) against its RECORD IS VARYING IN SIZE FROM min TO max (Programming Guide SC27-8714-03, pp. 422-424, Table 52); a FROM or TO the clause leaves out is the least or greatest level-01 record (Language Reference SC27-8713-03, p. 187), and a level-01 record's least length counts an OCCURS DEPENDING ON table at its fewest occurrences, 1 when the entry has no integer-1 TO (pp. 188, 204). A file without RECORD IS VARYING is checked against its level-01 records under COMPAT as under STANDARD, whether it has RECORD CONTAINS integer-4 TO integer-5, whose integers the record descriptions decide and must match (pp. 187, 191), RECORD CONTAINS integer-3, or no RECORD clause: the guide names only the VARYING declaration as what COMPAT checks, and gives no case without one. A file with no level-01 record is checked against its record area alone",
1442 basis: Basis::Chosen,
1443 oracle: Oracle::EnterpriseCobol,
1444 },
1445 Assumption {
1446 id: VLR_RECORDS_CHECKED,
1447 claim: "VLR changes the file status alone: under either setting the READ succeeds and delivers the same bytes (Programming Guide SC27-8714-03, p. 422). A record shorter than the check's minimum fills the record area only as far as its length, leaving the rest as it was, which IBM calls undefined, and one longer than the record area is truncated to it (Language Reference SC27-8713-03, pp. 431, 434); the record area, the larger of the RECORD clause's maximum and the longest level-01 record, is taken as the 'maximum record definition size' (p. 431), so a 70-byte record of Table 52's file is delivered whole and READ INTO moves its 70 bytes (p. 188). The check covers records of variable length: a sequential file whose DD or FD is variable, and an indexed, relative or I-O sequential file held in that format. A fixed-length record keeps its status 04 for a data set that ends in a short record or a record longer than the area, whatever VLR says, and a line-sequential file or text DD, whose short lines IBM fills with spaces (Programming Guide p. 218), is not checked",
1448 basis: Basis::Chosen,
1449 oracle: Oracle::EnterpriseCobol,
1450 },
1451 Assumption {
1452 id: VSAM_OPEN_NEVER_VERIFIED,
1453 claim: "VSAMOPENFS is read from a card and kept in the load module's options, but no ironwork OPEN reaches the condition it changes: a VSAM OPEN that succeeds once the file's integrity is verified, status 97 under COMPAT and 00 under SUCC (Programming Guide SC27-8714-03, pp. 199, 424; Language Reference SC27-8713-03, p. 303). Neither manual says when the check is made; from memory, z/OS makes it when a data set was left open for output, typically by a run that abended, and OPEN's implicit VERIFY succeeds. ironwork closes every file a run unit leaves open when it ends, abend or not, and holds an indexed or relative file in memory from OPEN to CLOSE, writing it whole at CLOSE, so a data set is always as a CLOSE left it and nothing marks it as not closed. Modelling it needs a mark kept with the data set, set by OPEN OUTPUT, I-O or EXTEND and left by an abend, which rt::files's rule that a program reaches only the files the operator maps does not provide for, and a choice of whether status 97 takes the file's error path. Until then a successful VSAM OPEN is 00, or 05 for an optional file, under either setting",
1454 basis: Basis::Chosen,
1455 oracle: Oracle::EnterpriseCobol,
1456 },
1457 Assumption {
1458 id: DISPSIGN_SEPARATE,
1459 claim: "Under DISPSIGN(SEP) DISPLAY shows a signed binary, packed or overpunched zoned item as a leading + or - followed by the digits DISPSIGN(COMPAT) shows, unsigned (Programming Guide SC27-8714-03, pp. 362-363, Table 48), so a COMP-5 or TRUNC(BIN) binary item keeps its 5, 10, 19 or 20 digits (C14). The Language Reference shows the sign 'as if SIGN IS SEPARATE was specified' (SC27-8713-03, p. 334), which without LEADING would put it last; the guide's leading sign and its table are followed. IBM's table lists no other kind, and the rest is chosen: a zoned item with SIGN SEPARATE, whose sign is separate already, shows as stored, a trailing sign staying last; an unsigned item, and a value that is not an item (a literal, a function's result), is unchanged; a national decimal item, which ironwork does not lay out yet, would be unchanged too, IBM naming only binary, packed and zoned. An overpunched zoned item is read as its bytes, as COMPAT shows them, not as arithmetic reads it: the sign is - when the sign position's zone is X'B' or X'D' and + for any other zone, one that is no sign included, and the digits are the bytes with that zone made X'F', so invalid data is shown rather than ending the run",
1460 basis: Basis::Chosen,
1461 oracle: Oracle::EnterpriseCobol,
1462 },
1463 Assumption {
1464 id: LILIAN_INTEGER_DATES,
1465 claim: "Under INTDATE(LILIAN) every integer date a date function takes or returns is a Lilian day, 15 October 1582 being day 1 (Programming Guide SC27-8714-03, pp. 59, 375): INTEGER-OF-DATE, DATE-OF-INTEGER, DAY-OF-INTEGER, INTEGER-OF-DAY, FORMATTED-DATE, FORMATTED-DATETIME and INTEGER-OF-FORMATTED-DATE, which the Language Reference marks as INTDATE's (SC27-8713-03, pp. 551, 555, 571, 573, 583, 585, 587). The Language Reference gives the ranges under ANSI only: integer dates 1 to 3,067,671 and years 1601 to 9999 (p. 509). Under LILIAN the dates run, as Language Environment's date services take them, from 15 October 1582 to 31 December 9999, so integer dates from 1 to 3,074,324, standard dates from 15821015, Julian dates from 1582288, and a formatted date's year from 1582. TEST-DATE-YYYYMMDD, TEST-DAY-YYYYDDD, TEST-FORMATTED-DATETIME and SECONDS-FROM-FORMATTED-TIME carry no INTDATE note and keep years from 1601 (pp. 637, 653, 655, 657). FORMATTED-CURRENT-DATE takes and gives no integer date, so INTDATE does not touch it. COMBINED-DATETIME, the other function the note is on (p. 541), takes an integer date in the same range",
1466 basis: Basis::Chosen,
1467 oracle: Oracle::EnterpriseCobol,
1468 },
1469 Assumption {
1470 id: CEECBLDY_UNDER_LILIAN,
1471 claim: "Under INTDATE(LILIAN) a CALL whose target is the literal 'CEECBLDY' is diagnosed and calls CEEDAYS, which takes the same arguments and gives a Lilian day (Programming Guide SC27-8714-03, p. 375). The guide gives neither the message nor its severity: it is a warning (W, return code 4) in ironwork's words, since the program no longer calls what it names. A CALL of an identifier that holds 'CEECBLDY' is not converted, as the guide names the literal only, and ends the run as ironwork does not provide CEECBLDY; nor is a literal under INTDATE(ANSI)",
1472 basis: Basis::Chosen,
1473 oracle: Oracle::EnterpriseCobol,
1474 },
1475 Assumption {
1476 id: COMPLETE_SET_OF_QUALIFIERS,
1477 claim: "Under QUALIFY(EXTEND) a reference the standard's rules find ambiguous names the one candidate it gives a complete set of qualifiers, 'every level in the containing hierarchy of names' (Programming Guide SC27-8714-03, p. 400; 'every qualifier is specified', Language Reference SC27-8713-03, p. 68); with no such candidate, or two, it stays ambiguous. A data item's complete set is the name of every group that holds it, nearest first, up to its level-01 entry: a FILLER or unnamed group has no name to give and is no level of it, and a level-66 item's hierarchy is its record. A record's file-name may follow but is not needed, since the Language Reference lets a level-01 name that is the only one of its level be referenced under EXTEND (p. 67), which a record of an FD or SD could not be if its file-name were needed (p. 69); a LINAGE-COUNTER's complete set is its file-name or nothing. A condition-name's hierarchy starts with its conditional variable, which qualifies it (p. 70). The rule applies to RENAMES operands too, among the items of the record. A SUM operand naming a REPORT SECTION entry is found by its report-name and does not follow it",
1478 basis: Basis::Chosen,
1479 oracle: Oracle::EnterpriseCobol,
1480 },
1481 Assumption {
1482 id: INSPECT_FUNCTION_SUBJECT,
1483 claim: "INSPECT's identifier-1 can be an alphanumeric or national function-identifier in a TALLYING-only INSPECT (format 1): a function-identifier can be used wherever a sending data item of its category can, except as a receiving operand (Language Reference SC27-8713-03, p. 77), the INSPECT data flow evaluates a function-identifier once, as the first operation (p. 360), and TALLYING leaves identifier-1 unchanged. REPLACING (formats 2 and 3) and CONVERTING (format 4) copy their result back to identifier-1 (Table 40, p. 359), so a function there is a receiving operand and is refused when compiled (S); so is an integer or numeric function as identifier-1, since one can be used only where an arithmetic expression can (pp. 77, 505) and identifier-1 must be a DISPLAY, DISPLAY-1 or NATIONAL item or group (p. 355). MIN, MAX and CONTENT-OF, whose type follows their arguments, are not refused. The manuals give neither the message numbers nor their text: the messages are ironwork's. A function-identifier as identifier-3 to identifier-7 is read as any sending operand is",
1484 basis: Basis::Documented,
1485 oracle: Oracle::EnterpriseCobol,
1486 },
1487 Assumption {
1488 id: INSPECT_NATIONAL_FUNCTION_RESULT,
1489 claim: "INSPECT TALLYING of a national function result counts national characters (two-byte encoding units) and matches comparands and BEFORE or AFTER INITIAL delimiters only at character boundaries, and a figurative constant there is one national character (Language Reference SC27-8713-03, p. 355). An inspected item of usage NATIONAL is still inspected byte by byte, with figurative constants of one byte, as before this entry; that and the lowering, which refuses INSPECT of a function result, are left for later. No intrinsic function returns DBCS, so a DBCS function result does not arise",
1490 basis: Basis::Documented,
1491 oracle: Oracle::EnterpriseCobol,
1492 },
1493 Assumption {
1494 id: NATIONAL_CASE_AND_REVERSE,
1495 claim: "UPPER-CASE, LOWER-CASE and REVERSE of a national argument are national (Language Reference SC27-8713-03, pp. 597, 635, 671), as TRIM's already was (p. 665), and lowering types all four so. REVERSE keeps a surrogate pair as one character (p. 635). The case functions map each character by Unicode's case mapping where that gives one character and leave it alone otherwise, so the result keeps the argument's length as the manual requires; IBM names UnicodeData.txt, whose simple mappings differ from this in a few characters, such as U+0130, which is left as it is here",
1496 basis: Basis::Chosen,
1497 oracle: Oracle::EnterpriseCobol,
1498 },
1499 Assumption {
1500 id: INVDATA_CLEANSIGN,
1501 claim: "Under INVDATA(CLEANSIGN), the default once INVDATA is given and part of ZONEDATA(MIG) and ZONEDATA(NOPFD), a packed-decimal or zoned item whose sign half-byte is a digit, 0 to 9, is read with that half-byte made F, positive, rather than ending in a data exception: the compiler 'generates code to clean the sign nibble of USAGE DISPLAY and USAGE PACKED-DECIMAL data items on input to compare, add, subtract, multiply, and divide operations', and not for SIGN IS SEPARATE (Programming Guide SC27-8714-03, p. 378). Which valid sign the cleaning produces is not stated; F is chosen. It applies wherever the item is read as a number, a MOVE's sending item included, where IBM names only comparisons and arithmetic. Under NOCLEANSIGN and NOINVDATA such a sign is a data exception, as before",
1502 basis: Basis::Chosen,
1503 oracle: Oracle::EnterpriseCobol,
1504 },
1505 Assumption {
1506 id: INVDATA_ZONES_COMPARED,
1507 claim: "Under INVDATA(NOFORCENUMCMP), the default once INVDATA is given and part of ZONEDATA(NOPFD), an unsigned zoned integer compared with ZERO, or with an unsigned zoned integer of its own length, is compared as the bytes it holds, zones included, so an item holding X'F0F040F0' is not equal to ZERO: the compiler compares zoned data 'in the same manner as COBOL 4 or earlier versions', by an alphanumeric comparison where those considered the zone bits, and IBM's VALUE1 example gives false under INVDATA(NOFORCENUMCMP) at any OPT setting (Programming Guide SC27-8714-03, pp. 377-378). Which comparisons COBOL 4 made by their bytes is not listed; these two, where the bytes of equal values are always equal, are chosen. Other comparisons, and every comparison under FORCENUMCMP, ZONEDATA(MIG) and NOINVDATA, read the digits and ignore the zones; under NOINVDATA IBM's result depends on OPT, and OPT(0)'s is chosen",
1508 basis: Basis::Chosen,
1509 oracle: Oracle::EnterpriseCobol,
1510 },
1511];
1512
1513pub fn get(id: &str) -> &'static Assumption {
1514 ASSUMPTIONS.iter().find(|a| a.id == id).unwrap_or_else(|| panic!("no assumption {id}"))
1515}
1516
1517pub fn c_series() -> impl Iterator<Item = (usize, &'static Assumption)> {
1520 ASSUMPTIONS.iter().enumerate().map(|(i, a)| (i + 1, a))
1521}
1522
1523#[cfg(test)]
1524mod tests {
1525 use super::*;
1526
1527 #[test]
1528 fn ids_are_unique() {
1529 let mut ids: Vec<_> = ASSUMPTIONS.iter().map(|a| a.id).collect();
1530 ids.sort();
1531 ids.dedup();
1532 assert_eq!(ids.len(), ASSUMPTIONS.len());
1533 }
1534
1535 #[test]
1536 fn c_series_numbers_run_from_one_without_gaps() {
1537 let numbers: Vec<usize> = c_series().map(|(n, _)| n).collect();
1538 assert_eq!(numbers, (1..=ASSUMPTIONS.len()).collect::<Vec<_>>());
1539 }
1540
1541 #[test]
1542 fn c_series_keeps_every_id_once_and_leaves_the_register_alone() {
1543 let before: Vec<&str> = ASSUMPTIONS.iter().map(|a| a.id).collect();
1544 let seen: Vec<&str> = c_series().map(|(_, a)| a.id).collect();
1545 assert_eq!(seen, before);
1546 assert_eq!(ASSUMPTIONS.iter().map(|a| a.id).collect::<Vec<_>>(), before);
1547 }
1548}