2.079.0-rc.1 [Re: Beta 2.079.0]

2018-02-27 Thread Martin Nowak via Digitalmars-d-announce
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA512

Release candidate available now.

http://dlang.org/changelog/2.079.0.html
http://dlang.org/download.html#dmd_beta

- -Martin
-BEGIN PGP SIGNATURE-

iQIzBAEBCgAdFiEEpzRNrTw0HqEtE8TmsnOBFhK7GTkFAlqV4EgACgkQsnOBFhK7
GTmxyQ/9HSNmHvegTkIwheEcoHOMyn5s2QvK/8O1k07zfzLa6Bzhu55zEXlQGj1V
GDEl6YwGmzOcEF19XJnh/QOFMeNQJfwErfCjE2pJecN5aSeN87NapARzp1IZLXZw
avGJtlIPALpImYc7sg02syCRkg7399Bei5eAmgxsnbf0p5hx645brkL5v8Ko0stp
+PkGFM3ycAcxXq5iWcyxoIm1zgRKxzlP1xpJi1FIm9vMvT30nFmcF6vNz/IItMhv
bCSDaMU7GVsoRqD6SM9vnzCusbUJZpI6TkH0r+nlAMaU5UI8v9jG9+xQldxKiGhi
ScJY8kxMs4Bl2OS8ZTKqjgzJecejOuiRiseXgrQxRFWjyRVEOhZhh67q9HdgztCy
pc4OwRbwQEI3OR2jyNgbGqyc6eEQenvI4viQEjEONxAYR61hqDCUsWH7/K17z1Uu
4EmybgSiKowqvxF8Q6R7ZfsisAPzs3miSVjZ7pNSldQnrddUsisbfDYfHdexH9Aw
wPWp6OHsLjPRxihxCo8ThVSOjFgXh2+pu9Bzrj+QOa5pmha/hUfsRg6SfoRBsNnm
FopQXDDG4EuaTt64hvw5Phtm9AuUxzuD/49B98EN/YoosfmPFpuecXUX1FDHw33E
Vi467utwlLk5mbG5OBaBrpkpnFExyUn5vb1Ts6S+cCVVSbp58Po=
=nY5p
-END PGP SIGNATURE-


Re: Documentation for any* dub package, any version

2018-02-27 Thread Nick Sabalausky via Digitalmars-d-announce

On Tuesday, 27 February 2018 at 15:49:37 UTC, Basile B. wrote:


At first glance i can say that this will work perfectly for DUB 
packages. Once DCD gives a file, the IDE just have to look the 
parent folders to get the SemVer tag.
If the file is in a git repository things might be more 
complicated.


In most cases its pretty easy from a git repo too, just run 'git 
describe'. That'll give you the latest (annotated) tag (which 
SHOULD be the semver number, and generally is for dub projects) 
and no other output. Nothing to parse or scrape.


If theres been extra commits since the last tag, then there's a 
little extra suffix appended to git describe's output, but its 
trivial enough to parse/remove if you need to.


Re: Documentation for any* dub package, any version

2018-02-27 Thread David Gileadi via Digitalmars-d-announce

On 2/27/18 2:59 PM, Adam D. Ruppe wrote:

