www.digitalmars.com         C & C++   DMDScript  

digitalmars.D - Version of implementation for docs

reply "JS" <js.mdnq gmail.com> writes:
Can we get the version of implementation/addition of a feature in 
the docs. e.g., if X feature/method/library is added into dmd 
version v, then the docs should display that feature.

For example, when I go to http://dlang.org/phobos/object.html I 
see tsize. When I try to use it on my class I dmd says it doesn't 
exist. I'm using 2.063. If I new when tsize was implemented I 
would know if it is something I am doing wrong or if I'm just 
using a version where it isn't implemented.

const pure nothrow  property  safe size_t tsize();       (v 2.063)

or whatever.

P.S. note I added a fake version to it to demonstrate what the 
docs could look like... I know for some this post will be very 
difficult to understand... some will ask for a use case, some 
will call me a troll... Others will say it is not useful, and 
some will say it is too difficult to implement or will be too 
hard to maintain.
Aug 10 2013
next sibling parent reply Jonathan M Davis <jmdavisProg gmx.com> writes:
On Sunday, August 11, 2013 06:30:57 JS wrote:
 Can we get the version of implementation/addition of a feature in
 the docs. e.g., if X feature/method/library is added into dmd
 version v, then the docs should display that feature.
 
 For example, when I go to http://dlang.org/phobos/object.html I
 see tsize. When I try to use it on my class I dmd says it doesn't
 exist. I'm using 2.063. If I new when tsize was implemented I
 would know if it is something I am doing wrong or if I'm just
 using a version where it isn't implemented.
 
 const pure nothrow  property  safe size_t tsize();       (v 2.063)
 
 or whatever.
 
 P.S. note I added a fake version to it to demonstrate what the
 docs could look like... I know for some this post will be very
 difficult to understand... some will ask for a use case, some
 will call me a troll... Others will say it is not useful, and
 some will say it is too difficult to implement or will be too
 hard to maintain.
