www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.announce - DMD 1.024 and 2.008 releases

reply Walter Bright <newshound1 digitalmars.com> writes:
New const/invariant in 2.007!

http://www.digitalmars.com/d/1.0/changelog.html
http://ftp.digitalmars.com/dmd.1.024.zip

http://www.digitalmars.com/d/changelog.html
http://ftp.digitalmars.com/dmd.2.008.zip
Nov 27 2007
next sibling parent reply Walter Bright <newshound1 digitalmars.com> writes:
Walter Bright wrote:
 New const/invariant in 2.007!

er, 2.008!
Nov 27 2007
parent Jay Norwood <jayn io.com> writes:
Walter Bright Wrote:

 Walter Bright wrote:
 New const/invariant in 2.007!

er, 2.008!

The changelog for 2.008 states invariant was added to isExpression, but the on-line documentation of isExpression instead includes a second instance of interface. http://www.digitalmars.com/d/changelog.html http://www.digitalmars.com/d/expression.html#IsExpression
Jan 06 2008
prev sibling next sibling parent reply Clay Smith <clayasaurus gmail.com> writes:
Walter Bright wrote:
 New const/invariant in 2.007!
 
 http://www.digitalmars.com/d/1.0/changelog.html
 http://ftp.digitalmars.com/dmd.1.024.zip
 
 http://www.digitalmars.com/d/changelog.html
 http://ftp.digitalmars.com/dmd.2.008.zip

Horray! It also looks like the beginning of an actively developed phobos! Great work Walter and Andrei!
Nov 27 2007
parent Bill Baxter <dnewsgroup billbaxter.com> writes:
Clay Smith wrote:
 Walter Bright wrote:
 New const/invariant in 2.007!

 http://www.digitalmars.com/d/1.0/changelog.html
 http://ftp.digitalmars.com/dmd.1.024.zip

 http://www.digitalmars.com/d/changelog.html
 http://ftp.digitalmars.com/dmd.2.008.zip

Horray! It also looks like the beginning of an actively developed phobos! Great work Walter and Andrei!

Yikes! Looks like I've got my work cut out for me updating the std2 backport of phobos. Anyway, is the const article up to date with the "current state of the const"? I mean this one: http://www.digitalmars.com/d/const.html --bb
Nov 27 2007
prev sibling next sibling parent reply Kenny TM~ <kennytm gmail..com> writes:
Walter Bright wrote:
 New const/invariant in 2.007!
 
 http://www.digitalmars.com/d/1.0/changelog.html
 http://ftp.digitalmars.com/dmd.1.024.zip
 
 http://www.digitalmars.com/d/changelog.html
 http://ftp.digitalmars.com/dmd.2.008.zip

Oh great! :D Love to see the new std.algorithm. BTW, are std.windows.charset and std.slist new modules too? Seems not mentioned on the changelog, or probably I've missed it in previous versions. -- -- Kenny.
Nov 27 2007
parent jcc7 <technocrat7 gmail.com> writes:
== Quote from Kenny TM~ (kennytm gmail..com)'s article
 Walter Bright wrote:
 New const/invariant in 2.007!

 http://www.digitalmars.com/d/1.0/changelog.html
 http://ftp.digitalmars.com/dmd.1.024.zip

 http://www.digitalmars.com/d/changelog.html
 http://ftp.digitalmars.com/dmd.2.008.zip

Oh great! :D Love to see the new std.algorithm. BTW, are std.windows.charset and std.slist new modules too? Seems not mentioned on the changelog, or probably I've missed it in previous versions.

The changelog has been split into several pages so it can be tricky to search. The std.windows.charset module was added a few years ago (DMD 0.140, Nov 23, 2005): http://www.digitalmars.com/d/1.0/changelog2.html#new0140 On the other hand, I couldn't find the std.slist module in the changelog either, and it seems to be much newer: http://www.dsource.org/projects/phobos/log/trunk/phobos/std/slist.d http://www.dsource.org/projects/phobos/log/candidate/phobos/std/slist.d
Nov 28 2007
prev sibling next sibling parent reply Lutger <lutger.blijdestijn gmail.com> writes:
Walter Bright wrote:
 New const/invariant in 2.007!
 
 http://www.digitalmars.com/d/1.0/changelog.html
 http://ftp.digitalmars.com/dmd.1.024.zip
 
 http://www.digitalmars.com/d/changelog.html
 http://ftp.digitalmars.com/dmd.2.008.zip

