Package eu.bandm.tools.d2d2.base
Class Resolver.FirstCalculator
java.lang.Object
eu.bandm.tools.d2d2.model.MATCH_ONLY_00
eu.bandm.tools.d2d2.model.SinglePhase
eu.bandm.tools.d2d2.base.Navigate.VisitReachable<Object>
eu.bandm.tools.d2d2.base.Resolver.FirstCalculator
- Enclosing class:
- Resolver
Sets up constants in each
Visiting starts with the (externally requested) top-level module and follows ONLY references (to declarations contained anywhere!) ATTENTION: Does NOT visit the expressions X in "import _ from _ ^ ( X / _)"
Expression
, which cache
structural properties of the syntax for later parsing.
- The ".firsts : String -> (Expression+int)" director map (this points to sub-expressions of an ALT or PERM or to starting position numbers of a SEQU!)
- whether character data is accepted
- whether epsilon accepted
Visiting starts with the (externally requested) top-level module and follows ONLY references (to declarations contained anywhere!) ATTENTION: Does NOT visit the expressions X in "import _ from _ ^ ( X / _)"
-
Field Summary
Fields inherited from class eu.bandm.tools.d2d2.base.Navigate.VisitReachable
done, result, todo
Fields inherited from class eu.bandm.tools.d2d2.model.MATCH_ONLY_00
_visitor_debug_stream, partial
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
void
action
(CharsRegExp def) void
void
action
(Enumeration def) void
void
void
void
void
void
Put "tag->expr" into directors' map for later parsing.void
void
void
action
(TagsRegExp def) protected void
addFromTo
(Expression from, Expression to, boolean isalt) From is the "sub"-expression FROM which the director map is copied inTO the map ruling the "super"-expression called "to".protected void
(package private) boolean
isDone
(Expression exp) protected void
LL1_violation
(String s, Expression from, Expression to) protected void
makeGenericHints
(String genname, Module referingMod, String modname) protected void
makeGenericHints
(String genname, XRegExp referrer, Definition referred) Methods inherited from class eu.bandm.tools.d2d2.base.Navigate.VisitReachable
markToDo, markToDo, process, process, processAll, processPublic
Methods inherited from class eu.bandm.tools.d2d2.model.SinglePhase
action, action, action, action, action, action, action, action, action, action, action, action, action, action, action, action, action, action, action, action, action, action, action, action, action, descend_ImportItem$globalSubsts, descend_ImportItem$localSubsts, descend_Module$definitions, descend_Module$imports, descend_Module$modules, descend_TagsRegExp$localdefs
Methods inherited from class eu.bandm.tools.d2d2.model.MATCH_ONLY_00
_visitor_trace, action, action, action, action, compile, descend_Alt$on, descend_Perm$on, descend_Seq$on, foreignObject, match, match, match, match, match, match, match, match, match, match, match, match, match, match, match, match, match, match, match, match, match, match, match, match, match, match, match, match, match, match, match, match, match, match, match, match, match, match, match, nomatch
-
Field Details
-
currentdef
TagsRegExp currentdef
-
-
Constructor Details
-
FirstCalculator
public FirstCalculator()
-
-
Method Details
-
action
- Overrides:
action
in classSinglePhase
-
action
- Overrides:
action
in classSinglePhase
-
action
- Overrides:
action
in classSinglePhase
-
isDone
-
action
- Overrides:
action
in classSinglePhase
-
action
- Overrides:
action
in classSinglePhase
-
action
- Overrides:
action
in classSinglePhase
-
makeGenericHints
-
makeGenericHints
-
action
Put "tag->expr" into directors' map for later parsing.
Attention: Use the name of the referred to declaration object, which is a kind of "d2d-tag" with possibly local scope. Do NOT use the refering source text, which already has been normlized to module level scope.
References can refer to Tags, Chars and Enumerations !- Overrides:
action
in classSinglePhase
-
copyMult
-
action
- Overrides:
action
in classSinglePhase
-
action
- Overrides:
action
in classSinglePhase
-
action
- Overrides:
action
in classSinglePhase
-
LL1_violation
-
addFromTo
From is the "sub"-expression FROM which the director map is copied inTO the map ruling the "super"-expression called "to". -
action
- Overrides:
action
in classSinglePhase
-
action
- Overrides:
action
in classSinglePhase
-
action
- Overrides:
action
in classSinglePhase
-