step-examples/12-1c-syntax/Ls013.stp
Sources
- T026, N054
Description
Two distinct empty-list forms exist: a zero-attribute entity `#1=ABSTRACT_PT()` and an empty typed parameter `IFCMEASURE(())`. Lexical layer accepts `#1=PRODUCT();` but the schema expects N attributes.
Reproducer recipe
`#1=BOUNDED_SURFACE();` versus `#2=IFCMEASURE(IFCLENGTHMEASURE());`
Expected kernel behavior
Lex layer accepts `()` as zero-argument record; semantic layer must reject if schema requires N>0 with "0 attributes, expected N". Reject zero-argument typed parameters unless the schema explicitly permits.
Notes
**See also**: Ad015. Synonyms: "empty parameter list versus null", "PRODUCT() with no attributes", "zero-attribute STEP entity", "schema expects attributes but none provided", "empty parens for typed parameter".
Expected validation
occt=empty/empty gmsh=empty ifc=schema_n/a
Byte assertions
contains(b'PRODUCT();') or contains(b'IFCMEASURE(IFCLENGTHMEASURE())')matches(rb'PRODUCT\(\s*\)') or contains(b'IFCMEASURE(')
Tier-3 assertions
shape_null == True
Cross-references
Live oracle output
No live oracle data — run _run_corpus to populate.
Fixture content
Show fixture bytes
1/* Ls013 - Empty parameter list () versus typed empty parameter 2 ---------------------------------------------------------------------- 3 Catalog section : §12.1c parameter syntax 4 Sources : T026, N054 5 See also : Ad015 6 ---------------------------------------------------------------------- 7 Defect 8 Two distinct empty-list forms exist: 9 - a zero-attribute entity record : #1=BOUNDED_SURFACE(); 10 - an empty typed parameter : IFCMEASURE(()) 11 The lexical layer accepts #1=PRODUCT();, but the schema expects N 12 attributes, so the semantic layer must reject. Generators emit zero- 13 argument forms when default-construction logic produces empty slots. 14 Expected behavior 15 Lex layer accepts () as zero-argument record. Semantic layer must 16 reject if the schema requires N>0 attributes with the diagnostic 17 "0 attributes, expected N". Reject zero-argument typed parameters 18 unless the schema explicitly permits them. 19 ---------------------------------------------------------------------- 20*/ 21ISO-10303-21; 22HEADER; 23FILE_DESCRIPTION(('Ls013 - empty parameter list versus typed empty parameter'),'2;1'); 24FILE_NAME('Ls013.stp','2026-04-26T00:00:00',('auto-generated'),(''), 25 'auto-generated','',''); 26FILE_SCHEMA(('AUTOMOTIVE_DESIGN { 1 0 10303 214 3 1 1 }')); 27ENDSEC; 28DATA; 29/* Defect: zero-argument entity record where schema requires N attributes */ 30#10=BOUNDED_SURFACE(); 31/* Defect: empty typed parameter where the schema expects a value */ 32#20=IFCMEASURE(IFCLENGTHMEASURE()); 33/* Defect: zero-argument PRODUCT (schema-illegal) */ 34#30=PRODUCT(); 35/* Defect: nested empty typed parameter inside an aggregate */ 36#40=PROPERTY_LIST((IFCMEASURE(IFCLENGTHMEASURE()))); 37ENDSEC; 38END-ISO-10303-21;