If you want the docs that go with your version of the compiler, then look at the ones that come with it (they are provided in the zip file - I don't know if they get installed with the installers though). We have enough trouble keeping the documentation up-to-date and accurate without having to worry about versioning. And for the most part, if you have issues with it due to using an older version of the compiler, the advice is going to be to upgrade to the latest compiler. - Jonathan M Davis
Aug 11 2013
parent reply "JS" <js.mdnq gmail.com> writes:
On Sunday, 11 August 2013 at 07:04:14 UTC, Jonathan M Davis wrote:
 On Sunday, August 11, 2013 06:30:57 JS wrote:
 Can we get the version of implementation/addition of a feature 
 in
 the docs. e.g., if X feature/method/library is added into dmd
 version v, then the docs should display that feature.
 
 For example, when I go to http://dlang.org/phobos/object.html I
 see tsize. When I try to use it on my class I dmd says it 
 doesn't
 exist. I'm using 2.063. If I new when tsize was implemented I
 would know if it is something I am doing wrong or if I'm just
 using a version where it isn't implemented.
 
 const pure nothrow  property  safe size_t tsize();       (v 
 2.063)
 
 or whatever.
 
 P.S. note I added a fake version to it to demonstrate what the
 docs could look like... I know for some this post will be very
 difficult to understand... some will ask for a use case, some
 will call me a troll... Others will say it is not useful, and
 some will say it is too difficult to implement or will be too
 hard to maintain.
If you want the docs that go with your version of the compiler, then look at the ones that come with it (they are provided in the zip file - I don't know if they get installed with the installers though). We have enough trouble keeping the documentation up-to-date and accurate without having to worry about versioning. And for the most part, if you have issues with it due to using an older version of the compiler, the advice is going to be to upgrade to the latest compiler. - Jonathan M Davis
And where can I download the most up to date compiled dmd for windows?
Aug 11 2013
parent reply Jonathan M Davis <jmdavisProg gmx.com> writes:
On Sunday, August 11, 2013 09:10:15 JS wrote:
 And where can I download the most up to date compiled dmd for
 windows?
The latest relase is always here: http://dlang.org/download.html And that's the version that the online docs correspond to. - Jonathan M Davis
Aug 11 2013
parent reply "JS" <js.mdnq gmail.com> writes:
On Sunday, 11 August 2013 at 07:17:57 UTC, Jonathan M Davis wrote:
 On Sunday, August 11, 2013 09:10:15 JS wrote:
 And where can I download the most up to date compiled dmd for
 windows?
The latest relase is always here: http://dlang.org/download.html And that's the version that the online docs correspond to. - Jonathan M Davis
But that doesn't correspond to the master? I thought the latest version was 2.064?
Aug 11 2013
parent Tobias Pankrath <lists pankrath.net> writes:
On 11.08.2013 10:59, JS wrote:
 On Sunday, 11 August 2013 at 07:17:57 UTC, Jonathan M Davis wrote:
 On Sunday, August 11, 2013 09:10:15 JS wrote:
 And where can I download the most up to date compiled dmd for
 windows?
The latest relase is always here: http://dlang.org/download.html And that's the version that the online docs correspond to. - Jonathan M Davis
But that doesn't correspond to the master? I thought the latest version was 2.064?
~master is the development branch. Davis is talking about releases, because only releases get a version.
Aug 11 2013
prev sibling next sibling parent reply "bearophile" <bearophileHUGS lycos.com> writes:
JS:

 Can we get the version of implementation/addition of a feature 
 in the docs. e.g., if X feature/method/library is added into 
 dmd version v, then the docs should display that feature.
Python docs do this, and in my first patch I have added such version number. Bye, bearophile
Aug 11 2013
parent reply "JS" <js.mdnq gmail.com> writes:
On Sunday, 11 August 2013 at 10:16:47 UTC, bearophile wrote:
 JS:

 Can we get the version of implementation/addition of a feature 
 in the docs. e.g., if X feature/method/library is added into 
 dmd version v, then the docs should display that feature.
Python docs do this, and in my first patch I have added such version number. Bye, bearophile
Too bad have the "development team" feel this is not important. Very bad decision and will hurt D in the long run. It's not a hard thing to do. Seems to be a lot of laziness going around. Maybe you can tell us just how hard/time consuming it was to type in 2.063 when you added a method?
Aug 11 2013
parent "Tyler Jameson Little" <beatgammit gmail.com> writes:
On Sunday, 11 August 2013 at 15:25:27 UTC, JS wrote:
 On Sunday, 11 August 2013 at 10:16:47 UTC, bearophile wrote:
 JS:

 Can we get the version of implementation/addition of a 
 feature in the docs. e.g., if X feature/method/library is 
 added into dmd version v, then the docs should display that 
 feature.
Python docs do this, and in my first patch I have added such version number. Bye, bearophile
Too bad have the "development team" feel this is not important. Very bad decision and will hurt D in the long run. It's not a hard thing to do. Seems to be a lot of laziness going around. Maybe you can tell us just how hard/time consuming it was to type in 2.063 when you added a method?
Personally I don't like the tone here, but I agree that having version numbers would be very nice to have, especially when using a pre-packaged DMD+Phobos from a package manager. Perhaps this could be automated? It'd be a little messy, but it could look something like this: * get list of all exported names changed since last release (using diff tool) * eliminate all names that have the same definition in the last release * mark new names (not in last release) as new in current release * mark changed names as changed in current release (keep list of changes since added) * document deleted names as having been removed This would only have to be run once per release, so it's okay if it's a little expensive. This bit me once in Go when a dependency failed to compile because of a missing function name. It existed in the official docs, but not in my local docs. After updating to the latest release, everything worked as expected. There was, however, no indication in the docs that anything had been added, only in the change logs.
Aug 11 2013
prev sibling parent Jacob Carlborg <doob me.com> writes:
On 2013-08-11 06:30, JS wrote:
 Can we get the version of implementation/addition of a feature in the
 docs. e.g., if X feature/method/library is added into dmd version v,
 then the docs should display that feature.

 For example, when I go to http://dlang.org/phobos/object.html I see
 tsize. When I try to use it on my class I dmd says it doesn't exist. I'm
 using 2.063. If I new when tsize was implemented I would know if it is
 something I am doing wrong or if I'm just using a version where it isn't
 implemented.

 const pure nothrow  property  safe size_t tsize();       (v 2.063)

 or whatever.
I like the idea. The documentation for API's from Apple contains the version a method/class was added and when something got depreciated, example: http://developer.apple.com/library/Mac/documentation/Cocoa/Reference/ApplicationKit/Classes/NSTableView_Class/Reference/Reference.html -- /Jacob Carlborg
Aug 12 2013