[erlang-questions] Why do we need modules at all?

Edmond Begumisa <>
Wed May 25 09:18:09 CEST 2011


That's precisely what I was suggesting in suggestion 2...

> ... 2. Expanding on this: letting the programmer centralise the possible  
> locations ...

That "erlang.manfest" contains is a prop_list that maps "erlang://" URIs  
to actual locations. Sorry it wasn't clear enough.

- Edmond -


On Wed, 25 May 2011 17:07:04 +1000, Richard O'Keefe <>  
wrote:

>
> On 25/05/2011, at 3:34 PM, Edmond Begumisa wrote:
>
>> Hello Joe,
>>
>> I've personally wanted an easy way to load modules from different  
>> places.
>>
>> If you started with making modules easy to load from different places,  
>> then later provide support for functions, I imagine this would be  
>> easier to implement immediately and easier for people to make use of  
>> immediately ... where "people" refers to me :)
>>
>> I've got two suggestions (mostly inspired by the Mozilla Framework)...
>>
>> 1. How about letting the programmer choose where the functions come  
>> from (kv store, fs, web-server, etc)...
>>
>> For instance, a module could start...
>>
>> -import(["file://misc/collect_int", "http://erlang.org/lists/*",  
>> "mnesia://db1/misc/merge_kv"]).
>
> Why does this have to be done inside the module?
> Why cannot the mapping from module names to sources
> be *outside*, like an SGML (or XML) catalogue,
> or a .lace file?
>
>


-- 
Using Opera's revolutionary e-mail client: http://www.opera.com/mail/



More information about the erlang-questions mailing list