eXept Software AG Logo

Smalltalk/X Webserver

Documentation of class 'Parser::Correction':

Home

Documentation
www.exept.de
Everywhere
for:
[back]

Class: Correction (private in Parser

This class is only visible from within Parser.

Inheritance:

   Object
   |
   +--Parser::Correction
      |
      +--Parser::CorrectByChangingSelector
      |
      +--Parser::CorrectByDeclaringIdentifierAs
      |
      +--Parser::CorrectByDeletingLocalIdentifier
      |
      +--Parser::CorrectByGeneratingMissingMethod
      |
      +--Parser::CorrectByGroupingMessage
      |
      +--Parser::CorrectByInserting
      |
      +--Parser::CorrectByInteractiveCorrection
      |
      +--Parser::CorrectByInteractiveRename
      |
      +--Parser::CorrectByMakingValidHexConstant

Package:
stx:libcomp
Category:
System-Compiler
Owner:
Parser

Description:


a new correction scheme.

Previously, there were only 2 hardcoded interactive corrections possible when
the compiler had a correctbleError to report (declare as and correct).
The use was asked via the correctableError: message (to the requestor),
which had to return a symbol.

Now, we move to a more flexible correction scheme, where the parser provides a list
of plausible corrections as a collection of operations (actually class instances),
which provide button labels (and possibly addition information in the future).

Also, the correction object is supposed (in the future) to do the correction, so those
operations are to be moved out of the compiler.


Class protocol:

instance creation
o  instance

queries
o  buttonLabel


Instance protocol:

accessing
o  buttonLabel

correcting
o  fixFrom: position1 to: position2 for: aCompiler
to be redefined by subclasses.
should return corrected source or nil

ignored accessing
o  positionOfPeriod: ignored
intentionally ignore here

o  positionToInsert: charPosition
intentionally ignore here

o  receiverClass: ignoredClass
intentionally ignore here

o  receiverNode: ignoredNode
intentionally ignore here

o  selector: ignoredSelector
intentionally ignore here

instance creation
o  instance



ST/X 7.7.0.0; WebServer 1.702 at 20f6060372b9.unknown:8081; Sun, 26 May 2024 12:50:06 GMT