Ad049 — Real literal lacks decimal point or has Fortran `D` exponent

§12.11 (sub-class: malformed-numeric / encoding)

P2 — spec deviation (no data loss)

spec-violation adversarial

Sources

Description

Per spec, REAL must have `.`; exponent is uppercase `E`; integers may not have leading `.`. Generators emit `1`, `.5`, `1e+18`, `1.0D5`, `+1.0`, `1_000.0`, `1,5` (locale comma), `0x10` (hex). Stepcode silently coerces INTEGER→REAL via `istringstream`, hiding unit-corruption bugs.

Reproducer recipe

`#1=IFCDIRECTION((1,0,0));`, `#1=IFCDIRECTION((1.0D5,0.,0.));`, `#1=IFCREAL(1_000.0);`.

Expected kernel behavior

Strict spec lex rejects with diagnostic; tolerant mode warns and accepts (coerces). Must not silently accept malformed reals.

Notes

**See also**: Ls001.

Expected validation

occt=empty/empty gmsh=empty ifc=schema_n/a

Byte assertions

Tier-3 assertions

Cross-references

Ls001

Live oracle output

No live oracle data — run _run_corpus to populate.

Fixture content

Show fixture bytes (with defect highlighting)
1ISO-10303-21;
2/* Ad049: malformed REAL literals: '1.0D5' (Fortran D-exponent), '1_000.0' (underscore separator), '1.5e+02' (lowercase e), '(1,0,0)' (INTEGER coordinates without decimal point); Stepcode silently coerces INTEGER→REAL hiding unit-corruption bugs; GEOMETRIC_CURVE_SET IS model entity — OCC yields empty */
3HEADER;
4FILE_DESCRIPTION(('Ad049'),'2;1');
5FILE_NAME('Ad049.stp','2026-06-17T00:00:00',(''),(''),'cad-research-suite','','');
6FILE_SCHEMA(('AUTOMOTIVE_DESIGN { 1 0 10303 214 3 1 1 }'));
7ENDSEC;
8DATA;
9#1=CARTESIAN_POINT('',(0.0,0.0,0.0));
10#2=GEOMETRIC_CURVE_SET('',(#1));
11#3=DIRECTION('integer_coords',(1,0,0));
12#4=DIRECTION('fortran_d_exp',(1.0D5,0.,0.));
13#5=DIRECTION('underscore_sep',(1_000.0,0.0,0.0));
14#6=DIRECTION('lowercase_e_exp',(1.5e+02,0.0,0.0));
15#7=CARTESIAN_POINT('int_point',(0,0,0));
16ENDSEC;
17END-ISO-10303-21;