www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.announce - D:YAML 0.4 released

reply "Kiith-Sa" <42 theanswer.com> writes:
I've released D:YAML 0.4 . This release brings mostly updates to 
keep compatibility with DMD 2.057 and bugfixes (in particular, 
compilation on 32bit
works now). The constructor API has also been simplified.

Any custom YAML types (structs and classes serialized directly 
from/to YAML
nodes) now need to define the opCmp operator. This is used to 
detect duplicates and will be used for faster access to data in 
unordered maps in future. (AAs were used previously, but caused 
bugs) If this turns out to be too
impractical, and if Phobos gets a usable hash map, I might use 
that in future -
which would still require toHash and opEquals, though.

API documentation, tutorials and examples were updated to reflect 
the changes,
and slightly improved.

See CHANGES.txt in the source package for detailed information.


Again, the API is unstable and might change in future.
Jan 23 2012
next sibling parent Nengwen Zhuo <soarowl yeah.net> writes:
 I've released D:YAML 0.4 . This release brings mostly updates to
 keep compatibility with DMD 2.057 and bugfixes (in particular,
 compilation on 32bit
 works now). The constructor API has also been simplified.
 Any custom YAML types (structs and classes serialized directly
 from/to YAML
 nodes) now need to define the opCmp operator. This is used to
 detect duplicates and will be used for faster access to data in
 unordered maps in future. (AAs were used previously, but caused
 bugs) If this turns out to be too
 impractical, and if Phobos gets a usable hash map, I might use
 that in future -
 which would still require toHash and opEquals, though.
 API documentation, tutorials and examples were updated to reflect
 the changes,
 and slightly improved.
 See CHANGES.txt in the source package for detailed information.
 
 Again, the API is unstable and might change in future.
 

Greate news. DMD has a bug: dmd -inline -release -O -lib -ofyaml.lib yaml.d compile fine, but: dmd -noboundscheck -inline -release -O -lib -ofyaml.lib yaml.d emit errors.
Jan 23 2012
prev sibling next sibling parent reply "Kiith-Sa" <42 theanswer.com> writes:
 Greate news. DMD has a bug:

 dmd -inline -release -O -lib -ofyaml.lib yaml.d

 compile fine, but:

 dmd -noboundscheck -inline -release -O -lib -ofyaml.lib yaml.d

 emit errors.

Was it a DMD bug, or did it actually compile and cause errors when running? I wasn't able to reproduce it, but I'm on Linux. If it's a DMD/Windows bug, it can't do much about it (although maybe 2.058 will help?) Or are you actually trying to compile D:YAML with that command? Use the CDC script in the source to do that (see the getting started tutorial for detailed info): ./cdc.d release That compiles the release build , which includes -O, -inline, -release and -noboundscheck .
Jan 24 2012
next sibling parent Nengwen Zhuo <soarowl yeah.net> writes:
 Greate news. DMD has a bug:
 
 dmd -inline -release -O -lib -ofyaml.lib yaml.d
 
 compile fine, but:
 
 dmd -noboundscheck -inline -release -O -lib -ofyaml.lib yaml.d
 
 emit errors.
 

when running? I wasn't able to reproduce it, but I'm on Linux. If it's a DMD/Windows bug, it can't do much about it (although maybe 2.058 will help?) Or are you actually trying to compile D:YAML with that command? Use the CDC script in the source to do that (see the getting started tutorial for detailed info): ./cdc.d release That compiles the release build , which includes -O, -inline, -release and -noboundscheck .

I'm using all head version on windows: dmd, druntime and phobos. It's a compiler bug, not run time bug. If I use "-noboundscheck -inline -release -O" options, most projects in github have one or other related bugs. By the way, cdc.d con't compile, "import core.stdc;" statment needed.
Jan 24 2012
prev sibling next sibling parent reply "Kiith-Sa" <42 theanswer.com> writes:
I added import core.stdc;

