forked from chapel-lang/chapel
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request chapel-lang#5328 from vasslitvinov/switch-to-deinit()
Switched to using deinit() This is a follow-up to chapel-lang#5299. * Added a compiler warning that "~classname" names for deinitializers are deprecated. The warning is currently commented out. As before this change, users can use either name ("deinit" or "~classname") without warnings. We will enact the "~classname" warning for deinitializers when we do the same for "classname"-named initializers. * Switched from ~classname() to deinit() in our Chapel code base: modules, tests, spec. Left "~R" naming in printouts, to reduce the volume of changes. * Added a test that specifically tests ~classname() naming. * Renamed "destructors" to "deinitializers" throughout the spec. These changes are trivial, except for these non-trivial pieces: * Changed the spec text in that the destructor is called "deinit", not "~classname". * In learnChapelInYMinutes(), I also adjusted the comments on the constructor and destructor. Switched to "initializer" and "deinitializer" words proactively. Promised compiler-generated initializer according to the current world for constructors, and warned that it is going away soon. There is still "constructor" usage there that we need to change. * Left the old "~classname" naming in these tests: // to test "destructor name must match class/record name" warning classes/figueroa/BogusDestructors5 classes/figueroa/BogusDestructors7 // these test scanning or pasing "~" classes/diten/deleteDollar classes/diten/test_destroy2 // tests both new and old syntax classes/deinitializers/deinitAndDestruct r: @lydia-duncan
- Loading branch information
Showing
134 changed files
with
268 additions
and
218 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -132,7 +132,7 @@ module Futures { | |
} | ||
|
||
pragma "no doc" | ||
proc ~Future() { | ||
proc deinit() { | ||
release(); | ||
} | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.