Neat! What does the typeof(return) type specifier do?
Nov 28 2007
next sibling parent reply Lutger <lutger.blijdestijn gmail.com> writes:
Lutger wrote:
 Walter Bright wrote:
 New const/invariant in 2.007!

 http://www.digitalmars.com/d/1.0/changelog.html
 http://ftp.digitalmars.com/dmd.1.024.zip

 http://www.digitalmars.com/d/changelog.html
 http://ftp.digitalmars.com/dmd.2.008.zip

Neat! What does the typeof(return) type specifier do?

I found it, nevermind. (inside a function, evaluates to the return type). That's a pretty convenient addition for generic code.
Nov 28 2007
parent Walter Bright <newshound1 digitalmars.com> writes:
Lutger wrote:
  > I found it, nevermind.  (inside a function, evaluates to the return 
type).
 
 That's a pretty convenient addition for generic code.

It's another of Andrei's ideas :-)
Nov 28 2007
prev sibling parent Walter Bright <newshound1 digitalmars.com> writes:
Lutger wrote:
 What does the typeof(return) type specifier do?

It's replaced with the type of the return value of the function you're in.
Nov 28 2007
prev sibling next sibling parent "Simen Haugen" <simen norstat.no> writes:
I have found a bug similar to 1665. It only happens when compiling with -O 
and the error:
Internal error: ..\ztc\cgcod.c 1523

I haven't been able to create any sample code...


"Walter Bright" <newshound1 digitalmars.com> wrote in message 
news:fiiu78$1sf5$1 digitalmars.com...
 New const/invariant in 2.007!

 http://www.digitalmars.com/d/1.0/changelog.html
 http://ftp.digitalmars.com/dmd.1.024.zip

 http://www.digitalmars.com/d/changelog.html
 http://ftp.digitalmars.com/dmd.2.008.zip 

Nov 28 2007
prev sibling next sibling parent reply korogu <trekontiki hotmail.com> writes:
Walter Bright Wrote:

 New const/invariant in 2.007!
 
 http://www.digitalmars.com/d/1.0/changelog.html
 http://ftp.digitalmars.com/dmd.1.024.zip
 
 http://www.digitalmars.com/d/changelog.html
 http://ftp.digitalmars.com/dmd.2.008.zip

Version 2.007 worked fine, but trying to run 2.008 I got : dmd: /lib/tls/libc.so.6: version `GLIBC_2.4' not found (required by dmd) How can i correct that :-s ?
Nov 28 2007
next sibling parent reply Walter Bright <newshound1 digitalmars.com> writes:
korogu wrote:
 Version 2.007 worked fine, but trying to run 2.008 I got :
 
 dmd: /lib/tls/libc.so.6: version `GLIBC_2.4' not found (required by dmd)
 
 How can i correct that :-s ?
 

