module A type type1 foo(a::type1) end module B type type2 foo(a::type2) end
if you do that and then try
WARNING: both B and A export “foo”; uses of it in module Main must be qualified
ERROR: LoadError: UndefVarError: foo not defined
The obvious way around this is to put those definitions in a single module and export foo, however the goal is to keep all the functions segregated by type.
i’ve looked through the methods and modules section of the docs and haven’t seen a way around this.
I even poked around in the julia source code, and it looks like the solution is, in fact, to make all the definitions in one file and then export from there, i.e. the modules are organized by method as opposed to type.
Just making sure before I start organizing my source code.