openbim-step 0.6.0
Changed
- Breaking:
EntityDef::supertype: Option<String>is replaced by
EntityDef::supertypes: Vec<String>, every direct supertype in
SUBTYPE OForder.EntityDef::supertype()returns the first, for
single-inheritance callers;with_supertypenow appends. Migration:
def.supertype.clone()becomesdef.supertype().map(str::to_owned). - Breaking:
EntityDefgained publicsupertypesandredeclared
fields, so struct-literal construction must add them.
cargo semver-checks against the published 0.5.1 reports exactly these two
breaks (struct_pub_field_missing, constructible_struct_adds_field) and
182 of 184 checks passing.
Added
EntityDef::redeclared,EntityDef::is_redeclared, andRedeclaration:
explicitSELF\X.a : T;redeclarations, kept apart fromattributes.SchemaGraph::direct_supertypes.
Fixed
- Multiple inheritance (#2). Every supertype after the first was dropped, so
SchemaGraph::attributesomitted inherited slots andis_amissed
ancestors. Layouts now follow ISO 10303-21:2016 §12.2.5.2: supertypes in
SUBTYPE OForder, higher supertypes first, and a supertype reached twice
through a diamond counted once.supertypes,subtypes, andis_awalk
every parent. AP242 has 248 multi-parent entities; IFC has none. - Explicit redeclarations no longer add a phantom positional slot (#3).
SELF\styled_item.item : plane_or_planar_box;was parsed as a new
attribute namedSELF\styled_item.item; ISO 10303-21:2016 §12.2.8 says it
has no effect on the encoding. This affected 481 AP242 entities, including
advanced_face. - A
\S\page escape followed by an apostrophe no longer ends the string
literal.\S\takes exactly one followingLATIN_CODEPOINT, which includes
the apostrophe (ISO 10303-21:2016 §5.2, §6.4.3.1), so'Stra\S\'e'is one
string decoding toStra§e. Previously it failed to lex. The recovery
resynchronizer applies the same rule, and\\is consumed as one escaped
backslash in both so its second byte cannot open a page escape (#1).
Checked against OCCT's per-entity parameter counts (CheckNbParams in its
generated RWStep* readers): AP242 mismatches fell from 107 to 2, AP203e2
from 24 to 1. The residuals are OCCT departing from Part 21 (common_datum
diamond read twice; characterized_representation dropping derived *
slots) and are pinned in tests/schema_graph.rs.
Full changelog: v0.5.1...v0.6.0
crates.io: https://crates.io/crates/openbim-step/0.6.0