Skip to content
This repository has been archived by the owner on Oct 12, 2022. It is now read-only.

@disable TypeInfo.init #1766

Merged
merged 2 commits into from Mar 13, 2017
Merged

Conversation

aG0aep6G
Copy link
Contributor

As planned (one release behind schedule).

@aG0aep6G
Copy link
Contributor Author

I'm not sure if I got the changelog entry right. The README.md didn't actually tell me to create a file, but that's the plan, right? When I build ../dlang.org/web/changelog/pending.html as instructed, my entry doesn't show up. The doc tester doesn't show it either. Maybe the tooling isn't there yet?

@wilzbach
Copy link
Member

I'm not sure if I got the changelog entry right. The README.md didn't actually tell me to create a file, but that's the plan, right?

Yep - see Phobos for a couple of examples: https://github.com/dlang/phobos/tree/master/changelog

When I build ../dlang.org/web/changelog/pending.html as instructed, my entry doesn't show up.

Your problem is that the changelog entry doesn't end with .dd. It seems that the druntime changelog README is a bit outdated in comparison to Phobos: https://github.com/dlang/phobos/tree/master/changelog

For reference, that's how it looks once the file has the proper extension:

image

The doc tester doesn't show it either. Maybe the tooling isn't there yet?

Yep: dlang/dlang.org#1549

@aG0aep6G
Copy link
Contributor Author

Blocked by dmd tests using TypeInfo.init - dlang/dmd#6547.

Your problem is that the changelog entry doesn't end with .dd.

Fixed, thanks.

@aG0aep6G aG0aep6G force-pushed the disable-TypeInfo.init branch 2 times, most recently from 7815a1d to aca7193 Compare February 18, 2017 00:38
@aG0aep6G
Copy link
Contributor Author

Blocked by dmd tests using TypeInfo.init - dlang/dmd#6547.

That PR has been merged. auto-tester is turning green. So this should be good to go. I've squashed the fixup commit.

@rainers
Copy link
Member

rainers commented Feb 18, 2017

You should also update dmd not to use TypeInfo.init, as the travis build for dmd rebuilds itself, see for example https://travis-ci.org/dlang/dmd/jobs/202809672#L5264.

@aG0aep6G
Copy link
Contributor Author

You should also update dmd not to use TypeInfo.init, as the travis build for dmd rebuilds itself, see for example https://travis-ci.org/dlang/dmd/jobs/202809672#L5264.

dlang/dmd#6550

@aG0aep6G
Copy link
Contributor Author

Alright, we have a problem here. dlang/dmd#6550 fails because the test bots use relatively old releases to build dmd. Those don't have TypeInfo.initializer, so they fail.

I'm not sure, is there an older release that's deemed stable, which is supposed to be able to build all newer releases? If so, can we bump that to a newer one or make a point release for it? If not, can we just make the bots use newer versions?

@wilzbach
Copy link
Member

I'm not sure, is there an older release that's deemed stable, which is supposed to be able to build all newer releases? If so, can we bump that to a newer one or make a point release for it? If not, can we just
make the bots use newer versions?

