May 07, 2007 Re: DSSS and Rebuild 0.64 released. | ||||
---|---|---|---|---|
| ||||
Posted in reply to David Ferenczi | David Ferenczi wrote:
> Hi Gregor,
>
> I have some trouble with the doc generation again.
>
> The tip you gave me last time
>
> "rebuild -o- -candydoc -Ddmylib_doc mylib/*.d"
>
> worked smoothly, but with this new release I got the message:
>
> "WARNING: Module application.d does not have a module declaration. This can
> cause problems with rebuild's -oq option. If an error occurs, fix this
> first."
>
> Ok, I didn't have module declarations in my sources so I made it up.
>
> With having the module declaration in my sources the documentation
> generation silently dies. Simply nothing happens. Could you please take a
> look at?
>
> Many thanks,
> David
>
>
>
Actually, the bug is that it's only generating documentation if you're making output files (i.e. not using -o-). The quickfix is to use -odgarbage_objs. Will fix the underlying bug by 0.65.
- Gregor Richards
|
May 07, 2007 Re: DSSS and Rebuild 0.64 released. | ||||
---|---|---|---|---|
| ||||
Posted in reply to Gregor Richards | Gregor Richards wrote:
> David Ferenczi wrote:
>> Hi Gregor,
>>
>> I have some trouble with the doc generation again.
>>
>> The tip you gave me last time
>>
>> "rebuild -o- -candydoc -Ddmylib_doc mylib/*.d"
>>
>> worked smoothly, but with this new release I got the message:
>>
>> "WARNING: Module application.d does not have a module declaration. This can cause problems with rebuild's -oq option. If an error occurs, fix this first."
>>
>> Ok, I didn't have module declarations in my sources so I made it up.
>>
>> With having the module declaration in my sources the documentation generation silently dies. Simply nothing happens. Could you please take a look at?
>>
>> Many thanks,
>> David
>>
>>
>>
>
> Actually, the bug is that it's only generating documentation if you're making output files (i.e. not using -o-). The quickfix is to use -odgarbage_objs. Will fix the underlying bug by 0.65.
>
> - Gregor Richards
That's what I call a response time! Many thanks! :-)
Just from curiousity: what is the reason for compulsory module names?
Regards,
David
|
May 07, 2007 Re: DSSS and Rebuild 0.64 released. | ||||
---|---|---|---|---|
| ||||
Posted in reply to David Ferenczi | David Ferenczi wrote:
> Gregor Richards wrote:
>
>> David Ferenczi wrote:
>>> Hi Gregor,
>>>
>>> I have some trouble with the doc generation again.
>>>
>>> The tip you gave me last time
>>>
>>> "rebuild -o- -candydoc -Ddmylib_doc mylib/*.d"
>>>
>>> worked smoothly, but with this new release I got the message:
>>>
>>> "WARNING: Module application.d does not have a module declaration. This
>>> can cause problems with rebuild's -oq option. If an error occurs, fix
>>> this first."
>>>
>>> Ok, I didn't have module declarations in my sources so I made it up.
>>>
>>> With having the module declaration in my sources the documentation
>>> generation silently dies. Simply nothing happens. Could you please take a
>>> look at?
>>>
>>> Many thanks,
>>> David
>>>
>>>
>>>
>> Actually, the bug is that it's only generating documentation if you're
>> making output files (i.e. not using -o-). The quickfix is to use
>> -odgarbage_objs. Will fix the underlying bug by 0.65.
>>
>> - Gregor Richards
>
> That's what I call a response time! Many thanks! :-)
>
> Just from curiousity: what is the reason for compulsory module names?
>
> Regards,
> David
>
rebuild's default output file naming is -oq, which basically names things by their fully-qualified module name. So the module foo.io.translation becomes foo.io.translation.o and foo.text.translation becomes foo.text.translation becomes foo.text.translation.o. These file names are based on the module name, so if foo.io.translation lacks a module declaration, the file name will be translation.o. That's fine, unless foo.text.translation ALSO has no module declaration, in which case both will be named translation.o, and that's deadly.
This can be repaired somewhat by implying the module name from the directory, but I've found that problem to be surprisingly difficult to solve in reality.
Also, it's just good style to always include module declarations :)
- Gregor Richards
|
May 08, 2007 Re: DSSS and Rebuild 0.64 released. | ||||
---|---|---|---|---|
| ||||
Posted in reply to Gregor Richards | > rebuild's default output file naming is -oq, which basically names things by their fully-qualified module name. So the module foo.io.translation becomes foo.io.translation.o and foo.text.translation becomes foo.text.translation becomes foo.text.translation.o. These file names are based on the module name, so if foo.io.translation lacks a module declaration, the file name will be translation.o. That's fine, unless foo.text.translation ALSO has no module declaration, in which case both will be named translation.o, and that's deadly. Ok, I didn't know that -oq was default. > This can be repaired somewhat by implying the module name from the directory, but I've found that problem to be surprisingly difficult to solve in reality. This is what I didn't presume. Since I "name" a module always after the file name, I didn't use the module declaration. It's surely not the best practice, since it may be reasonable to name modules for example with a prefix. > Also, it's just good style to always include module declarations :) I promise to keep it from now on. ;-) Reagrds, David |
Copyright © 1999-2021 by the D Language Foundation