Compiles with or without it here, though, so I can't say if it 
helped.
However; does that even make sense?

Shouldn't you have to import a particular module instead of just 
core.stdc?
Jan 24 2012
parent Nengwen Zhuo <soarowl yeah.net> writes:
 I added import core.stdc;
 
 Compiles with or without it here, though, so I can't say if it
 helped.
 However; does that even make sense?
 Shouldn't you have to import a particular module instead of just
 core.stdc?
 

I add import core.stdc.stdlib; but core.stdc.stdlib.system(...) conflict with std.process.system(...); and there have other compiler issues with head version of dmd, druntime and phobos, because phobos has minor changes. I have to leave a week right now and no time to fix all those issues. Sorry!
Jan 24 2012
prev sibling parent "Kiith-Sa" <42 theanswer.com> writes:
Never mind, I needed to import core.stdc.stdlib; it should work 
correctly now.
Jan 24 2012
prev sibling next sibling parent Jonathan M Davis <jmdavisProg gmx.com> writes:
On Monday, January 23, 2012 20:55:10 Kiith-Sa wrote:
 I've released D:YAML 0.4 . This release brings mostly updates to
 keep compatibility with DMD 2.057 and bugfixes (in particular,
 compilation on 32bit
 works now). The constructor API has also been simplified.
 
 Any custom YAML types (structs and classes serialized directly
 from/to YAML
 nodes) now need to define the opCmp operator. This is used to
 detect duplicates and will be used for faster access to data in
 unordered maps in future. (AAs were used previously, but caused
 bugs) If this turns out to be too
 impractical, and if Phobos gets a usable hash map, I might use
 that in future -
 which would still require toHash and opEquals, though.
 
 API documentation, tutorials and examples were updated to reflect
 the changes,
 and slightly improved.
 
 See CHANGES.txt in the source package for detailed information.
 
 
 Again, the API is unstable and might change in future.

Thanks for doing this! I need a YAML parser for one of my projects and was expecting to have to write one (which I was actually kind of looking forward to doing, since I like writing parsers, but I'm kind of short on time, so having to write one _is_ a bit problematic). This will save me time. - Jonathan M Davis
Jul 26 2012
prev sibling next sibling parent "Paulo Pinto" <pjmlp progtools.org> writes:
On Monday, 23 January 2012 at 19:55:11 UTC, Kiith-Sa wrote:
 I've released D:YAML 0.4 . This release brings mostly updates 
 to keep compatibility with DMD 2.057 and bugfixes (in 
 particular, compilation on 32bit
 works now). The constructor API has also been simplified.

 Any custom YAML types (structs and classes serialized directly 
 from/to YAML
 nodes) now need to define the opCmp operator. This is used to 
 detect duplicates and will be used for faster access to data in 
 unordered maps in future. (AAs were used previously, but caused 
 bugs) If this turns out to be too
 impractical, and if Phobos gets a usable hash map, I might use 
 that in future -
 which would still require toHash and opEquals, though.

 API documentation, tutorials and examples were updated to 
 reflect the changes,
 and slightly improved.

 See CHANGES.txt in the source package for detailed information.


 Again, the API is unstable and might change in future.

Link seems to be missing. https://github.com/kiith-sa/D-YAML
Jul 27 2012
prev sibling next sibling parent "Paulo Pinto" <pjmlp progtools.org> writes:
On Tuesday, 24 January 2012 at 09:45:03 UTC, Kiith-Sa wrote:
 Greate news. DMD has a bug:

 dmd -inline -release -O -lib -ofyaml.lib yaml.d

 compile fine, but:

 dmd -noboundscheck -inline -release -O -lib -ofyaml.lib yaml.d

 emit errors.

Was it a DMD bug, or did it actually compile and cause errors when running? I wasn't able to reproduce it, but I'm on Linux. If it's a DMD/Windows bug, it can't do much about it (although maybe 2.058 will help?) Or are you actually trying to compile D:YAML with that command? Use the CDC script in the source to do that (see the getting started tutorial for detailed info): ./cdc.d release That compiles the release build , which includes -O, -inline, -release and -noboundscheck .

with dmd 2.059 on Windows, D:\kiith-sa-D-YAML-c690d56>cdc building release target CDC: dmd compile C:\D\dmd2\windows\bin\..\..\src\phobos\std\datetime.d(29289): Error: variable std.path.sep is deprecated C:\D\dmd2\windows\bin\..\..\src\phobos\std\datetime.d(29598): Error: variable std.path.sep is deprecated C:\D\dmd2\windows\bin\..\..\src\phobos\std\datetime.d(29600): Error: variable std.path.sep is deprecated C:\D\dmd2\windows\bin\..\..\src\phobos\std\datetime.d(29601): Error: variable std.path.sep is deprecated C:\D\dmd2\windows\bin\..\..\src\phobos\std\file.d(542): Error: variable std.path.sep is deprecated C:\D\dmd2\windows\bin\..\..\src\phobos\std\file.d(543): Error: variable std.path.sep is deprecated C:\D\dmd2\windows\bin\..\..\src\phobos\std\file.d(1968): Error: variable std.path.sep is deprecated C:\D\dmd2\windows\bin\..\..\src\phobos\std\file.d(1969): Error: variable std.path.sep is deprecated Compiler failed: Process dmd exited with status 1 DONE D:\kiith-sa-D-YAML-c690d56>dmd -inline -release -O -lib -ofyaml.lib yaml.d D:\kiith-sa-D-YAML-c690d56>dmd -noboundscheck -inline -release -O -lib -ofyaml.lib yaml.d C:\D\dmd2\windows\bin\..\..\src\phobos\std\datetime.d(29289): Error: variable std.path.sep is deprecated C:\D\dmd2\windows\bin\..\..\src\phobos\std\datetime.d(29598): Error: variable std.path.sep is deprecated C:\D\dmd2\windows\bin\..\..\src\phobos\std\datetime.d(29600): Error: variable std.path.sep is deprecated C:\D\dmd2\windows\bin\..\..\src\phobos\std\datetime.d(29601): Error: variable std.path.sep is deprecated C:\D\dmd2\windows\bin\..\..\src\phobos\std\file.d(542): Error: variable std.path.sep is deprecated C:\D\dmd2\windows\bin\..\..\src\phobos\std\file.d(543): Error: variable std.path.sep is deprecated C:\D\dmd2\windows\bin\..\..\src\phobos\std\file.d(1968): Error: variable std.path.sep is deprecated C:\D\dmd2\windows\bin\..\..\src\phobos\std\file.d(1969): Error: variable std.path.sep is deprecated
Jul 27 2012
prev sibling next sibling parent "Paulo Pinto" <pjmlp progtools.org> writes:
On Saturday, 28 July 2012 at 06:01:15 UTC, Paulo Pinto wrote:
 On Tuesday, 24 January 2012 at 09:45:03 UTC, Kiith-Sa wrote:
 Greate news. DMD has a bug:

 dmd -inline -release -O -lib -ofyaml.lib yaml.d

 compile fine, but:

 dmd -noboundscheck -inline -release -O -lib -ofyaml.lib yaml.d

 emit errors.

Was it a DMD bug, or did it actually compile and cause errors when running? I wasn't able to reproduce it, but I'm on Linux. If it's a DMD/Windows bug, it can't do much about it (although maybe 2.058 will help?) Or are you actually trying to compile D:YAML with that command? Use the CDC script in the source to do that (see the getting started tutorial for detailed info): ./cdc.d release That compiles the release build , which includes -O, -inline, -release and -noboundscheck .

with dmd 2.059 on Windows, D:\kiith-sa-D-YAML-c690d56>cdc building release target CDC: dmd compile C:\D\dmd2\windows\bin\..\..\src\phobos\std\datetime.d(29289): Error: variable std.path.sep is deprecated C:\D\dmd2\windows\bin\..\..\src\phobos\std\datetime.d(29598): Error: variable std.path.sep is deprecated C:\D\dmd2\windows\bin\..\..\src\phobos\std\datetime.d(29600): Error: variable std.path.sep is deprecated C:\D\dmd2\windows\bin\..\..\src\phobos\std\datetime.d(29601): Error: variable std.path.sep is deprecated C:\D\dmd2\windows\bin\..\..\src\phobos\std\file.d(542): Error: variable std.path.sep is deprecated C:\D\dmd2\windows\bin\..\..\src\phobos\std\file.d(543): Error: variable std.path.sep is deprecated C:\D\dmd2\windows\bin\..\..\src\phobos\std\file.d(1968): Error: variable std.path.sep is deprecated C:\D\dmd2\windows\bin\..\..\src\phobos\std\file.d(1969): Error: variable std.path.sep is deprecated Compiler failed: Process dmd exited with status 1 DONE D:\kiith-sa-D-YAML-c690d56>dmd -inline -release -O -lib -ofyaml.lib yaml.d D:\kiith-sa-D-YAML-c690d56>dmd -noboundscheck -inline -release -O -lib -ofyaml.lib yaml.d C:\D\dmd2\windows\bin\..\..\src\phobos\std\datetime.d(29289): Error: variable std.path.sep is deprecated C:\D\dmd2\windows\bin\..\..\src\phobos\std\datetime.d(29598): Error: variable std.path.sep is deprecated C:\D\dmd2\windows\bin\..\..\src\phobos\std\datetime.d(29600): Error: variable std.path.sep is deprecated C:\D\dmd2\windows\bin\..\..\src\phobos\std\datetime.d(29601): Error: variable std.path.sep is deprecated C:\D\dmd2\windows\bin\..\..\src\phobos\std\file.d(542): Error: variable std.path.sep is deprecated C:\D\dmd2\windows\bin\..\..\src\phobos\std\file.d(543): Error: variable std.path.sep is deprecated C:\D\dmd2\windows\bin\..\..\src\phobos\std\file.d(1968): Error: variable std.path.sep is deprecated C:\D\dmd2\windows\bin\..\..\src\phobos\std\file.d(1969): Error: variable std.path.sep is deprecated

A workaround is to add .d to the command line, as it seems that phobos makes use of deprecated stuff on windows. Is there a bug for it already? Otherwise I could provide a fix. -- Paulo
Jul 27 2012
prev sibling next sibling parent Jonathan M Davis <jmdavisProg gmx.com> writes:
On Saturday, July 28, 2012 08:24:20 Paulo Pinto wrote:
 Is there a bug for it already? Otherwise I could provide a fix.

http://d.puremagic.com/issues/show_bug.cgi?id=8003 dmd 2.060beta does not have the problem. - Jonathan M Davis
Jul 27 2012
prev sibling next sibling parent "Paulo Pinto" <pjmlp progtools.org> writes:
On Saturday, 28 July 2012 at 06:31:31 UTC, Jonathan M Davis wrote:
 On Saturday, July 28, 2012 08:24:20 Paulo Pinto wrote:
 Is there a bug for it already? Otherwise I could provide a fix.

http://d.puremagic.com/issues/show_bug.cgi?id=8003 dmd 2.060beta does not have the problem. - Jonathan M Davis

Ah, thanks. Nothing to be done then.
Jul 28 2012
prev sibling parent "Kiith-Sa" <42 theanswer.com> writes:
 A workaround is to add .d to the command line, as it seems that 
 phobos makes use of deprecated stuff on windows.

 Is there a bug for it already? Otherwise I could provide a fix.

 --
 Paulo

I'm currently working on a non-D project, and didn't yet check if it works with DMD newer than 2.058. I.m planning to fix any issues in September (but that will be with DMD 2.060).
Jul 28 2012