Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork238
fix: FMI varname parse bug #3934#3935
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
base:master
Are you sure you want to change the base?
fix: FMI varname parse bug #3934#3935
Conversation
8c1b37a to559150bCompareChrisRackauckas commentedSep 18, 2025
This reformats the whole repo. Right now the formatter is broken so don't worry about it. Revert that. |
EduardoMartinezLopez commentedSep 18, 2025
@ChrisRackauckas Thanks! I reverted the formatter commit. |
EduardoMartinezLopez commentedSep 18, 2025 • edited
Loading Uh oh!
There was an error while loading.Please reload this page.
edited
Uh oh!
There was an error while loading.Please reload this page.
@ChrisRackauckas Question for you. It seems like the existing code in MTKFMIExt > parseFMIVariableName() mutates the "name" input variable. Is that OK? My understanding is that this is considered bad practice as Julia passes by reference. Also if it the input is mutated, the convention is to add ! to the function name, right? |
ChrisRackauckas commentedSep 18, 2025
I don't see where it mutates it. It creates a view but then creates a Symbol, which is effectively an interned string. But I don't see it actually mutating the string? Put to the line that you're worried about. Though it probably shouldn't create the symbol there for performance reasons on large models, but that's a minor detail. |
EduardoMartinezLopez commentedSep 19, 2025
Ok, I was concerned about the |
ChrisRackauckas commentedSep 19, 2025
that just makes |
AayushSabharwal commentedSep 19, 2025
The test doesn't work |
EduardoMartinezLopez commentedSep 19, 2025
@AayushSabharwal what is the problem with the test on your end? |
c018d3b to3ce579aCompare
Uh oh!
There was an error while loading.Please reload this page.
This PRFixes#3934
Checklist
contributor guidelines, in particular theSciML Style Guide and
COLPRAC.
Additional context
Add any other context about the problem here.