That would be 2.072.2. For Travis and CircleCi this is already used at the dmd repo (though not for druntime and phobos, but the bump is in the queue: dlang/phobos#5140, #1725)

However as the auto-tester (and GDC) still use an old frontend, you should definitely see this discussion http://forum.dlang.org/thread/FA142E6B-DD11-43F6-8EF9-EEC72AA1A7F2@klickverbot.at

@aG0aep6G
Copy link
Contributor Author

That would be 2.072.2.

2.072 is not a long-term support version, is it? Anyway, 2.072 is fine, as TypeInfo.initializer has been added in 2.070.0. Trouble is with anything older than that.

However as the auto-tester (and GDC) still use an old frontend

The auto-tester and the doc tester are the real problem. If gdc is supposed to be able to build dmd, then it needs updating too. Question is how do I get TypeInfo.initializer into the testers (and maybe gdc)?

@PetarKirov
Copy link
Member

@ibuclaw @jpf91 we would like to move forward with removing TypeInfo.init. Any chance of cherrypicking the druntime change from #1403 into GDC, so we can bump the minimum compiler version that is used to build DMD?

CC @MartinNowak

@ibuclaw
Copy link
Member

ibuclaw commented Feb 23, 2017

GDC is not affected by this as far as I can see, the dmd builds are still passing on travisci.

@wilzbach wilzbach added this to the 2.074.0 milestone Mar 5, 2017
@aG0aep6G
Copy link
Contributor Author

dlang/dmd#6550 has been merged. Testers are green. Regarding dmd, this should be good to go.

gdc still uses the C frontend, so it should not be affected.

ldc will have to incorporate dlang/dmd#6550 to be be buildable by dmd 2.074. I've tried to cherry pick it, but the path to rmem.d is different in ldc and that makes things weird. @klickverbot: Please advise or take over.

@@ -0,0 +1,6 @@
TypeInfo.init has been `@disable`d.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Perhaps write this out as init() to make clear that this is referring to the property function?

@@ -0,0 +1,6 @@
TypeInfo.init has been `@disable`d.

This is a step towards removal of `TypeInfo.init`, which is necessary to resolve
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe phrase this in a more direct and comprehensive way to give people who have not been following the process enough to make sense of the change? Something like:

TypeInfo.init() (deprecated since 2.0XX) collides with the built-in type property of the same name and will be removed in XXX. To get the default initializer of the described type, use TypeInfo.initializer instead.

(Okay, that isn't much of an improvement either, but I hope it gets my point across.)

Copy link
Member

@dnadlinger dnadlinger left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is fine from an LDC perspective.

If we wanted to be cautious about reducing the number of future bootstrapping steps, we would make sure that jump straight past this change from the last C++ compiler, but we can always do this by pushing out appropriate LDC patch releases if necessary.

@aG0aep6G aG0aep6G force-pushed the disable-TypeInfo.init branch 2 times, most recently from 88d380d to a4616e8 Compare March 13, 2017 16:02
@aG0aep6G
Copy link
Contributor Author

I've tweaked the changelog entry a bit, reacting to @klickverbot's comments, hopefully making things clearer. I don't really care about the exact words. Please feel free to just edit it, if you think it can be improved.


This is fine from an LDC perspective.

Alright. Looks like we're all set then.

@MartinNowak
Copy link
Member

If we wanted to be cautious about reducing the number of future bootstrapping steps, we would make sure that jump straight past this change from the last C++ compiler

Bootstrapping will really only remain feasible via cross-compilation. It's just unrealistic to assume that we can rebuild every intermediate compiler in 10 years (not to mention the crazy amount of steps).

@MartinNowak MartinNowak merged commit ffe3a95 into dlang:master Mar 13, 2017
@aG0aep6G aG0aep6G deleted the disable-TypeInfo.init branch March 14, 2017 15:57
nemanja-boric-sociomantic added a commit to nemanja-boric-sociomantic/swarm-1 that referenced this pull request Jan 19, 2018
TypeInfo_Class.init is deprecated and removed from the runtime (since
.init clashes with the type property of the same name). This uses
`initializer()` method which is the new way of accessing the same thing
in D2.

dlang/druntime#1403
dlang/druntime#1766
dlang/druntime#1807

https://issues.dlang.org/show_bug.cgi?id=15037
https://issues.dlang.org/show_bug.cgi?id=12233
gavin-norman-sociomantic pushed a commit to sociomantic-tsunami/swarm that referenced this pull request Jan 19, 2018
TypeInfo_Class.init is deprecated and removed from the runtime (since
.init clashes with the type property of the same name). This uses
`initializer()` method which is the new way of accessing the same thing
in D2.

dlang/druntime#1403
dlang/druntime#1766
dlang/druntime#1807

https://issues.dlang.org/show_bug.cgi?id=15037
https://issues.dlang.org/show_bug.cgi?id=12233
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
7 participants