The Trunk: 61Deprecated-ct.26.mcz
| Newsgroups | gmane.comp.lang.smalltalk.squeak.general |
|---|---|
| Message-ID | <[email protected]> |
Christoph Thiede uploaded a new version of 61Deprecated to project The Trunk: http://source.squeak.org/trunk/61Deprecated-ct.26.mcz ==================== Summary ==================== Name: 61Deprecated-ct.26 Author: ct Time: 6 May 2026, 8:56:31.179972 pm UUID: ff272803-9483-4118-a8ab-c2c272cd3f97 Ancestors: 61Deprecated-ct.25 Merges and revises BrokenPromise-compat to add backward compatibility for BrokenPromise. See: https://lists.squeakfoundation.org/archives/list/[email protected]/thread/BHBVRXIXUFGXDLIAFGLBBZ2LCX4OKYGD/ Revision: Also adds proper deprecation for removed Promise>>error and BrokenPromise>>error via #errorValue. =============== Diff against 61Deprecated-ct.25 =============== Item was changed: SystemOrganization addCategory: #'61Deprecated-ST80-Support'! SystemOrganization addCategory: #'61Deprecated-Morphic-Support'! SystemOrganization addCategory: #'61Deprecated-Etoys-Squeakland-Tools-Process Browser'! + SystemOrganization addCategory: #'61Deprecated-Kernel-Exceptions'! Item was added: + Notification subclass: #BrokenPromise + instanceVariableNames: 'promise' + classVariableNames: '' + poolDictionaries: '' + category: '61Deprecated-Kernel-Exceptions'! + + !BrokenPromise commentStamp: 'tonyg 2/17/2017 13:53' prior: 0! + I am signalled when, during a Promise>>wait, the promise is rejected. + promise: the promise itself. + ! Item was added: + ----- Method: BrokenPromise class>>handles: (in category 'exceptionSelector') ----- + handles: exception + + ^ (super handles: exception) + ifTrue: [Deprecation signal: 'BrokenPromise is deprecated. Handle Error instead. See: https://lists.squeakfoundation.org/archives/list/[email protected]/thread/BHBVRXIXUFGXDLIAFGLBBZ2LCX4OKYGD/']; + yourself! Item was added: + ----- Method: BrokenPromise>>defaultAction (in category 'priv handling') ----- + defaultAction + + ^ #ignored! Item was added: + ----- Method: BrokenPromise>>error (in category 'accessing') ----- + error + + self deprecated: 'To retrieve the error value of a broken promise, send #errorValue. To signal a new error, please send #error to a different object or super.'. + ^ self errorValue! Item was added: + ----- Method: BrokenPromise>>errorValue (in category 'accessing') ----- + errorValue + + ^ promise ifNotNil: [promise errorValue]! Item was added: + ----- Method: BrokenPromise>>messageText (in category 'accessing') ----- + messageText + + ^ messageText ifNil: + [self error ifNotNil: [:error | + error asString]]! Item was added: + ----- Method: BrokenPromise>>promise (in category 'accessing') ----- + promise + ^ promise! Item was added: + ----- Method: BrokenPromise>>promise: (in category 'accessing') ----- + promise: aPromise + promise := aPromise! Item was added: + ----- Method: Promise>>error (in category '*61Deprecated-accessing') ----- + error + + self deprecated: 'To retrieve the error value of a promise, send #errorValue. To signal a new error, please send #error to a different object or super.'. + ^ self errorValue! Squeak-dev mailing list -- [email protected] To unsubscribe send an email to [email protected]