This versin of dmd was compiled with the latest ubuntu, which probably uses the latest C runtime library. So can you install the latest C shared runtime library?
Nov 28 2007
next sibling parent reply BCS <BCS pathlink.com> writes:
Walter Bright wrote:
 korogu wrote:
 
 Version 2.007 worked fine, but trying to run 2.008 I got :

 dmd: /lib/tls/libc.so.6: version `GLIBC_2.4' not found (required by dmd)

 How can i correct that :-s ?

This versin of dmd was compiled with the latest ubuntu, which probably uses the latest C runtime library. So can you install the latest C shared runtime library?

I can't (OTOH I haven't tried using it yet but I'm using a rather old copy of linux)
Nov 28 2007
parent reply Walter Bright <newshound1 digitalmars.com> writes:
BCS wrote:
 Walter Bright wrote:
 This versin of dmd was compiled with the latest ubuntu, which probably 
 uses the latest C runtime library. So can you install the latest C 
 shared runtime library?

I can't (OTOH I haven't tried using it yet but I'm using a rather old copy of linux)

Why not?
Nov 28 2007
parent reply BCS <BCS pathlink.com> writes:
Walter Bright wrote:
 BCS wrote:
 
 Walter Bright wrote:

 This versin of dmd was compiled with the latest ubuntu, which 
 probably uses the latest C runtime library. So can you install the 
 latest C shared runtime library?

I can't (OTOH I haven't tried using it yet but I'm using a rather old copy of linux)

Why not?

Laziness/incompetence mostly. Actually it has no Internet connection so I would have to play a few fun games to get anything done. Come to think of it though, I do have 2 blank hard drive in it that I could play with.... Short version is it would be a pain. If you can build DMD with stuff that won't require people to update it would save a lot of effort for a bunch of people.
Nov 28 2007
next sibling parent reply Sean Kelly <sean f4.ca> writes:
BCS wrote:
 
 Short version is it would be a pain. If you can build DMD with stuff 
 that won't require people to update it would save a lot of effort for a 
 bunch of people.

I had to downgrade to get DMD working on Linux before this release, so it's a matter of perspective. Sean
Nov 28 2007
parent Sean Kelly <sean f4.ca> writes:
Sean Kelly wrote:
 BCS wrote:
 Short version is it would be a pain. If you can build DMD with stuff 
 that won't require people to update it would save a lot of effort for 
 a bunch of people.

I had to downgrade to get DMD working on Linux before this release, so it's a matter of perspective.

Hm, I take it back. I don't have glibc 2.4 on my system after all. Sean
Nov 28 2007
prev sibling parent reply Walter Bright <newshound1 digitalmars.com> writes:
BCS wrote:
 Laziness/incompetence mostly. Actually it has no Internet connection so 
 I would have to play a few fun games to get anything done.
 
 Come to think of it though, I do have 2 blank hard drive in it that I 
 could play with....
 
 Short version is it would be a pain. If you can build DMD with stuff 
 that won't require people to update it would save a lot of effort for a 
 bunch of people.

When I built dmd with the old library, then people with the modern ubuntu had to go find the old C shared library and install that. So somebody will be inconvenienced. I think it's better to make things painless for people using the latest linux.
Nov 28 2007
parent BCS <BCS pathlink.com> writes:
Walter Bright wrote:

 I think it's better to make things 
 painless for people using the latest linux.

with modifications (s/the latest/reasonably recent/) I'll grant the point. I don't think catering to the bleeding edge is a good idea (I /don't/ think that's what you are saying). I'd personally go with the oldest version that will work with up to date systems.
Nov 28 2007
prev sibling next sibling parent korogu <trekontiki hotmail.com> writes:
Walter Bright Wrote:

 korogu wrote:
 Version 2.007 worked fine, but trying to run 2.008 I got :
 
 dmd: /lib/tls/libc.so.6: version `GLIBC_2.4' not found (required by dmd)
 
 How can i correct that :-s ?
 

This version of dmd was compiled with the latest ubuntu, which probably uses the latest C runtime library. So can you install the latest C shared runtime library?

