Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » Epsilon » Import of EOL libraries
Import of EOL libraries [message #649731] Thu, 20 January 2011 13:29 Go to next message
Konrad Schwarz is currently offline Konrad SchwarzFriend
Messages: 5
Registered: January 2011
Junior Member
Hi,

I was hoping to access a variable defined in a EOL module
"parameters.eol" in a second file "validate.evl" like
this:

/* parameters.eol */
var some_constant: Real = 0.001;

/* validate.evl */
import "parameters.eol";

pre {
some_constant.print();
}

But it does appear to work; some_constant is unknown.

What am I doing wrong?
Re: Import of EOL libraries [message #649733 is a reply to message #649731] Thu, 20 January 2011 13:38 Go to previous messageGo to next message
Konrad Schwarz is currently offline Konrad SchwarzFriend
Messages: 5
Registered: January 2011
Junior Member
Careful reading of 3.1 indicates that only EOL operations are imported--is this correct?

So constants should implemented as 0-arity operations, right?
Re: Import of EOL libraries [message #649735 is a reply to message #649733] Thu, 20 January 2011 13:41 Go to previous message
Dimitris Kolovos is currently offline Dimitris KolovosFriend
Messages: 2162
Registered: July 2009
Location: York, UK
Senior Member

Hi Konrad,

That is correct.

Cheers,
Dimitris
Re: Import of EOL libraries [message #649736 is a reply to message #649731] Thu, 20 January 2011 13:32 Go to previous message
Dimitrios Kolovos is currently offline Dimitrios KolovosFriend
Messages: 1776
Registered: July 2009
Senior Member
Hi Konrad,

When you import an EOL module, only the operations defined in it are
imported.

Cheers,
Dimitris

On 20/01/2011 13:30, Konrad Schwarz wrote:
> Hi,
>
> I was hoping to access a variable defined in a EOL module
> "parameters.eol" in a second file "validate.evl" like
> this:
>
> /* parameters.eol */
> var some_constant: Real = 0.001;
>
> /* validate.evl */
> import "parameters.eol";
>
> pre {
> some_constant.print();
> }
>
> But it does appear to work; some_constant is unknown.
>
> What am I doing wrong?
Previous Topic:Errata in EpsilonBook.pdf, 29-Nov-2010
Next Topic:Backquotes/Backticks
Goto Forum:
  


Current Time: Thu Apr 18 04:44:48 GMT 2024

Powered by FUDForum. Page generated in 0.01756 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top