0

If I have functions in two packages that have parameters such as length_, width_ and height_; is there any way to have both packages loaded without generating messages such as "Symbol length appears in multiple contexts"?

Is there any way to make function parameters local instead of global?

Do all function names and parameters need to be unique across packages?

kglr
  • 394,356
  • 18
  • 477
  • 896
Doug Kimzey
  • 2,279
  • 1
  • 14
  • 21
  • Please see the linked question on how to construct packages. These name clashes will not happen when the standard package structure is followed. – Szabolcs Nov 13 '14 at 19:05
  • Wait a second... I've never heard of function parameter names colliding, in any programming language. Is that something that actually happens in Mathematica packages?? –  Nov 13 '14 at 19:08
  • 1
    @RahulNarain This happens when one does not use Private` sub-context for implementation code. Those symbols (local variables) are then generated in public context and exported as well, when the context is loaded. – Leonid Shifrin Nov 13 '14 at 19:45

0 Answers0