Is it the package called "libc6" ? I updated to the latest available version, 2.3.6-0ubuntu20.5 Same error message ...
Nov 28 2007
prev sibling parent reply Markus Dittrich <markusle gmail.com> writes:
Walter Bright Wrote:

 korogu wrote:
 Version 2.007 worked fine, but trying to run 2.008 I got :
 
 dmd: /lib/tls/libc.so.6: version `GLIBC_2.4' not found (required by dmd)
 
 How can i correct that :-s ?
 

This versin of dmd was compiled with the latest ubuntu, which probably uses the latest C runtime library. So can you install the latest C shared runtime library?

It looks like the only symbol requiring >=glibc-2.4 in the binary is [dittrich despina] readelf -s ./dmd.bin | grep GLIBC_2.4 69: 00000000 70 FUNC GLOBAL DEFAULT UND __stack_chk_fail GLIBC_2.4 (10) which probably means that you used "-fstack-protector" or sth similar to compile the dmd source. Without it, the requirement for a newer glibc may actually go away. Otherwise, dmd.bin could also be distributed as a static binary at the cost of a (much) larger filesize. Markus
Nov 28 2007
next sibling parent reply Walter Bright <newshound1 digitalmars.com> writes:
Markus Dittrich wrote:
 It looks like the only symbol requiring >=glibc-2.4 in the binary is
 
 [dittrich despina] readelf -s ./dmd.bin | grep GLIBC_2.4
     69: 00000000    70 FUNC    GLOBAL DEFAULT  UND __stack_chk_fail GLIBC_2.4
(10)
 
 which probably means that you used "-fstack-protector" or sth similar to
compile the
 dmd source. Without it, the requirement for a newer glibc may actually go
away. 
 Otherwise, dmd.bin could also be distributed as a static binary at the cost of
a (much)
 larger filesize. 

I didn't use that switch. Hmm, do both 1.0 and 2.0 dmd's have this problem?
Nov 28 2007
parent Markus Dittrich <markusle gmail.com> writes:
Walter Bright Wrote:

 Markus Dittrich wrote:
 It looks like the only symbol requiring >=glibc-2.4 in the binary is
 
 [dittrich despina] readelf -s ./dmd.bin | grep GLIBC_2.4
     69: 00000000    70 FUNC    GLOBAL DEFAULT  UND __stack_chk_fail GLIBC_2.4
(10)
 
 which probably means that you used "-fstack-protector" or sth similar to
compile the
 dmd source. Without it, the requirement for a newer glibc may actually go
away. 
 Otherwise, dmd.bin could also be distributed as a static binary at the cost of
a (much)
 larger filesize. 

I didn't use that switch. Hmm, do both 1.0 and 2.0 dmd's have this problem?

The only thing I can think of right now is that some distros may patch their gcc specs such that certain flags are being applied by default without user interaction. But I don't know if this is the case for ubuntu since I've never used it. You could always try to explicitly turn it off via "-fno-stack-protector" (assuming that your gcc has this flag, mine does) and see if that symbol goes away. cheers, Markus
Nov 28 2007
prev sibling parent Markus Dittrich <markusle gmail.com> writes:
Brad Roberts Wrote:
 
 You can't link libc statically (for glibc at least, other os' do allow it) 
 any more.  I forget the last version that supported it, but it might well 
 be prior to 2.4.  Either way, it's not considered supported to build 
 against version X of glibc and run it against any version < X, only >= 
 even if it happens to not link against a versioned symbol (not all symbols 
 are versioned).

Yeah, you are absolutely correct - static linking won't work for glibc. My bad :( Markus
Nov 28 2007
prev sibling next sibling parent Brad Roberts <braddr puremagic.com> writes:
On Wed, 28 Nov 2007, Walter Bright wrote:

 BCS wrote:
 Laziness/incompetence mostly. Actually it has no Internet connection so I
 would have to play a few fun games to get anything done.
 
 Come to think of it though, I do have 2 blank hard drive in it that I could
 play with....
 
 Short version is it would be a pain. If you can build DMD with stuff that
 won't require people to update it would save a lot of effort for a bunch of
 people.

When I built dmd with the old library, then people with the modern ubuntu had to go find the old C shared library and install that. So somebody will be inconvenienced. I think it's better to make things painless for people using the latest linux.

Careful.. details here are important. The past releases have needed an older version of libstdc++, the c++ runtime (primarily stl). It's easy to have multiple versions of libstdc++ installed and all distributions package several of them for just this situation. This current release apparantly needs libc 2.4 or greater. libc tends to be great at backwards compatibility (ie, running apps built against 2.2 can still run against installations with 2.4), but the reverse isn't true. It's either very hard or practically impossible to have multiple versions of libc installed and upgrading it is usually only done during whole os updates. As a case in point, would you upgrade your old box's libc in isolation? Probably not. Either way, this change in the 1.x series seems inappropriate. It might be ok for 2.x, though will cost some number of adopters to put it off for a later date. Later, Brad
Nov 28 2007
prev sibling parent Brad Roberts <braddr puremagic.com> writes:
On Wed, 28 Nov 2007, Markus Dittrich wrote:

 Walter Bright Wrote:
 
 korogu wrote:
 Version 2.007 worked fine, but trying to run 2.008 I got :
 
 dmd: /lib/tls/libc.so.6: version `GLIBC_2.4' not found (required by dmd)
 
 How can i correct that :-s ?
 

