Thread overview | ||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
August 06, 2013 Phobos and older DMD versions | ||||
---|---|---|---|---|
| ||||
My recent pull request [0] triggered some issue, which should get a bigger discussion: Should Phobos version N also compile with DMD N-1? In my opinion it should, because it makes Phobos development simpler. You don't need a self compiled dmd to fix bugs. However, reality sometimes requires exceptions. I understand that sometimes Phobos uses a feature of dmd HEAD. That is why I said "should", but not "must". ;) [0] https://github.com/D-Programming-Language/phobos/pull/1454/files#r5601514 |
August 06, 2013 Re: Phobos and older DMD versions | ||||
---|---|---|---|---|
| ||||
Posted in reply to qznc | On Tuesday, 6 August 2013 at 14:51:35 UTC, qznc wrote:
> In my opinion it should, because it makes Phobos development simpler. You don't need a self compiled dmd to fix bugs.
On a related note, I think providing compiled daily/weekly master builds is a good idea. They are compiled by the auto tester anyway, right?
|
August 06, 2013 Re: Phobos and older DMD versions | ||||
---|---|---|---|---|
| ||||
Posted in reply to Mr. Anonymous | On Tuesday, 6 August 2013 at 14:56:43 UTC, Mr. Anonymous wrote:
> On Tuesday, 6 August 2013 at 14:51:35 UTC, qznc wrote:
>> In my opinion it should, because it makes Phobos development simpler. You don't need a self compiled dmd to fix bugs.
>
> On a related note, I think providing compiled daily/weekly master builds is a good idea. They are compiled by the auto tester anyway, right?
This would definitely make life easier for me as I'm not in a position ATM to compile the latest D.
|
August 06, 2013 Re: Phobos and older DMD versions | ||||
---|---|---|---|---|
| ||||
Posted in reply to qznc | On Tuesday, 6 August 2013 at 14:51:35 UTC, qznc wrote:
> My recent pull request [0] triggered some issue, which should get a bigger discussion:
>
> Should Phobos version N also compile with DMD N-1?
>
> In my opinion it should, because it makes Phobos development simpler. You don't need a self compiled dmd to fix bugs.
>
> However, reality sometimes requires exceptions. I understand that sometimes Phobos uses a feature of dmd HEAD. That is why I said "should", but not "must". ;)
>
>
> [0] https://github.com/D-Programming-Language/phobos/pull/1454/files#r5601514
This doesn't sound related to the problem discussed. Phobos N must compile with DMD N, that is a primary requirement. If Phobos N compiles with DMD N-1, great but it can't fail in DMD N.
Now, if we step back from the principle of it. It would be good to require DMD N-1 to compile Phobos N because it would require careful thought in how to do translations. Instead of fixing the bug, prepare the compiler to accept the change that will be needed in Druntime.
That is of course the armchair statement, I think is something to strive for and if we're trying to do the "do what you would do if you had a million users," this is probably something we would do; where we is a couple hundred of the million users (oh we don't have that:).
|
August 06, 2013 Re: Phobos and older DMD versions | ||||
---|---|---|---|---|
| ||||
Posted in reply to qznc | On Tuesday, 6 August 2013 at 14:51:35 UTC, qznc wrote: > My recent pull request [0] triggered some issue, which should get a bigger discussion: > > Should Phobos version N also compile with DMD N-1? > > In my opinion it should, because it makes Phobos development simpler. You don't need a self compiled dmd to fix bugs. > > However, reality sometimes requires exceptions. I understand that sometimes Phobos uses a feature of dmd HEAD. That is why I said "should", but not "must". ;) > > > [0] https://github.com/D-Programming-Language/phobos/pull/1454/files#r5601514 The contribution guide should probably say it must build with DMD master because that's really the only requirement and the only thing the autotester checks against. It seems unlikely that the code in a pull request will ever make it into a DMD N-1 release so while it would be nice if it built with the current DMD stable release it's not really vital that it does. Until fairly recently I'd just use the latest dmd release when making phobos pull requests because building dmd always seemed to give me trouble. There are new guides and tools to help with this though. On Windows you might add a blurb about using the new bootstrap-dmd.bat[1] file Nick Sabalausky created. The wiki also has a guide that might be worth linking to that shows that helps you setup the peculiar (in my opinion) directory structure needed to build dmd, druntime, and phobos from git master[2]. You might also want to incorporate stuff from from the Pull Requests page on the wiki or link to it.[3] 1. https://github.com/D-Programming-Language/installer/blob/master/bootstrap/bootstrap-dmd.bat 2. http://wiki.dlang.org/Building_DMD 3. http://wiki.dlang.org/Pull_Requests |
August 06, 2013 Re: Phobos and older DMD versions | ||||
---|---|---|---|---|
| ||||
Posted in reply to Jesse Phillips | On Tuesday, 6 August 2013 at 16:02:31 UTC, Jesse Phillips wrote:
> On Tuesday, 6 August 2013 at 14:51:35 UTC, qznc wrote:
>> My recent pull request [0] triggered some issue, which should get a bigger discussion:
>>
>> Should Phobos version N also compile with DMD N-1?
>>
>> In my opinion it should, because it makes Phobos development simpler. You don't need a self compiled dmd to fix bugs.
>>
>> However, reality sometimes requires exceptions. I understand that sometimes Phobos uses a feature of dmd HEAD. That is why I said "should", but not "must". ;)
>>
>>
>> [0] https://github.com/D-Programming-Language/phobos/pull/1454/files#r5601514
>
> This doesn't sound related to the problem discussed. Phobos N must compile with DMD N, that is a primary requirement. If Phobos N compiles with DMD N-1, great but it can't fail in DMD N.
Correct, Phobos N with DMD N is a "must". The question is, whether Phobos N with DMD N-1 is a "should".
For the pull request, the question is what goes into the guidelines. That should be discussed there, instead of here in the forums. ;)
|
August 06, 2013 Re: Phobos and older DMD versions | ||||
---|---|---|---|---|
| ||||
Posted in reply to Jesse Phillips | On 2013-08-06 16:02:30 +0000, Jesse Phillips said:
> On Tuesday, 6 August 2013 at 14:51:35 UTC, qznc wrote:
>> My recent pull request [0] triggered some issue, which should get a bigger discussion:
>>
>> Should Phobos version N also compile with DMD N-1?
>>
>> In my opinion it should, because it makes Phobos development simpler. You don't need a self compiled dmd to fix bugs.
>>
>> However, reality sometimes requires exceptions. I understand that sometimes Phobos uses a feature of dmd HEAD. That is why I said "should", but not "must". ;)
>>
>>
>> [0] https://github.com/D-Programming-Language/phobos/pull/1454/files#r5601514
>
> This doesn't sound related to the problem discussed. Phobos N must compile with DMD N, that is a primary requirement. If Phobos N compiles with DMD N-1, great but it can't fail in DMD N.
>
> Now, if we step back from the principle of it. It would be good to require DMD N-1 to compile Phobos N because it would require careful thought in how to do translations. Instead of fixing the bug, prepare the compiler to accept the change that will be needed in Druntime.
>
> That is of course the armchair statement, I think is something to strive for and if we're trying to do the "do what you would do if you had a million users," this is probably something we would do; where we is a couple hundred of the million users (oh we don't have that:).
I think it should be fair to require the new compiler with the new stdlib. They are released in unison.
Andrei
|
August 07, 2013 Re: Phobos and older DMD versions | ||||
---|---|---|---|---|
| ||||
Posted in reply to qznc | On Tuesday, 6 August 2013 at 14:51:35 UTC, qznc wrote:
> My recent pull request [0] triggered some issue, which should get a bigger discussion:
>
> Should Phobos version N also compile with DMD N-1?
>
> In my opinion it should, because it makes Phobos development simpler. You don't need a self compiled dmd to fix bugs.
>
> However, reality sometimes requires exceptions. I understand that sometimes Phobos uses a feature of dmd HEAD. That is why I said "should", but not "must". ;)
>
>
> [0] https://github.com/D-Programming-Language/phobos/pull/1454/files#r5601514
One of the "big" problems is that a *lot* of bugs work this way:
1) Bug is discovered in Phobos
2) Fixing bug reveals a dmd bug
3) dmd is fixed
4) phobos is fixed
If phobos N had to work with DMD N-1, then development in phobos would simply grind to a halt.
It's not just about new features in DMD that phobos wants to use. dmd bugs are fixed for phobos, I'd say, on a twice by week basis (roughly).
|
August 07, 2013 Re: Phobos and older DMD versions | ||||
---|---|---|---|---|
| ||||
Posted in reply to qznc | On Tuesday, 6 August 2013 at 14:51:35 UTC, qznc wrote:
> My recent pull request [0] triggered some issue, which should get a bigger discussion:
>
> Should Phobos version N also compile with DMD N-1?
>
> In my opinion it should, because it makes Phobos development simpler. You don't need a self compiled dmd to fix bugs.
>
> However, reality sometimes requires exceptions. I understand that sometimes Phobos uses a feature of dmd HEAD. That is why I said "should", but not "must". ;)
>
>
> [0] https://github.com/D-Programming-Language/phobos/pull/1454/files#r5601514
Makes no sense to me.
1) DMD and Phobos are always released at the same time and share versioning.
2) It will require essentially doubling the load on pull request tester.
As you need to be sure your fix works on current DMD head anyway, you should have full custom environment anyway (dmd + druntime + phobos). It is quite easy to keep such development environment separate from system-wide dmd installation anyway.
|
August 07, 2013 Re: Phobos and older DMD versions | ||||
---|---|---|---|---|
| ||||
Posted in reply to Andrei Alexandrescu | On Tuesday, 6 August 2013 at 22:23:03 UTC, Andrei Alexandrescu wrote:
> I think it should be fair to require the new compiler with the new stdlib. They are released in unison.
>
> Andrei
I agree, but there is at least potential benefits from choosing previous compiler version. If a change in compiler requires a change in Phobos/druntime it also means a change in user code (at least I don't see why it wouldn't).
It would just be an extra layer to make upgrading from one compiler to another less likely to have unintended breaking changes. But this would be minor in comparison to the other steps which have been taken.
|
Copyright © 1999-2021 by the D Language Foundation