Version 8.0 improves the built-in state machine editor, the Rust back end and the SysML v2 code generator. New in this version:
- Built-in state machine editor: the editor now lays out and draws its diagrams itself. GraphViz no longer has to be installed — see Built-in Visual Editor.
- Built-in editor, C and C++ code: events can carry data. In the editor you declare the fields an event carries (name and type); the generated C and C++ code passes them along with the event, so guards and actions can read them — see C and C++.
- Built-in editor: a state copied with Copy State to Clipboard can now be pasted into a region, including a state that has regions of its own — see Editor Part II.
- Simulation in the built-in editor: when the machine starts in a choice, you pick the branch it takes. The event coverage counts the transitions taken so far — see Editor Part III.
- Built-in editor: the selected target language and the detail level shown for states and transitions are kept between sessions. The editor has a new application icon.
- Rust code: the generated code passes
rustc, Clippy andrustfmtwithout warnings. The handler functions now change the machine in place and return an outcome value instead of a number; code that calls the machine may need small changes — see Rust. - SysML v2 library: the library packages (
ScalarValues,ISQ,SIand others) are no longer built intocodegen.jar. They are delivered as files in the foldersysml_lib, which must stay next tocodegen.jar.W3177warns when a package cannot be found. A project can use its own version of a package by placing the file next to its model. - SysML v2 parser: the parts of a declaration (type, multiplicity, redefinition, value and so on) may now appear in any order the standard allows, and more of the standard is accepted overall.
- SysML v2 parameters: binding follows the standard more closely. A parameter listed
without a value (
in x;) no longer takes the caller’s feature of the same name; writebind a.x = x;instead.W3179warns where a parameter would be bound differently by name than by position. - SysML v2 command line:
-dprints the model as the generator has read it: for every feature its type, where its value comes from and what it redefines. This helps to find modelling mistakes. - SysML v2 code generation: many bug fixes in the C++ and Python back ends.