This versin of dmd was compiled with the latest ubuntu, which probably uses the latest C runtime library. So can you install the latest C shared runtime library?

It looks like the only symbol requiring >=glibc-2.4 in the binary is [dittrich despina] readelf -s ./dmd.bin | grep GLIBC_2.4 69: 00000000 70 FUNC GLOBAL DEFAULT UND __stack_chk_fail GLIBC_2.4 (10) which probably means that you used "-fstack-protector" or sth similar to compile the dmd source. Without it, the requirement for a newer glibc may actually go away. Otherwise, dmd.bin could also be distributed as a static binary at the cost of a (much) larger filesize. Markus

You can't link libc statically (for glibc at least, other os' do allow it) any more. I forget the last version that supported it, but it might well be prior to 2.4. Either way, it's not considered supported to build against version X of glibc and run it against any version < X, only >= even if it happens to not link against a versioned symbol (not all symbols are versioned). Later, Brad
Nov 28 2007
prev sibling next sibling parent "Jarrett Billingsley" <kb3ctd2 yahoo.com> writes:
"Walter Bright" <newshound1 digitalmars.com> wrote in message 
news:fiiu78$1sf5$1 digitalmars.com...
 New const/invariant in 2.007!

 http://www.digitalmars.com/d/1.0/changelog.html
 http://ftp.digitalmars.com/dmd.1.024.zip

 http://www.digitalmars.com/d/changelog.html
 http://ftp.digitalmars.com/dmd.2.008.zip

"Changed the way coverage analysis is done so it is independent of order dependencies among modules." !! Oh man, thank God for this.
Nov 28 2007
prev sibling next sibling parent reply Carlos Santander <csantander619 gmail.com> writes:
Walter Bright escribió:
 New const/invariant in 2.007!
 
 http://www.digitalmars.com/d/1.0/changelog.html
 http://ftp.digitalmars.com/dmd.1.024.zip
 
 http://www.digitalmars.com/d/changelog.html
 http://ftp.digitalmars.com/dmd.2.008.zip

I hope nobody gets offended by this, but I don't like that Phobos is mimicking the C++ STL so much. In a way, it seems to be losing its D flavor. -- Carlos Santander Bernal
Nov 28 2007
parent Walter Bright <newshound1 digitalmars.com> writes:
Carlos Santander wrote:
 I hope nobody gets offended by this, but I don't like that Phobos is 
 mimicking the C++ STL so much. In a way, it seems to be losing its D 
 flavor.

That is a deliberate choice. My problem with the STL is not its ideas, which are sound, but the un-aesthetic implementation.
Nov 28 2007
prev sibling next sibling parent reply Tom S <h3r3tic remove.mat.uni.torun.pl> writes:
Walter Bright wrote:
 New const/invariant in 2.007!
 
 http://www.digitalmars.com/d/1.0/changelog.html
 http://ftp.digitalmars.com/dmd.1.024.zip
 
 http://www.digitalmars.com/d/changelog.html
 http://ftp.digitalmars.com/dmd.2.008.zip

Awesome! Thanks Walter :) BTW, 1.024 is the sexiest version number so far ;D -- Tomasz Stachowiak http://h3.team0xf.com/ h3/h3r3tic on #D freenode
Nov 28 2007
parent Daniel Keep <daniel.keep.lists gmail.com> writes:
Tom S wrote:
 Walter Bright wrote:
 New const/invariant in 2.007!

 http://www.digitalmars.com/d/1.0/changelog.html
 http://ftp.digitalmars.com/dmd.1.024.zip

 http://www.digitalmars.com/d/changelog.html
 http://ftp.digitalmars.com/dmd.2.008.zip

