Search the web
Sign In
New User? Sign Up
claireprogramminglanguage · Claire Programming Language - A place to discuss about the CLAIRE language
? Already a member? Sign in to Yahoo!

Yahoo! Groups Tips

Did you know...
Real people. Real stories. See how Yahoo! Groups impacts members worldwide.

Best of Y! Groups

   Check them out and nominate your group.
Having problems with message search? Fill out this form to ensure your group is one of the first to be migrated to the new message search system.

Messages

  Messages Help
Advanced
how to define/compile a module?   Message List  
Reply | Forward Message #588 of 1160 |
Re: how to define/compile a module?

Hi,

Just define your module in the init.cl file:
testmod :: module( part_of = claire, made_of list("test") )

And remove the begin/end lines, these instruction are only useful
when you want to change the current namespace (usually in
interpreted mode)

Note also that no method will be called when launching your compiled
module. You will have to call main() from the "testmod>" prompt that
will appear.

Thierry

--- In claireprogramminglanguage@yahoogroups.com, igouy2
<no_reply@y...> wrote:
> Please help explain what things I'm doing wrong.
> (using unchanged init.cl from distribution release-3-3-28.zip
>
> file testmod.cl
> test :: module( part_of = claire, made_of list("test") )
>
> file test.cl
> begin(test)
> main() -> printf("hello world!")
> end(test)
>
> I:\pls\Claire>claire -cm testmod
> -- CLAIRE run-time library v 3.3.28 [os: ntv, C++:MS VC++ ] --
> this is a init file for cclaire for OS: ntv -------------------
> init.cl is ok -------------------------------------------------
> **** An error has occurred.
> testmod is not a module




Wed Oct 8, 2003 6:02 am

thbenoist
Offline Offline

Forward
Message #588 of 1160 |
Expand Messages Author Sort by Date

Please help explain what things I'm doing wrong. (using unchanged init.cl from distribution release-3-3-28.zip file testmod.cl test :: module( part_of =...
igouy2
Offline
Oct 8, 2003
12:29 am

Hi, Just define your module in the init.cl file: testmod :: module( part_of = claire, made_of list("test") ) And remove the begin/end lines, these instruction...
thbenoist
Offline
Oct 8, 2003
6:03 am

... It didn't seem to like that? I:\pls\Claire>claire -cm testmod -- CLAIRE run-time library v 3.3.28 [os: ntv, C++:MS VC++ ] -- this is a init file for...
igouy2
Offline
Oct 8, 2003
2:59 pm

testmod :: module( part_of = claire, made_of = list<string>("test") )...
thbenoist
Offline
Oct 8, 2003
3:04 pm

... ("test") ) Thanks that's let me take a step forward. I:\pls\Claire>claire -cm testmod -- CLAIRE run-time library v 3.3.28 [os: ntv, C++:MS VC++ ] -- this...
igouy2
Offline
Oct 8, 2003
3:32 pm

Hi, Think to specify the source module's attribute : testmod :: module( part_of = claire, source = "." , made_of = list<string>("test") ) The default value of...
nmuseux
Offline
Oct 8, 2003
3:41 pm

... Ah! I see. ... Fixed with: testmod :: module( part_of = claire, source = ".", made_of = list<string>("test"), uses = list(claire) ) Two questions: 1) ...
igouy2
Offline
Oct 8, 2003
4:11 pm

OK, testmod :: module( part_of = claire, source = ".",made_of = list<string>("test") ) or maybe setting source to your full path: "c:\\myDirectory\\sources"...
thbenoist
Offline
Oct 9, 2003
6:04 am
Advanced

Copyright © 2009 Yahoo! Inc. All rights reserved.
Privacy Policy - Terms of Service - Guidelines - Help