- Index
- » Usage and Applications
- » OpenModelica Usage and Applications
- » The identifier at start and end are...
The identifier at start and end are different
The identifier at start and end are different
Hi,
I run OpenModelica 1.13.0 still.
When I start OMEdit and do Open Modelica/Library Files(s) and choose one file - then I get the error message
Parse error: The identifier at start and end are different
I get it repeatedly of several different files that I can without problem run independently in JModelica.
Still older files I have moved from JModelica to OpenModelica works as usual.
(And I use the same editor TexMate - out in the Mac - while OM is a VM with Linux from downloaded from your homepage)
Any idea of what the problem can be?
Jan Peter
Re: The identifier at start and end are different
Is it possible to share the model?
best regards
- Arinomo23
- 120 Posts
Re: The identifier at start and end are different
It seems like somewhere in your code you have,
Code:
model A
end B;
In such cases you have the error The identifier at start and end are different.
Usually you end up with such errors when you manually try to edit the models.
Adeel.
- adeas
- 454 Posts
Re: The identifier at start and end are different
Right click and choose "Expand All".
Adeel.
- adeas
- 454 Posts
Re: The identifier at start and end are different
In what context should I right click and "Expand all"?
I work in Linux and use Mouspad - there is not that option when I right click.
Out in the file system I can choose the (closed) file and right click but no such option as "Expand all" there either.
Jan Peter
Re: The identifier at start and end are different
I think we both are on different tracks. I am a bit lost actually.
Just to understand your problem again. You are having problems loading your models in OMEdit. So basically you just get the error and nothing is loaded, right? If yes then usually such error also points you to the exact file and line.
If you can't share your model then at least try to make a minimal model that depicts the problem. Unfortunately its very hard for us to solve the issue without the source code.
Adeel.
- adeas
- 454 Posts
Re: The identifier at start and end are different
I have cut down the model now and it still has the same problem.
When I load I just get a read error line as described above and nothing is really loaded.
So it is some very, very basic problem.
The problem has come this week.
But I have also managed this week to do very small models that do work.
Enclosed the file.
Jan Peter
Re: The identifier at start and end are different
Hi,
on line 26 to 30
Code:
connector LiquidCon
replaceable package medium=Medium;
medium.Concentration c "Concentration";
flow Real F (unit="L/h") "Flow rate";
end LiquiCon;
you forget the D....
- Arinomo23
- 120 Posts
Re: The identifier at start and end are different
Great!
You saved my day, if not the whole week.
Jan Peter
PS It is somewhat interesting how "forgiving" the JModelica compiler is compared to the OpenModelica compiler.
PS2. And I take away the file when now the problem is solved.
Re: The identifier at start and end are different
NP! And your welcome...
I have not worked with JModelica, so i dont know how it works. OMEdit check your syntax and i think its a great thing. If you use OM Connection Editor and a syntax error comes up, it usually tell you at which line the error occur.
Maybe JModelica only check the keyword "end" after you declare a model or connection w/o checking the identifier. But I think i doesn't make any sense.
- Arinomo23
- 120 Posts
- Index
- » Usage and Applications
- » OpenModelica Usage and Applications
- » The identifier at start and end are...