On Tuesday, 27 February 2018 at 16:39:08 UTC, David Gileadi wrote:
Markdown actually supports two kinds of links: inline links (which you 
describe above and I'm very happy you support) and reference links [1].


Oh, I have something similar to that too.

http://dpldocs.info/experimental-docs/adrdox.syntax.html#footnotes

I actually didn't realize markdown had such... mine is probably not 
quite compatible... but [text][text] is an uncommon enough pattern it 
might just be workable. I doubt I'd ever write [link][link] without a 
space in between...


What I want to do is automatically include references for symbols in 
the current scope, to support links to symbols via [symbol] and [alt 
text][symbol].


Yeah, that might work on both generators.


I hope so. I'm happy that D documentation is nicer to use. Thanks for 
working on it!


Re: Documentation for any* dub package, any version

2018-02-27 Thread David Gileadi via Digitalmars-d-announce

On 2/27/18 3:18 PM, David Gileadi wrote:

On 2/27/18 2:59 PM, Adam D. Ruppe wrote:

On Tuesday, 27 February 2018 at 16:39:08 UTC, David Gileadi wrote:
Markdown actually supports two kinds of links: inline links (which 
you describe above and I'm very happy you support) and reference 
links [1].


Oh, I have something similar to that too.

http://dpldocs.info/experimental-docs/adrdox.syntax.html#footnotes

I actually didn't realize markdown had such... mine is probably not 
quite compatible... but [text][text] is an uncommon enough pattern it 
might just be workable. I doubt I'd ever write [link][link] without a 
space in between...


What I want to do is automatically include references for symbols in 
the current scope, to support links to symbols via [symbol] and [alt 
text][symbol].


Yeah, that might work on both generators.


I hope so. I'm happy that D documentation is nicer to use. Thanks for 
working on it!


Whoops, should have been "...D documentation is *getting* nicer to use."


Re: Documentation for any* dub package, any version

2018-02-27 Thread Adam D. Ruppe via Digitalmars-d-announce

On Tuesday, 27 February 2018 at 16:39:08 UTC, David Gileadi wrote:
Markdown actually supports two kinds of links: inline links 
(which you describe above and I'm very happy you support) and 
reference links [1].


Oh, I have something similar to that too.

http://dpldocs.info/experimental-docs/adrdox.syntax.html#footnotes

I actually didn't realize markdown had such... mine is probably 
not quite compatible... but [text][text] is an uncommon enough 
pattern it might just be workable. I doubt I'd ever write 
[link][link] without a space in between...


What I want to do is automatically include references for 
symbols in the current scope, to support links to symbols via 
[symbol] and [alt text][symbol].


Yeah, that might work on both generators.



Re: Documentation for any* dub package, any version

2018-02-27 Thread David Gileadi via Digitalmars-d-announce

On 2/27/18 9:21 AM, Adam D. Ruppe wrote:

On Tuesday, 27 February 2018 at 16:00:26 UTC, David Gileadi wrote:
Out of curiosity, what prompted [symbol|alt text] instead of going 
with the Markdown construct of [alt text][symbol]?


Well, markdown is [alt text](url), and adrdox actually DOES support that 
as well:


http://dpldocs.info/experimental-docs/adrdox.syntax.html#markdown-style-links 



(I just added that last Friday though for gtkd docs compatibility!)

Though it does NOT support a symbol in there, just a URL right now. 
Maybe I can add it, but I always start conservative - allow the least 
syntax with the most restrictions I can, then loosen them as I'm sure it 
isn't annoying.



But anyway, the [symbol|alt text] comes from Wikipedia's markup 
actually, which is the first thing that comes to my mind to easily 
cross-link articles. On wikipedia, you use brackets to indicate a word 
as a link: `director = [[Avery Brooks]]`, for example, will link to that 
article. Similarly, `[[Star Trek: Deep Space Nine (season 6)|6]]` will 
just show the text "6", while linking to the page in there.


So I took that and generalized it a bit so it supports other URLs too, 
then simplified it to just one set of [] instead of two.



The big advantage for [] over markdown links is it is lighter syntax in 
the simple case:


/// See also: [intersect]

knows to link to the symbol `intersect`. Whereas:

/// See also: [intersect](intersect)

would be the equivalent markdown style, but it is repeated... so you 
might skip the alt text:


/// See also: (intersect)

but that conflicts with very common parenthetical text like "I think 
that's silly (sorta)..." and I wouldn't want "sorta" to be linked there!


So I just went with [].


Markdown actually supports two kinds of links: inline links (which you 
describe above and I'm very happy you support) and reference links [1].


A reference link can be like [alt text][reference] or you can do the 
shortcut version if your alt text is the same as the reference name: 
[reference]. I currently support both forms in my upcoming Markdown PR, 
but they only link to references that are defined elsewhere in the 
document, like my [1] at the bottom of this message. What I want to do 
is automatically include references for symbols in the current scope, to 
support links to symbols via [symbol] and [alt text][symbol].



[1]: http://spec.commonmark.org/0.28/#reference-link


Re: Documentation for any* dub package, any version

2018-02-27 Thread Adam D. Ruppe via Digitalmars-d-announce

On Tuesday, 27 February 2018 at 16:00:26 UTC, David Gileadi wrote:
Out of curiosity, what prompted [symbol|alt text] instead of 
going with the Markdown construct of [alt text][symbol]?


Well, markdown is [alt text](url), and adrdox actually DOES 
support that as well:


http://dpldocs.info/experimental-docs/adrdox.syntax.html#markdown-style-links

(I just added that last Friday though for gtkd docs 
compatibility!)


Though it does NOT support a symbol in there, just a URL right 
now. Maybe I can add it, but I always start conservative - allow 
the least syntax with the most restrictions I can, then loosen 
them as I'm sure it isn't annoying.



But anyway, the [symbol|alt text] comes from Wikipedia's markup 
actually, which is the first thing that comes to my mind to 
easily cross-link articles. On wikipedia, you use brackets to 
indicate a word as a link: `director = [[Avery Brooks]]`, for 
example, will link to that article. Similarly, `[[Star Trek: Deep 
Space Nine (season 6)|6]]` will just show the text "6", while 
linking to the page in there.


So I took that and generalized it a bit so it supports other URLs 
too, then simplified it to just one set of [] instead of two.



The big advantage for [] over markdown links is it is lighter 
syntax in the simple case:


/// See also: [intersect]

knows to link to the symbol `intersect`. Whereas:

/// See also: [intersect](intersect)

would be the equivalent markdown style, but it is repeated... so 
you might skip the alt text:


/// See also: (intersect)

but that conflicts with very common parenthetical text like "I 
think that's silly (sorta)..." and I wouldn't want "sorta" to be 
linked there!


So I just went with [].



Re: Documentation for any* dub package, any version

2018-02-27 Thread David Gileadi via Digitalmars-d-announce

On 2/26/18 12:51 PM, Adam D. Ruppe wrote:
... I just have 
a built-in, simple, unified syntax: [symbol|alt text] where alt text is 
optional and symbol is looked up according to D scope rules. (you can 
also define custom symbols for things like author name links).


I link to the source automatically too, including to the specific line 
of the correct overload for functions, so no need for macros to do those.


Out of curiosity, what prompted [symbol|alt text] instead of going with 
the Markdown construct of [alt text][symbol]? I ask because if I'm able 
to get my Markdown support merged into DDoc, I'd like to support 
[symbol] and [alt text][symbol] links.


Re: Documentation for any* dub package, any version

2018-02-27 Thread Basile B. via Digitalmars-d-announce

On Tuesday, 27 February 2018 at 14:42:11 UTC, Adam D. Ruppe wrote:

On Tuesday, 27 February 2018 at 10:02:13 UTC, Basile B. wrote:
Awesome work. IDEs could use this, i don't know how yet but 
i'll maybe try something one day.


Yeah, webfreak was talking to me about that on irc and I've had 
people ask me about the main dpldocs site being an api (to 
which I reply "it is already a REST api returning a XML 
representation called a static html page". which i think is 
good - this html is a bit verbose bu that's because i wrote it 
with a lot of semantic information included in the tags, it can 
be machine parsed and analyzed. need a lib for it? use my dom.d 
:P )


But anyway, once I see someone with a prototype and we can 
identify specific needs through use, then I'm open to adding 
more stuff to help that effort.


I think that nothing more is needed.

The idea is to use DCD to get the d source where a symbol is 
declared, from this file it's possible to guess the html page for 
this symbol. Actually i already do this for phobos (using the 
official html) and it works fine.


At first glance i can say that this will work perfectly for DUB 
packages. Once DCD gives a file, the IDE just have to look the 
parent folders to get the SemVer tag.
If the file is in a git repository things might be more 
complicated.


The only difference with what is done right now (in Coedit) is 
the url structure.
For now it's  ".html#" or 
"_.html#".

While with ardrox it's ..html.




Re: Documentation for any* dub package, any version

2018-02-27 Thread Adam D. Ruppe via Digitalmars-d-announce

On Tuesday, 27 February 2018 at 10:02:13 UTC, Basile B. wrote:
Awesome work. IDEs could use this, i don't know how yet but 
i'll maybe try something one day.


Yeah, webfreak was talking to me about that on irc and I've had 
people ask me about the main dpldocs site being an api (to which 
I reply "it is already a REST api returning a XML 
representation called a static html page". which i think is 
good - this html is a bit verbose bu that's because i wrote it 
with a lot of semantic information included in the tags, it can 
be machine parsed and analyzed. need a lib for it? use my dom.d 
:P )


But anyway, once I see someone with a prototype and we can 
identify specific needs through use, then I'm open to adding more 
stuff to help that effort. Until then tho my feeling is YAGNI and 
I am keeping the code on this server simple - try the IDE 
integration just showing the HTML in a web view first, or 
scraping the html for plain text, and we'll see how that looks as 
the first draft.



Are the doc persistent on your server ?
For example is http://iz.dpldocs.info/v0.6.4/iz.html here 
forever ?


Logically yes, in reality, maybe but I'm in the shell right now 
`rm -r`ing from time to time as I update the generator, and then 
your page will be automatically rebuild on the next request with 
the new generator version.


But that has already stabilized quite a bit so a lot of those 
files may in fact sit there for a very long time. I may also 
clear some if i ever hit a disk space limit tho...


but in any case, if a page is requested, it will be there, even 
if it has to be unzipped/regenerated first. Just be a bit patient 
waiting for the load in those events.


Re: Documentation for any* dub package, any version

2018-02-27 Thread Adam D. Ruppe via Digitalmars-d-announce

On Tuesday, 27 February 2018 at 09:17:21 UTC, bauss wrote:

Nvm, I see how stupid I was.


Nah, bad UX. I give myself some slack cuz I slapped this together 
in just a few spare hours over the weekend, but the error message 
also could have pointed you back to the site index.


That just took 3 minutes to change tho, now it says:

404. Try diamond.html as a starting point (and it is a link)


Re: An optional/maybe type with range semantics

2018-02-27 Thread aliak via Digitalmars-d-announce

On Tuesday, 27 February 2018 at 11:58:34 UTC, Dukc wrote:

On Monday, 26 February 2018 at 20:04:14 UTC, aliak wrote:
Guess I could do a pointer and call new when i need to store a 
value instead. Or maybe it's better to do it like above and 
store as value type with default value and a boolean at the 
site. Not sure.


You do not need a separate boolean field. If someone assigns 
"none" or calls popFront() just assign the pointer to null. 
When someone queries empty, you check whether the pointer 
points to null.  The default value is easy too: 
typeof(element).init.


Either you misunderstood or my writing was not clear. I meant 
you'd need a boolean if you were using a value type (was just 
speaking out loud as another alternative to a pointer or array)




That's the superior design, because it does not need any excess 
memory for the empty flag.


It means using new, so not sure how superior it is compare to 
storing a value type.




Re: An optional/maybe type with range semantics

2018-02-27 Thread Dukc via Digitalmars-d-announce

On Monday, 26 February 2018 at 20:04:14 UTC, aliak wrote:
Guess I could do a pointer and call new when i need to store a 
value instead. Or maybe it's better to do it like above and 
store as value type with default value and a boolean at the 
site. Not sure.


You do not need a separate boolean field. If someone assigns 
"none" or calls popFront() just assign the pointer to null. When 
someone queries empty, you check whether the pointer points to 
null.  The default value is easy too: typeof(element).init.


That's the superior design, because it does not need any excess 
memory for the empty flag.





Re: Documentation for any* dub package, any version

2018-02-27 Thread Basile B. via Digitalmars-d-announce

On Monday, 26 February 2018 at 14:59:07 UTC, Adam D. Ruppe wrote:
Many of you will already know this from the other thread or 
from my twitter, but I just added a on-demand downloader to my 
dpldocs.info domain to fetch and build docs for any* dub 
package.


Simply go to projectname.dpldocs.info/vX.Y.Z/ and it will 
generate docs for dub package projectname, version X.Y.Z. (If 
you don't specify a version, it will pull the master branch.)


For example:

http://arsd-official.dpldocs.info/arsd.html

master branch for the arsd-official package

or:

http://dplug.dpldocs.info/v6.0.22/dplug.html

6.0.22 of the dplug package.

etc.

I'd like to get the code.dlang.org folks to add the correct 
link to the main package site so people can easily discover 
this just put nofollow on it plz so google doesn't trigger 
generation of pages people don't actually need (the lazy 
generation + caching allows me to host this on a cheap VPS)



It builds the docs using my own doc generator 
 which pulls embedded doc 
comments out of the source.


It isn't 100% compatible with ddoc. For example, this 
user-defined macro was not expanded: 
http://dxml.dpldocs.info/dxml.dom.html#source


But, it builds 99% of Phobos so it can probably build your 
project too! And get the ease of adrdox navigation and 
legibility.


Moreover, if you want to embrace it, you can use all the 
features described here: 
http://dpldocs.info/experimental-docs/adrdox.syntax.html except 
for the LaTeX math generation (that's not installed on the dub 
doc server I set up).


You can group functions like seen here: 
http://dpldocs.info/experimental-docs/arsd.nanovega.html and 
use some markdown syntax, and easy [reference] linking and more.




The generated docs may get some customization options in the 
future, like adding a logo, header nav links, or maybe tweaking 
the color scheme. It will probably also start reading 
.gitignore and perhaps a .adrdoxignore file soon to to exclude 
files from generation. I just need to decide the details first 
and it is time to work the day job right now and I want to 
announce sooner rather than later :)



* currently, only github code downloading is actually 
implemented.


Awesome work. IDEs could use this, i don't know how yet but i'll 
maybe try something one day.


Are the doc persistent on your server ?
For example is http://iz.dpldocs.info/v0.6.4/iz.html here forever 
?


Re: Documentation for any* dub package, any version

2018-02-27 Thread aberba via Digitalmars-d-announce

On Tuesday, 27 February 2018 at 09:17:21 UTC, bauss wrote:

On Tuesday, 27 February 2018 at 09:16:12 UTC, bauss wrote:
On Monday, 26 February 2018 at 14:59:07 UTC, Adam D. Ruppe 
wrote:

[...]


Tried with http://diamond.dpldocs.info/arsd.html and it gives 
a 404


Nvm, I see how stupid I was.


You were not stupid. You made a mistake. They're two different 
things.


Re: Documentation for any* dub package, any version

2018-02-27 Thread bauss via Digitalmars-d-announce

On Tuesday, 27 February 2018 at 09:16:12 UTC, bauss wrote:
On Monday, 26 February 2018 at 14:59:07 UTC, Adam D. Ruppe 
wrote:

[...]


Tried with http://diamond.dpldocs.info/arsd.html and it gives a 
404


Nvm, I see how stupid I was.


Re: Documentation for any* dub package, any version

2018-02-27 Thread bauss via Digitalmars-d-announce

On Monday, 26 February 2018 at 14:59:07 UTC, Adam D. Ruppe wrote:
Many of you will already know this from the other thread or 
from my twitter, but I just added a on-demand downloader to my 
dpldocs.info domain to fetch and build docs for any* dub 
package.


Simply go to projectname.dpldocs.info/vX.Y.Z/ and it will 
generate docs for dub package projectname, version X.Y.Z. (If 
you don't specify a version, it will pull the master branch.)


For example:

http://arsd-official.dpldocs.info/arsd.html

master branch for the arsd-official package

or:

http://dplug.dpldocs.info/v6.0.22/dplug.html

6.0.22 of the dplug package.

etc.

I'd like to get the code.dlang.org folks to add the correct 
link to the main package site so people can easily discover 
this just put nofollow on it plz so google doesn't trigger 
generation of pages people don't actually need (the lazy 
generation + caching allows me to host this on a cheap VPS)



It builds the docs using my own doc generator 
 which pulls embedded doc 
comments out of the source.


It isn't 100% compatible with ddoc. For example, this 
user-defined macro was not expanded: 
http://dxml.dpldocs.info/dxml.dom.html#source


But, it builds 99% of Phobos so it can probably build your 
project too! And get the ease of adrdox navigation and 
legibility.


Moreover, if you want to embrace it, you can use all the 
features described here: 
http://dpldocs.info/experimental-docs/adrdox.syntax.html except 
for the LaTeX math generation (that's not installed on the dub 
doc server I set up).


You can group functions like seen here: 
http://dpldocs.info/experimental-docs/arsd.nanovega.html and 
use some markdown syntax, and easy [reference] linking and more.




The generated docs may get some customization options in the 
future, like adding a logo, header nav links, or maybe tweaking 
the color scheme. It will probably also start reading 
.gitignore and perhaps a .adrdoxignore file soon to to exclude 
files from generation. I just need to decide the details first 
and it is time to work the day job right now and I want to 
announce sooner rather than later :)



* currently, only github code downloading is actually 
implemented.


Tried with http://diamond.dpldocs.info/arsd.html and it gives a 
404