Re: Namespaces (was Re: GUI Library Task Force)

2001-10-14 Thread John Hughes




___
Haskell mailing list
[EMAIL PROTECTED]
http://www.haskell.org/mailman/listinfo/haskell



Re: Namespaces (was Re: GUI Library Task Force)

2001-10-11 Thread Fergus Henderson

On 10-Oct-2001, Hal Daume III <[EMAIL PROTECTED]> wrote:
> So, barring this, I'm curious how other people handle this issue.
> 
> I have multiple projects.  Call them A, B, C.  They are in directories:
>   ~/projects/A
>   ~/projects/B
>   ~/projects/C
> repsectively.
> 
> Say I'm creating a new project, D, in ~/projects/D that uses code that
> I've written in packages A, B and C.  Now, as far as I can see, I have
> two options:
> 
>  1) Copy all the .(l)hs files from /A, /B, and /C to /D that I need to
> import
>  2) Include projects/A, projects/B and projects/C in my search path for
> ghc(i)
> 
> I hate both of these options.  1 is terrible because I have multiple
> copies of the same code lying around and, if I make changes to one, I
> have to remember to copy the changes over to the others.  2 is a big
> nuisance, especially since ghc (seems to) lack an environment variable
> that it looks at to get command line options every time it runs
> (HUGSFLAGS, I think it was for Hugs).

Well, I wouldn't be invoking ghc manually anyway; I'd put the commands
to invoke ghc in a script or, more likely, in a Makefile.

-- 
Fergus Henderson <[EMAIL PROTECTED]>  | "... it seems to me that 15 years of
The University of Melbourne | email is plenty for one lifetime."
WWW:   | -- Prof. Donald E. Knuth

___
Haskell mailing list
[EMAIL PROTECTED]
http://www.haskell.org/mailman/listinfo/haskell



Re: Namespaces (was Re: GUI Library Task Force)

2001-10-10 Thread John Meacham

On Wed, Oct 10, 2001 at 03:29:03PM -0400, Hal Daume III wrote:
> So, barring this, I'm curious how other people handle this issue.
> 
> I have multiple projects.  Call them A, B, C.  They are in directories:
>   ~/projects/A
>   ~/projects/B
>   ~/projects/C
> repsectively.
> 
> Say I'm creating a new project, D, in ~/projects/D that uses code that
> I've written in packages A, B and C.  Now, as far as I can see, I have
> two options:
> 
>  1) Copy all the .(l)hs files from /A, /B, and /C to /D that I need to
> import
>  2) Include projects/A, projects/B and projects/C in my search path for
> ghc(i)
> 
> I hate both of these options.  1 is terrible because I have multiple
> copies of the same code lying around and, if I make changes to one, I
> have to remember to copy the changes over to the others.  2 is a big
> nuisance, especially since ghc (seems to) lack an environment variable
> that it looks at to get command line options every time it runs
> (HUGSFLAGS, I think it was for Hugs).
> 
> So is there a third option that I'm missing?  How do other people handle
> this issue?


Personally I use symbolic links, either to the file or to the whole
directory. This is not ideal since i cannot easily see which projects
depend on a given file but at least all the dependencies of a project
are visible under one directory without having to reverse-engineer the
makefile.
John

-- 
---
John Meacham - California Institute of Technology, Alum. - [EMAIL PROTECTED]
---

___
Haskell mailing list
[EMAIL PROTECTED]
http://www.haskell.org/mailman/listinfo/haskell



Re: Namespaces (was Re: GUI Library Task Force)

2001-10-10 Thread Hal Daume III

So, barring this, I'm curious how other people handle this issue.

I have multiple projects.  Call them A, B, C.  They are in directories:
  ~/projects/A
  ~/projects/B
  ~/projects/C
repsectively.

Say I'm creating a new project, D, in ~/projects/D that uses code that
I've written in packages A, B and C.  Now, as far as I can see, I have
two options:

 1) Copy all the .(l)hs files from /A, /B, and /C to /D that I need to
import
 2) Include projects/A, projects/B and projects/C in my search path for
ghc(i)

I hate both of these options.  1 is terrible because I have multiple
copies of the same code lying around and, if I make changes to one, I
have to remember to copy the changes over to the others.  2 is a big
nuisance, especially since ghc (seems to) lack an environment variable
that it looks at to get command line options every time it runs
(HUGSFLAGS, I think it was for Hugs).

So is there a third option that I'm missing?  How do other people handle
this issue?

 - Hal

On Wed, 10 Oct 2001, Mark Carroll wrote:

> On Wed, 10 Oct 2001, Hal Daume III wrote:
> (snip)
> > least) is that the Java compiler knows how to interpret the "."s and
> > will use them to navigate directory structure.
> (snip)
>
> Yes, that's certainly an interesting idea. I'd like to fall short of
> mandating anything about location of source files in any language spec,
> though: although I can see that people probably find Java's imposed
> semantics useful, personally I find them irritating and wouldn't want to
> shackle everyone to them.
>
> -- Mark
>
>
> ___
> Haskell mailing list
> [EMAIL PROTECTED]
> http://www.haskell.org/mailman/listinfo/haskell
>

~~
Hal Daume III  [EMAIL PROTECTED]
"arrest this man, he talks in maths"   www.andrew.cmu.edu/~hcd
~~


___
Haskell mailing list
[EMAIL PROTECTED]
http://www.haskell.org/mailman/listinfo/haskell



Re: Namespaces (was Re: GUI Library Task Force)

2001-10-10 Thread Mark Carroll

On Wed, 10 Oct 2001, Hal Daume III wrote:
(snip)
> least) is that the Java compiler knows how to interpret the "."s and
> will use them to navigate directory structure.
(snip)

Yes, that's certainly an interesting idea. I'd like to fall short of
mandating anything about location of source files in any language spec,
though: although I can see that people probably find Java's imposed
semantics useful, personally I find them irritating and wouldn't want to
shackle everyone to them.

-- Mark


___
Haskell mailing list
[EMAIL PROTECTED]
http://www.haskell.org/mailman/listinfo/haskell



Namespaces (was Re: GUI Library Task Force)

2001-10-10 Thread Hal Daume III

I think one important aspect of Java's java.foo.bar style has been
overlooked: the semantics.  sure, syntactivally, java.foo.bar and
java_foo_bar; they're basically the same.  the big issue (to me, at
least) is that the Java compiler knows how to interpret the "."s and
will use them to navigate directory structure.

This ability is one of the little things in Haskell that could be
"fixed" fairly easily (I can't see that it would break any existing
programs) and would make my Haskelling experience MUCH more plesant.

 - Hal

On Wed, 26 Sep 2001, Lennart Augustsson wrote:

> "S. Alexander Jacobson" wrote:
>
> > Great.  So that is something that goes into some library conventions
> > document.  Java has a convention that libraries should have reverse domain
> > name structure.  Is that how we should use _?
>
> Yes, I think that could be the way.  And in addition there should be some
> language libraries (just like Java has java.*).
>
> -- Lennart
>
>
>
> ___
> Haskell mailing list
> [EMAIL PROTECTED]
> http://www.haskell.org/mailman/listinfo/haskell
>

~~
Hal Daume III  [EMAIL PROTECTED]
"arrest this man, he talks in maths"   www.andrew.cmu.edu/~hcd
~~


___
Haskell mailing list
[EMAIL PROTECTED]
http://www.haskell.org/mailman/listinfo/haskell