staload, paths, and infix operators

55 views
Skip to first unread message

M88

unread,
Apr 2, 2018, 6:32:22 PM4/2/18
to ats-lang-users
I have two questions...

The first is that path resolution seems to have changed from ATS2 0.3.7 and 0.3.9.
I used to be able to write 'staload "sats/foo.sats"' in "dats/foo.dats"
and running patscc from the project root would find the file.  Now it seems I need to
write 'staload "./../sats/foo.sats"'.   Did this actually change, or am I missing something?
Strangely, -IATS with the project root doesn't seem to be working for me either -- at least with patscc. 
I've tried both relative and absolute paths.

The second is that infix operators consisting of non-alpha symbols (eg, '|>') are not imported
from .sats files during staload.  I can declare them in .dats files.  Would I need to
#include these if I chose to share them between files?

gmhwxi

unread,
Apr 3, 2018, 2:20:46 PM4/3/18
to ats-lang-users

>>Did this actually change, ...

Yes, it did. I took a look at the source code of ATS-Postiats.
The option -IATS seems to have been disabled. I will try to find
more on this.

>>Would I need to#include these if I chose to share them between files?

My own practice is to put infix declarations in a HATS file and
then include the file in places where the declarations are needed.

gmhwxi

unread,
Apr 5, 2018, 1:08:43 AM4/5/18
to ats-lang-users

I could not figure out why the support for -IATS was
disabled. I have just re-enable it. This change should go
into the next release.
Reply all
Reply to author
Forward
0 new messages