Awesome! Thanks Walter :) BTW, 1.024 is the sexiest version number so far ;D

Happy Version (2**10)/(10**3)! -- Daniel
Nov 28 2007
prev sibling next sibling parent reply guslay <guslay gmail.com> writes:
I have noticed that the status of some bugs listed in the changelog of the
release are not marked as fixed in bugzilla.

g.
Nov 28 2007
parent reply Brad Roberts <braddr puremagic.com> writes:
On Wed, 28 Nov 2007, guslay wrote:

 I have noticed that the status of some bugs listed in the changelog of the
release are not marked as fixed in bugzilla.
 
 g.

Bugs aren't always marked resolved right away (there's usually a day or two lag which gives reporters time to confirm and object to the fix if it's not actually fixed). If they're your bug reports and you can confirm that the issues are indeed resolved, then feel free to go ahead and mark them resolved. Later, Brad
Nov 28 2007
parent Jason House <jason.james.house gmail.com> writes:
Brad Roberts wrote:

 On Wed, 28 Nov 2007, guslay wrote:
 
 I have noticed that the status of some bugs listed in the changelog of
 the release are not marked as fixed in bugzilla.
 
 g.

Bugs aren't always marked resolved right away (there's usually a day or two lag which gives reporters time to confirm and object to the fix if it's not actually fixed). If they're your bug reports and you can confirm that the issues are indeed resolved, then feel free to go ahead and mark them resolved. Later, Brad

I'd hope the submitter doesn't just close the bugs. After many past issues with the GC, I was very interested in seeing more description about how the long-standing issues were fixed.
Nov 29 2007
prev sibling parent reply Christopher Wright <dhasenan gmail.com> writes:
Walter, you snuck in a change to implicit template arguments, didn't you?

The following works now but failed before:
template Foo (U : Bar!(T), T) {
     pragma (msg, T.stringof);
     const bool Foo = false;
}

class Bar (T) {
     T value;
}

void main () {
     auto f = Foo!(Bar!(long));
}

Now I can fake C# attributes for classes using interfaces:
interface IFoo : ImplementedBy!(Foo) {}

Though it only works for types, so I can't do:
class Bar : DbTable!("DatabaseTableForBar") {}
Dec 04 2007
parent reply Christopher Wright <dhasenan gmail.com> writes:
Okay, that all works, but only in a shallow manner. If you add the 
following, it doesn't compile:

class Something : Bar!(int) {}
bool b = Foo!(Something);

A pity, that. No faking attributes yet.

Christopher Wright wrote:
 Walter, you snuck in a change to implicit template arguments, didn't you?
 
 The following works now but failed before:
 template Foo (U : Bar!(T), T) {
     pragma (msg, T.stringof);
     const bool Foo = false;
 }
 
 class Bar (T) {
     T value;
 }
 
 void main () {
     auto f = Foo!(Bar!(long));
 }
 
 Now I can fake C# attributes for classes using interfaces:
 interface IFoo : ImplementedBy!(Foo) {}
 
 Though it only works for types, so I can't do:
 class Bar : DbTable!("DatabaseTableForBar") {}

Dec 04 2007
parent reply Christopher Wright <dhasenan gmail.com> writes:
Christopher Wright wrote:
 Okay, that all works, but only in a shallow manner. If you add the 
 following, it doesn't compile:
 
 class Something : Bar!(int) {}
 bool b = Foo!(Something);
 
 A pity, that. No faking attributes yet.

Also, it doesn't work with is expressions (the spec strongly implies that it should), and you can't differentiate templates based on it. I get the feeling this isn't going to be fixed very soon, but I'll file a bug.
Dec 04 2007
parent Walter Bright <newshound1 digitalmars.com> writes:
Christopher Wright wrote:
 Also, it doesn't work with is expressions (the spec strongly implies 
 that it should), and you can't differentiate templates based on it. I 
 get the feeling this isn't going to be fixed very soon, but I'll file a 
 bug.

Yes, please file a bug on bugzilla with canonical examples. That will help a lot.
Dec 04 2007