Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Test for binding/variable multi-source type error
- Loading branch information
1 parent
7e6f4d2
commit ad316fd
Showing
3 changed files
with
37 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
// name: ArrayModTypeError2 | ||
// keywords: modification array type | ||
// status: incorrect | ||
// | ||
|
||
model ArrayModTypeError | ||
Real y[2, 2]; | ||
equation | ||
der(y) = -y; | ||
end ArrayModTypeError; | ||
|
||
model ArrayModTypeError2 | ||
ArrayModTypeError arr(y(start = {{1, 2, 3}, {4, 5, 6}})); | ||
end ArrayModTypeError2; | ||
|
||
// Result: | ||
// Error processing file: ArrayModTypeError2.mo | ||
// [flattening/modelica/modification/ArrayModTypeError2.mo:13:27-13:57:writable] Notification: From here: | ||
// [flattening/modelica/modification/ArrayModTypeError2.mo:7:3-7:15:writable] Error: Array dimension mismatch, expression {4, 5, 6} has type Integer[3], expected array dimensions [2]. | ||
// Error: Error occurred while flattening model ArrayModTypeError2 | ||
// | ||
// # Error encountered! Exiting... | ||
// # Please check the error message and the flags. | ||
// | ||
// Execution failed! | ||
// endResult |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters