2025-07-11 Rubén Rubio * makeGrammar.cc (MixfixModule::makeSpecialProductions): initialize variable to avoid reading garbage 2025-06-26 Rubén Rubio * view.cc (handleStratAwkwardCase): removed call to addStratMappingVarIndices 2025-06-18 Saruman the White * ooProcess.cc (SyntacticPreModule::processClassSorts): use Token::isValidSortName(); use markAsBad() so module can't be imported at the metalevel * process.cc (SyntacticPreModule::processSorts): use Token::isValidSortName(); use markAsBad() so module can't be imported at the metalevel (SyntacticPreModule::getSort): symmetric changes * token.hh (isValidSortName): added * process.cc (SyntacticPreModule::getSort): check for bad sort names for sorts that get added as a fix up (SyntacticPreModule::process): update comments now that multiple calls can markAsBad * ooProcess.cc (SyntacticPreModule::processClassSorts): check that class name is also a valid sort name * process.cc (SyntacticPreModule::processSorts): check that new sort if a valid sort name 2025-06-17 Saruman the White * token.cc (Token::split): don't consider : . inside correctly nested {}s as split point * makeGrammar.cc (MixfixModule::makeParameterizedSortProductions): added explanation of why nonterminals for lead tokens of structured sorts are needed (MixfixModule::makeComponentProductions): removed commented out code 2025-06-16 Saruman the White * makeGrammar.cc (MixfixModule::makeComponentProductions): deleted commented out code for variableTokenCode * auxProperty.cc (Token::skipSortName): fix comment; use nullptr 2025-06-16 Rubén Rubio * importModule.cc (donateStatements2): deal with strat->expr mapping on the LHS of a strategy expression 2025-06-15 Saruman the White * view.cc (View::evaluate): check for valid view name * token.cc (Token::isValidViewName): added * token.hh (class Token): added decl for isValidViewName() 2025-06-06 Saruman the White * top.yy: added innerToken * modules.yy (sortNameFrag): clear fragment buffer before we start using it rather than after we're done with it. This fixes a bug where a parsing error leaves crap in the fragment buffer (innerToken): added (innerFrag): use innerToken * auxProperty.cc (Token::skipSortName): allow . and :: in sort names if they are inside {} so as to permit . and :: in view names used to instantiate parameterized sorts (Token::computeAuxProperty): allow . and :: in sort names if they are inside {} when checking fo AUX_CONSTANT and AUX_VARIABLE properties 2025-05-30 Rubén Rubio * importTranslation.cc (ImportTranslation::translateStrategy): use Sort::FIRST_USER_SORT * instantiateViewWithFreeParameters.cc (View::handleStratAwkwardCase): use Sort::KIND and variable lifting at the kind level * view.cc (View::insertStratToExprMapping): removed deletes to avoid double free 2025-04-26 Saruman the White * renaming.cc (Renaming::typeMatch): converted commented out cerr << into a DebugInfo() * importTranslation.hh (ImportTranslation::translate): use Sort::FIRST_USER_SORT * renameModule.cc (ImportModule::localSort): use Sort::FIRST_USER_SORT * view.cc (View::mapComponent): use Sort::FIRST_USER_SORT (View::typeMatch): use Sort::FIRST_USER_SORT * importTranslation.cc (ImportTranslation::translateRegularSymbol): use Sort::FIRST_USER_SORT (ImportTranslation::findTargetVersionOfSymbol): use Sort::FIRST_USER_SORT * instantiateViewWithFreeParameters.cc (View::handleInstantiationByModuleView): pass toModule rather than parameterCopyOfTheory as the parameterCopyUser addOpMappingsFromView() and addStratMappingsFromView() to avoid missing sorts in the canonicalRenaming op->op and op->term types (View::handleInstantiationByTheoryView): symmetric change, passing toModule rather than parameterCopyOfParameterTheory 2025-04-24 Saruman the White * instantiateViewWithFreeParameters.cc (View::handleAwkwardCase): use liftVariablesToKind flag when synthesizing op->term mapping * importTranslation.cc (ImportTranslation::ImportTranslation): take liftVariablesToKind argument and set data member (ImportTranslation::translate): handle liftVariablesToKind flag * importTranslation.hh (class ImportTranslation): added liftVariablesToKind data member and ctor argument 2025-04-22 Saruman the White * view.cc (View::insertOpToTermMapping): formatting 2024-06-07 Steven M. Eker * importModule.cc (ImportModule::donateStatements2): copy extension flag for rules (ImportModule::donateStatements2): copy extension flag for equations * mixfixParser.cc (MixfixParser::makeStatementPart): set extension flag for rules (MixfixParser::makeStatementPart): set extension flag for equations (MixfixParser::makeStatementPart): warn about extension flag for membership axioms * latexModulePrint.cc (VisibleModule::latexPrintAttributes): handle extension argument (VisibleModule::latexPrintRule): pass extension flag to latexPrintAttributes() (VisibleModule::latexPrintMembershipAxiom): pass extension flag to latexPrintAttributes() (VisibleModule::latexPrintEquation): pass extension flag to latexPrintAttributes() * visibleModule.hh (class VisibleModule): updated decl for latexPrintAttributes() * mixfixParser.hh (enum Flags): added EXTENSION * mixfixParser.cc (MixfixParser::makeAttributePart): handle MAKE_EXTENSION_ATTRIBUTE * makeGrammar.cc (MixfixModule::makeAttributeProductions): handle extension * mixfixParser.hh (enum SemanticActions): added MAKE_EXTENSION_ATTRIBUTE * specialTokens.cc: added "extension" ===================================Maude163=========================================== 2024-05-20 Steven Eker * narrowing.cc (Interpreter::showMostGeneralStates): use \/ rather than /\ (Interpreter::showFrontierStates): ditto ===================================Maude162=========================================== 2024-05-17 Steven Eker * maudeLatexBuffer.hh (class MaudeLatexBuffer): added decl for generateStateSet() * latexResult.cc (MaudeLatexBuffer::generateStateSet): added * narrowing.cc (Interpreter::showFrontierStates): rewritten to use getUnexpandedStates() 2024-05-16 Steven Eker * latexCommand.cc (MaudeLatexBuffer::generateSearch): fixed missing space after filter/delay * latexResult.cc (MaudeLatexBuffer::generateNarrowingSearchPath): use generateCompoundSubstitution() * maudeLatexBuffer.hh (class MaudeLatexBuffer): adde decl for generateCompoundSubstitution() * maudeLatexBuffer.cc (MaudeLatexBuffer::generateCompoundSubstitution): added * maudeLatexBuffer.hh (class MaudeLatexBuffer): added decl for generateNarrowingSearchPath() * narrowing.cc: use generateNarrowingSearchPath() * latexResult.cc (MaudeLatexBuffer::generateNarrowingSearchPath): added * latexCommand.cc (MaudeLatexBuffer::generateSearch): echo vfold, path * search.cc (Interpreter::search): echo vfold and path flags 2024-05-09 Steven Eker * narrowing.cc (Interpreter::showFrontierStates): use getUnexpandedState() (Interpreter::showFrontierStates): print a message for empty frontier (Interpreter::showFrontierStates): handle the case where we have no visited but unexpanded state but still have unvisited states 2024-05-08 Steven Eker * interpreter.hh (class Interpreter): added decls for showFrontierStates(), showMostGeneralStates(); made showNarrowingSearchPath() private * commands.yy (command): added syntax for show frontier states and show most general states * narrowing.cc (Interpreter::showFrontierStates) (Interpreter::showMostGeneralStates): added stubs * commands.yy (option): deleted KW_INVARIANT * top.yy: deleted KW_INVARIANT; added KW_FRONTIER, KW_MOST, KW_GENERAL * lexer.ll: deleted KW_INVARIANT; added KW_FRONTIER, KW_MOST, KW_GENERAL 2024-05-07 Steven Eker * lexer.ll: return , in INITIAL for multiple vu-narrow options 2024-05-06 Steven Eker * narrowing.cc (Interpreter::showNarrowingSearchPath): use UserLevelRewritingContext::printCompoundSubstitution() to print the variant unfier used for a narrowing step * userLevelRewritingContext.hh (class UserLevelRewritingContext): added decl for printCompoundSubstitution() * userLevelRewritingContext.cc (UserLevelRewritingContext::printCompoundSubstitution): added 2024-05-03 Steven Eker * narrowing.cc (Interpreter::showNarrowingSearchPath): moved here * execute.cc (Interpreter::clearContinueInfo): use nullptr * narrowing.cc (Interpreter::doVuNarrowing): delete state and unprotect module on abort; always save state and module for later inspection * search.cc (Interpreter::showNarrowingSearchPath): added (Interpreter::doSearching): delete state and unprotect module on abort ===================================Maude161=========================================== 2024-05-02 Steven Eker * search.cc (Interpreter::search): delete terms and condition fragments if term disjunction used with anything other than vu-narrow/fvu-narrow (Interpreter::search): check problemOK() in NarrowingSequenceSearch3() case 2024-05-01 Steven Eker * narrowing.cc (Interpreter::doVuNarrowing): pass stateNr to generateSolutionNr() (Interpreter::doVuNarrowing): print out state number if we have the KEEP_PATHS flag * maudeLatexBuffer.hh (class MaudeLatexBuffer): pass NONE by default to stateNr argument of generateSolutionNr() * maudeLatexBuffer.cc (MaudeLatexBuffer::generateSolutionNr): handle stateNr argument * top.yy: added KW_VFOLD, KW_INVARIANT * lexer.ll: added invariant, vfold 2024-04-24 Steven Eker * narrowing.cc (Interpreter::doVuNarrowing): latex initial state if there was more than one initial state * maudeLatexBuffer.hh (class MaudeLatexBuffer): updated decl for generateState() * maudeLatexBuffer.cc (MaudeLatexBuffer::generateState): take a message argument * narrowing.cc (Interpreter::doVuNarrowing): print out initial state if there was more than one initial state 2024-04-22 Steven Eker * search.cc (Interpreter::search): pass subjectDags to NarrowingSequenceSearch3() 2024-04-19 Steven Eker * commands.yy (search): fix comment (command): code cleaning 2024-04-12 Steven Eker * mixfixParser.hh (class MixfixParser): TERM_DISJUNCTION -> MAKE_TERM_DISJUNCTION * maudeLatexBuffer.hh (class MaudeLatexBuffer): updated decl for generateSearch() * search.cc (Interpreter::search): handle the syntax of disjuctions of initial terms * latexCommand.cc (MaudeLatexBuffer::generateSearch): handle disjuctions of subjects * makeGrammar.cc (MixfixModule::makeComponentProductions): use term disjunction for the first half of search pair * mixfixParser.cc (MixfixParser::makeTermDisjunction): added (MixfixParser::makeSearchCommand): use makeTermDisjunction() 2024-04-11 Steven Eker * mixfixParser.hh (class MixfixParser): added TERM_DISJUNCTION to enum SemanticActions * specialTokens.cc: added vee * makeGrammar.cc (MixfixModule::makeComponentProductions): added syntax for term disjunctions * mixfixModule.hh (class MixfixModule): added TERM_DISJUNCTION_TYPE and set COMPLEX_NUMBER_OF_TYPES = 6 2024-04-10 Steven Eker * mixfixModule.hh (MixfixModule::nonTerminal): use getNumberOfTypes() * makeGrammar.cc (MixfixModule::makeGrammar): use SIMPLE_NUMBER_OF_TYPES, COMPLEX_NUMBER_OF_TYPES * mixfixModule.hh (class MixfixModule): split NUMBER_OF_TYPES into SIMPLE_NUMBER_OF_TYPES and COMPLEX_NUMBER_OF_TYPES * mixfixParser.hh (class MixfixParser): updated decl for ctor * mixfixParser.cc (MixfixParser::MixfixParser): take and store numberOfTypes * mixfixParser.hh (class MixfixParser): added data member numberOfTypes (MixfixParser::getNumberOfTypes): added * mixfixModule.hh (MixfixModule::domainComponentIndex): moved here (MixfixModule::nonTerminal): moved here (both versions) * search.cc (Interpreter::search): pass initial as a Vector& rather than a Term*& * mixfixParser.hh (class MixfixParser): updated decl for makeSearchCommand() * mixfixParser.cc (MixfixParser::makeSearchCommand): initial is now a Vector& rather than a Term*& * mixfixModule.hh (class MixfixModule): updated decl for parseSearchCommand() * doParse.cc (MixfixModule::parseSearchCommand): initial is now a Vector& rather than a Term*& * makeGrammar.cc (MixfixModule::makeComplexProductions): added missing comment for get variants syntax 2024-04-05 Steven Eker * commutativeDecomposeEqualitySymbol.cc (CommutativeDecomposeEqualitySymbol::acProvablyUnequal): return with arguments correctly canceled (CommutativeDecomposeEqualitySymbol::acDecompose): handle the case where some arguments canceled 2024-04-04 Steven Eker * commutativeDecomposeEqualitySymbol.cc (CommutativeDecomposeEqualitySymbol::decompose): use acDecompose() * commutativeDecomposeEqualitySymbol.hh (class CommutativeDecomposeEqualitySymbol): added decl for acDecompose() * commutativeDecomposeEqualitySymbol.cc (CommutativeDecomposeEqualitySymbol::acDecompose): added * commutativeDecomposeEqualitySymbol.hh (CommutativeDecomposeEqualitySymbol::makeMultisetFromArguments): added (class CommutativeDecomposeEqualitySymbol): made makeMultiset() static * commutativeDecomposeEqualitySymbol.cc (CommutativeDecomposeEqualitySymbol::acProvablyUnequal): added pairing argument 2024-04-03 Steven Eker * commutativeDecomposeEqualitySymbol.hh (class CommutativeDecomposeEqualitySymbol): added decl for equationallyStableOrGround() * commutativeDecomposeEqualitySymbol.cc (CommutativeDecomposeEqualitySymbol::associativeDecompose): added (CommutativeDecomposeEqualitySymbol::equationallyStableOrGround): added * commutativeDecomposeEqualitySymbol.hh (class CommutativeDecomposeEqualitySymbol): added decl for acProvablyUnequal() * commutativeDecomposeEqualitySymbol.cc (CommutativeDecomposeEqualitySymbol::associativeDecompose): use makeMultiset() rather than fillSet() * commutativeDecomposeEqualitySymbol.hh (class CommutativeDecomposeEqualitySymbol): deleted decl for fillSet() * commutativeDecomposeEqualitySymbol.cc (CommutativeDecomposeEqualitySymbol::fillSet): deleted * commutativeDecomposeEqualitySymbol.hh (CommutativeDecomposeEqualitySymbol::makeMultiset): added 2024-04-02 Steven Eker * commutativeDecomposeEqualitySymbol.hh (class CommutativeDecomposeEqualitySymbol): added decl for fillSet() * commutativeDecomposeEqualitySymbol.cc (CommutativeDecomposeEqualitySymbol::fillSet): added * commutativeDecomposeEqualitySymbol.hh (class CommutativeDecomposeEqualitySymbol): added typedef DagNodeSet 2024-03-29 Steven Eker * commutativeDecomposeEqualitySymbol.hh (class CommutativeDecomposeEqualitySymbol): updated decl for decompose() * commutativeDecomposeEqualitySymbol.cc (CommutativeDecomposeEqualitySymbol::decompose) (CommutativeDecomposeEqualitySymbol::associativeDecompose) (CommutativeDecomposeEqualitySymbol::eqRewrite): use new isEquationallyStable() conventions (CommutativeDecomposeEqualitySymbol::decompose): don't take MixfixModule* argument (CommutativeDecomposeEqualitySymbol::eqRewrite): use new decompose convention * commutativeDecomposeEqualitySymbol.hh (slass CommutativeDecomposeEqualitySymbol): updated decl for isEquationallyStable(); made it static * commutativeDecomposeEqualitySymbol.cc (CommutativeDecomposeEqualitySymbol::decompose): use associativeDecompose() (CommutativeDecomposeEqualitySymbol::equationallyStable): don't take MixfixModule; renamed to isEquationallyStable() * commutativeDecomposeEqualitySymbol.hh (class CommutativeDecomposeEqualitySymbol): added decl for associativeDecompose() * commutativeDecomposeEqualitySymbol.cc (CommutativeDecomposeEqualitySymbol::associativeDecompose): split off assoc code into new function 2024-03-28 Steven Eker * commutativeDecomposeEqualitySymbol.cc (CommutativeDecomposeEqualitySymbol::decompose): fixed infinite loop bug 2024-03-27 Steven Eker * commutativeDecomposeEqualitySymbol.cc (CommutativeDecomposeEqualitySymbol::eqRewrite): rewritten using equationalStable() (CommutativeDecomposeEqualitySymbol::decompose): handle associative case * commutativeDecomposeEqualitySymbol.hh (class CommutativeDecomposeEqualitySymbol): added decl for equationallyStable() * commutativeDecomposeEqualitySymbol.cc (CommutativeDecomposeEqualitySymbol::equationallyStable): added 2024-03-26 Steven Eker * commutativeDecomposeEqualitySymbol.cc (CommutativeDecomposeEqualitySymbol::hasImmediateSubterm): use DagArgumentIterator to work in the general case (CommutativeDecomposeEqualitySymbol::decompose): check for the existence of a conjunction symbol here (CommutativeDecomposeEqualitySymbol::eqRewrite): don't check for the existence of a conjunctionSymbol here ===================================Maude160=========================================== 2024-03-15 Steven Eker * maudeLatexBuffer.cc (MaudeLatexBuffer::generateBanner): tweak spacing * banner.cc (printBanner): tweak spacing * latexCommon.cc (MixfixModule::latexPrintBubble): use restoreColor and latexClearColor() to fix lost color after newline bug (MixfixModule::latexPrintBubble): use \maudeHardSpace for '\s for symmetry with format, even though it doesn't seem necessary 2024-03-14 Steven Eker * lexer.ll: move latex from to * commands.yy (printOption): added latex option * latexDagNodePrint.cc (MixfixModule::latexPrettyPrint): only use latex attribue if the PRINT_LATEX is set * latexTermPrint.cc (MixfixModule::latexPrettyPrint): only use latex attribue if the PRINT_LATEX is set * printSettings.hh (class PrintSettings): added PRINT_LATEX and added it to DEFAULT_PRINT_FLAGS 2024-03-13 Steven Eker * latexCommon.cc (MixfixModule::latexFancySpace): update comment to explain why we need restoreColor ===================================Maude159=========================================== 2024-03-12 Steven Eker * latexCommon.cc (MixfixModule::latexFancySpace): set restoreColor rather than attributeUsed (MixfixModule::latexFancySpace): use restoreColor after a newline (MixfixModule::latexPrintBubble): use latexRed etc * mixfixModule.hh (class MixfixModule): added static data member restoreColor (MixfixModule::latexClearColor): use restoreColor * latexCommon.cc: added restoreColor static data member * latexDagNodePrint.cc (MixfixModule::latexPrintDagNode): call latexClearColor() * latexTermPrint.cc (MixfixModule::latexPrettyPrint): call latexClearColor() * mixfixModule.hh (MixfixModule::latexClearColor): added * latexCommon.cc (MixfixModule::latexFancySpace): set attributeUsed and use latexClearColor(s) (MixfixModule::latexFancySpace): use latexRed etc * prettyPrint.cc (MixfixModule::prettyPrint): (dagNode version) remove unnecessary MixfixModule:: qualifications 2024-03-11 Steven Eker * token.cc (Token::splitKind): reimplemented to avoid const_cast<> * latexCommand.cc (MaudeLatexBuffer::generateShow): use \maudeShowSpace (all three versions) * latexModulePrint.cc (VisibleModule::latexShowOps): symmetric change * visibleModule.cc (VisibleModule::showOps): consider all ops for potential printing because we may have local declarations even if an op is imported 2024-03-06 Steven Eker * prettyPrint.cc (MixfixModule::prettyPrint): (Term* version) got rid of const_cast<> * quotedIdentifierOpSymbol.cc (QuotedIdentifierOpSymbol::makeQid): got rid of const_cast<> * mixfixModule.hh (class MixfixModule): updated decls for suffix(), handleIter(), handleMinus(), handleDivision(), handleFloat(), handleString(), handleQuotedIdentifier(), handleVariable(), handleSMT_Number(), prettyPrint() (Term* versions) * termPrint.cc (MixfixModule::suffix, MixfixModule::handleIter) (MixfixModule::handleMinus, MixfixModule::handleDivision) (MixfixModule::handleFloat, MixfixModule::handleString) (MixfixModule::handleQuotedIdentifier) (MixfixModule::handleVariable, MixfixModule::handleSMT_Number) (MixfixModule::prettyPrint): make Term* arg const 2024-03-05 Steven Eker * importTranslation.cc (ImportTranslation::translateExpr): removed const_cast<> (ImportTranslation::translateTerm): removed const_cast<> 2024-03-04 Steven Eker * latexDagNodePrint.cc (MixfixModule::latexPrettyPrint): deleted * mixfixModule.hh (class MixfixModule): deleted decl for 2 argument DagNode* version of latexPrettyPrint() 2024-03-01 Steven Eker * latexCommand.cc (MaudeLatexBuffer::generateCommand): print strategy in comment if non-null * mixfixModule.hh (class MixfixModule): updated decl for StrategyExpression* version of prettyPrint() * global.cc (operator<<): (StrategyExpression* version) moved here; pass interpreter * strategyPrint.cc (MixfixModule::prettyPrint): take and pass printSettings * global.cc (operator<<): reimplmented using MixfixModule::printConditionFragment() * mixfixModule.hh (class MixfixModule): deleted decls for both 2 argument versions of printCondition() * prettyPrint.cc (MixfixModule::printCondition): deleted both 2 argument versions * strategyPrint.cc (MixfixModule::prettyPrint): use 3 argument printCondition() * search.cc (Interpreter::search): use 3 argument printCondition() * global.cc (operator<<): (SortConstraint*, Equation*, Rule*, StrategyDefinition* versions) use 3 argument printCondition() * match.cc (Interpreter::match): use 3 argument printCondition() * mixfixModule.hh (class MixfixModule): added decl for 3 argument reEquation* version of printCondition() * prettyPrint.cc (MixfixModule::printCondition): added 3 argument PreEquation* version * latexCommand.cc (MaudeLatexBuffer::generateMatch): use 3 argument version of printCondition() with commentSettings (MaudeLatexBuffer::generateSearch): ditto * mixfixModule.hh (class MixfixModule): added decl for printConditionFragment() and 3 argument version of printCondition() * prettyPrint.cc (MixfixModule::printConditionFragment): added (MixfixModule::printCondition): added 3 arg version 2024-02-29 Steven Eker * token.cc (Token::makePrettyOpName): return empty string if not prettified to alert caller * latexCommon.cc (MixfixModule::latexPrettyOpName): handle empty string as indicating that no prettification was done by Token::makePrettyOpName() and call Token::latexIdentifier() to figure out the correct font to use * prettyPrint.cc (MixfixModule::prettyOpName): handle empty string as indicating that no prettification was done by Token::makePrettyOpName() 2024-02-28 Steven Eker * interpreter.cc (Interpreter::quit): don't use comment environment * latexResult.cc (MaudeLatexBuffer::generateSearchPath): use startComment(), endComment() (MaudeLatexBuffer::generateSearchPathLabels): ditto (MaudeLatexBuffer::generateSearchGraph): ditto * latexCommand.cc (MaudeLatexBuffer::generateGetVariants): use startComment(), endComment(), commentTerm(), commentDagNode(); don't use Tty::blockEscapeSequences(), Tty::unblockEscapeSequences() (MaudeLatexBuffer::generateVariantMatch): use startComment(), endComment(), commentTerm(); don't use Tty::blockEscapeSequences(), Tty::unblockEscapeSequences() (MaudeLatexBuffer::generateVariantUnify): ditto (MaudeLatexBuffer::generateUnify): ditto (MaudeLatexBuffer::generateSearch): ditto (MaudeLatexBuffer::generateMatch): ditto (MaudeLatexBuffer::generateLoopTokens): don't use comment environment (MaudeLatexBuffer::generateCommand): (both versions) use startComment(), endComment() (MaudeLatexBuffer::generateContinue): use startComment(), endComment() (MaudeLatexBuffer::generateShow): (3 versions) use startComment(), endComment() * maudeLatexBuffer.hh (MaudeLatexBuffer::startComment): added (MaudeLatexBuffer::endComment): added * latexCommand.cc (MaudeLatexBuffer::generateCommand): (Term* version) use commentDagNode(); don't use Tty::blockEscapeSequences() and Tty::unblockEscapeSequences() * printSettings.hh (class PrintSettings): added PLAIN_PRINT_FLAGS to enum PrintFlags * maudeLatexBuffer.cc: init commentSettings() * latexCommand.cc (MaudeLatexBuffer::generateCommand): (DagNode* version) use commentDagNode(); don't use Tty::blockEscapeSequences() and Tty::unblockEscapeSequences() * maudeLatexBuffer.hh (class MaudeLatexBuffer): deleted commented out pendingClose data member (class MaudeLatexBuffer): added data member commentSettings; (MaudeLatexBuffer::commentTerm): added (MaudeLatexBuffer::commentDagNode): added ===================================Maude158=========================================== 2024-02-26 Steven Eker * latexCommand.cc (MaudeLatexBuffer::generateGetVariants) (MaudeLatexBuffer::generateVariantMatch) (MaudeLatexBuffer::generateVariantUnify) (MaudeLatexBuffer::generateUnify) (MaudeLatexBuffer::generateMatch) (MaudeLatexBuffer::generateSearch) (MaudeLatexBuffer::generateLoopTokens) (MaudeLatexBuffer::generateCommand) (both versions): use pendingCloseStack (MaudeLatexBuffer::generateContinue) (MaudeLatexBuffer::generateShow) (3 versions): use pendingCloseStack * maudeLatexBuffer.hh (class MaudeLatexBuffer): pendingClose becomes pendingCloseStack (MaudeLatexBuffer::cleanUp): use pendingCloseStack 2024-02-23 Steven Eker * latexCommand.cc (MaudeLatexBuffer::generateGetVariants): code cleaning (MaudeLatexBuffer::generateVariantMatch): code cleaning (MaudeLatexBuffer::generateVariantUnify): code cleaning * visibleModule.cc (VisibleModule::showAttributes): use prettyOpName() for op-hooks (VisibleModule::showPolymorphAttributes): ditto 2024-02-22 Steven Eker * fixUp.cc (SyntacticPreModule::findHookSymbol): don't recognize colon in position 0 2024-02-21 Steven Eker * view.cc (View::printViewExpression): update comment 2024-02-20 Steven Eker * token.hh (class Token): deleted decl for removeBoundParameterBrackets() * token.cc (Token::removeBoundParameterBrackets): deleted now that we use View::printViewExpression() and ImportModule::printModuleExpression() to handle output in a pretty way rather than trying to hack the names * syntacticView.cc (SyntacticView::showProcessedView): use printModuleExpression() on modules rather than Token::removeBoundParameterBrackets() on module names for fromTheory and toModule 2024-02-19 Steven Eker * moduleCache.cc (ModuleCache::showCreatedModules): use printModuleExpression() * importModule.hh (class ImportModule): deleted decl for prettyModuleExpression() * importModule.cc (ImportModule::prettyModuleExpression): deleted * view.hh (class View): deleted decl for prettyViewExpression() * view.cc (View::prettyViewExpression): deleted * visibleModule.cc (VisibleModule::showImports): use printModuleExpression() * importModule.hh (class ImportModule): added decl for printModuleExpression() * view.hh (class View): added decl for printViewExpression() * view.cc (View::printViewExpression): added * importModule.cc (ImportModule::printModuleExpression): added 2024-02-16 Steven Eker * view.hh (class View): added decl for prettyViewExpression() * importModule.cc (ImportModule::prettyModuleExpression): use prettyViewExpression() * view.cc (View::latexViewExpression): use \\maudeLeftBracket, \\maudeRightBracket (View::prettyViewExpression): added * visibleModule.cc(VisibleModule::showImports): use prettyModuleExpression() rather than Token::removeBoundParameterBrackets() * importModule.hh (class ImportModule): added decl for prettyModuleExpression() * importModule.cc (ImportModule::prettyModuleExpression): added * renaming.cc (Renaming::printRenaming): use MixfixModule::prettyOpName() (2 places) 2024-02-15 Steven Eker * visibleModule.cc (VisibleModule::showDecls): use prettyOpName() (VisibleModule::showPolymorphDecl): use prettyOpName() 2024-02-14 Steven Eker * command.cc (SyntacticPreModule::showModule): don't handle parameterized constants specially now that MixfixModule::prettyOpName() should do the right thing * prettyPrint.cc (MixfixModule::prettyOpName): added * mixfixModule.hh (class MixfixModule): added decl for prettyOpName() * command.cc (SyntacticPreModule::showModule): use pretty names for ops and msgs 2024-02-13 Steven Eker * token.hh (class Token): deleted decl for prettyOpName() * token.cc (Token::prettyOpName): deleted * mixfixModule.hh (class MixfixModule): deleted decl for latexPrettyOp() * latexCommon.cc (MixfixModule::latexPrettyOp): deleted * latexModulePrint.cc (VisibleModule::latexShowAttributes): use latexPrettyOpName(); pass Token::BARE_COLON to latexConstant() (VisibleModule::latexShowPolymorphAttributes): symmetric changes * latexCommon.cc (MixfixModule::latexPrettyOpName): check for BARE_COLON as a signifier that we're printing an op-hook and use the single token name in that case * token.hh (class Token): added BARE_COLON to enum ProblemSituations * token.cc (Token::makePrettyOpName): handle BARE_COLON * latexRenaming.cc (Renaming::latexRenaming): cleaned up and commented op problem situation code; fix bug where we were comparing pointer typeid()s rather than underlying objects 2024-02-12 Steven Eker * mixfixModule.hh (class MixfixModule): updated decl for latexConstant() * latexCommon.cc (MixfixModule::latexConstant): take situations argument and pass it to latexPrettyOpName() * latexRenaming.cc (Renaming::latexRenaming) : pass situations argument to MixfixModule::latexConstant() and MixfixModule::latexPrettyOpName() (2 places) * latexModulePrint.cc (VisibleModule::latexShowPolymorphDecl) (VisibleModule::latexShowDecls): pass Token::EXPOSED_COLON to latexPrettyOpName() (VisibleModule::latexShowDecls): added comment (VisibleModule::latexShowDecls): use latexStructuredConstant() and latexPrettyOpName() in place of latexConstant() (VisibleModule::latexShowPolymorphDecl): ditto * latexPreModulePrint.cc (SyntacticPreModule::latexShowModule): pass Token::MULTIPLE_TOKENS to MixfixModule::latexPrettyOpName() in the ops/msgs case (SyntacticPreModule::latexShowModule): passs Token::EXPOSED_COLON to MixfixModule::latexPrettyOpName() * mixfixModule.hh (class MixfixModule): updated decl for latexPrettyOpName() * latexCommon.cc (MixfixModule::latexPrettyOpName): take situations arg and pass to Token::makePrettyOpName() * token.hh (class Token): updated decl for makePrettyOpName() * token.cc (Token::makePrettyOpName): rewritten to take situations argument * token.hh (class Token): added enum ProblematicSituations 2024-02-09 Steven Eker * latexModulePrint.cc (VisibleModule::latexShowDecls): use latexPrettyOpName() rather than latexPrettyOp() (VisibleModule::latexShowPolymorphDecl): ditto * token.cc (Token::makePrettyOpName): fix bug in test for "term" 2024-02-08 Steven Eker * latexRenaming.cc (Renaming::latexRenaming): replace call to MixfixModule::latexPrettyOp() with call to MixfixModule::latexPrettyOpName() (2 places) * latexCommon.cc (MixfixModule::latexConstant): use latexPrettyOpName() rather than latexPrettyOp() in the non-structured case * token.cc (Token::makePrettyOpName): check for , [ tokens in the correct branch * latexPreModulePrint.cc (SyntacticPreModule::latexShowModule): fixed bug where we were using & rather == to test auxProperty() * latexCommon.cc (MixfixModule::latexPrettyOpName): added * mixfixModule.hh (class MixfixModule): added decl for latexPrettyOpName() * latexPreModulePrint.cc (SyntacticPreModule::latexShowModule): use MixfixModule::latexPrettyOpName(); don't prettify variable names * token.hh (class Token): updated decl for makePrettyOpName() * token.cc (Token::makePrettyOpName): check for initial "term" token and surrounding parens; always return a usable name (Token::makePrettyOpName): take wantedSingleToken argument to catch the case where we generate a multitoken name in an ops declaration 2024-02-07 Steven Eker * token.cc (Token::makePrettyOpName): added * token.hh (class Token): added decl for makePrettyOpName() * token.cc (Token::computeSpecialProperty): added comments 2024-02-05 Steven Eker * entry.cc (MixfixModule::addPolymorph): check for Token::PAREN_MISMATCH (MixfixModule::addOpDeclaration): check for Token::PAREN_MISMATCH * token.cc (Token::extractMixfix): detect parenthesis mismatch * token.hh (class Token): added enum ReturnValues 2024-02-02 Steven Eker * latexCommon.cc: deleted cerr accidentally left in ===================================Maude157=========================================== 2024-01-29 Steven Eker * latexCommon.cc (MixfixModule::latexNumber) (MixfixModule::latexString, MixfixModule::latexQid) (MixfixModule::latexRaw): bumped cutoff sizes by 10 * latexDagNodePrint.cc (MixfixModule::latexPrettyPrint) (MixfixModule::latexPrintDagNode): use latexGraphPrint() * graphPrint.cc (MixfixModule::latexGraphPrint): added * mixfixModule.hh (class MixfixModule): added decl for latexGraphPrint() 2024-01-26 Steven Eker * prettyPrint.cc (MixfixModule::printStrategyTerm): removed inline - there is no performance issue for output * global.cc (operator<<): NamedEntity*, Symbol*, Sort*, ConnectedComponent*, RewriteStrategy* versions moved here for consistancy * prettyPrint.cc (MixfixModule::prettyPrint): DagNode* version, take printSettings argument * global.cc (operator<<): moved StrategyDefintion* version here; pass printSettings argument to printAttributes() replaced commented out Interpreter declaration with explanation of why we allocate it on the heap - to check for memory leaks * mixfixModule.hh (class MixfixModule): updated decl for printAttributes() * prettyPrint.cc (MixfixModule::printAttributes): take printSettings argument * mixfixModule.hh (class MixfixModule): updated decl for Term* version of prettyPrint() * prettyPrint.cc (MixfixModule::prettyPrint): Term* versions, take printSettings argument * global.cc (operator<<): moved SortConstraint*, Equation*, Rule*, ConditionFragment* versions here; pass printSettings argument to printAttributes() * visibleModule.cc (VisibleModule::showPolymorphAttributes): pass owner to Term* version of pretty print (VisibleModule::showAttributes): ditto * global.cc (operator<<): Term* versions moved here; pass printSettings argument to prettyPrint() (operator<<): DagNode* versions moved here; pass printSettings argument to prettyPrint() 2024-01-19 Steven Eker * match.cc (Interpreter::match): added comment to explain why we don't pass the GC_SUBSTITUTION flag 2024-01-09 Steven Eker * latexCommand.cc (MaudeLatexBuffer::generateSearch): added support for =># * search.cc (Interpreter::checkSearchRestrictions): don't allow =># searches for narrowing and smt-search * makeGrammar.cc (MixfixModule::makeParameterizedSortProductions): deleted commented out code (MixfixModule::makeComplexProductions): added syntax for =># 2024-01-08 Steven Eker * specialTokens.cc: added arrowHash =># 2024-01-05 Steven Eker * latexCommon.cc (MixfixModule::latexPrintBubble): make spacing and character translations congruent with Interpreter::printBubble() (MixfixModule::latexFancySpace): use \maudeNewline (MixfixModule::latexPrintBubble): use \maudeNewline * maudeLatexBuffer.cc (MaudeLatexBuffer::generateBanner): update copyright year * latexResult.cc (MaudeLatexBuffer::generateBubbleResult): don't generate output for empty bubble because adjacent $s cause problems 2024-01-04 Steven Eker * latexCommon.cc (MixfixModule::latexFancySpace): added comment to explain why we test PRINT_COLOR flag 2024-01-03 Steven Eker * maudeLatexBuffer.hh (class MaudeLatexBuffer): added decl for generateBubbleResult() * latexResult.cc (MaudeLatexBuffer::generateBubbleResult): added * latexCommon.cc (MixfixModule::latexTokenVector): code cleaning * loopMode.cc (Interpreter::doLoop): call generateBubbleResult() * mixfixModule.hh (class MixfixModule): added decl for latexPrintBubble() * latexCommon.cc (MixfixModule::latexPrintBubble): added * interpreter.hh (class Interpreter): deleted commented out printFlags data member * loopMode.cc (Interpreter::doLoop): call generateResult() * maudeLatexBuffer.hh (class MaudeLatexBuffer): added decl for message + DagNode* version of generateResult() * latexResult.cc (generateResult): added message + DagNode* version * execute.cc (Interpreter::printStats): added comments to both versions to explain their existence * loopMode.cc (Interpreter::contLoop): call generateAdvisory() * banner.cc (printBanner): update copyright year * loopMode.cc (Interpreter::contLoop2): call generateLoopTokens() * maudeLatexBuffer.hh (class MaudeLatexBuffer): added decl for generateLoopTokens() * latexCommand.cc (MaudeLatexBuffer::generateLoopTokens): added 2024-01-02 Steven Eker * variantUnify.cc (Interpreter::variantUnify): pass showTiming flag to printStats() * variantMatch.cc (Interpreter::variantMatch): pass showTiming flag to printStats() * getVariants.cc (Interpreter::getVariants): pass showTiming flag to printStats() (Interpreter::doGetVariants): pass showTiming flag to printStats() (2 places) * execute.cc (Interpreter::printStats): merge the 2 and 3 arg versions * loopMode.cc (Interpreter::loop): support latex (Interpreter::doLoop): call cleanUp() 2023-12-22 Steven Eker * smtSearch.cc (Interpreter::doSmtSearch): call MaudeLatexBuffer::cleanup() * execute.cc (Interpreter::check): added latex support 2023-12-21 Steven Eker * maudeLatexBuffer.hh (class MaudeLatexBuffer): added decl for generateSmtResult() * smtSearch.cc (Interpreter::doSmtSearch): call generateSmtResult() * latexResult.cc (MaudeLatexBuffer::generateSmtResult): added (MaudeLatexBuffer::generateSmtResult): added * smtSearch.cc (Interpreter::doSmtSearch): use 4/5 argument version of printStats() 2023-12-20 Steven Eker * smtSearch.cc (Interpreter::doSmtSearch): add latex support for the no result case * syntacticPreModule.hh (class SyntacticPreModule): deleted decl for latexTokenVector() * latexPreModulePrint.cc (SyntacticPreModule::latexShowModule): use MixfixModule::latexTokenVector() (SyntacticPreModule::latexAttributes): use MixfixModule::latexTokenVector() (SyntacticPreModule::latexAttributes): use MixfixModule::latexTokenVector() (SyntacticPreModule::latexTokenVector): deleted * latexCommon.cc (MixfixModule::latexTokenVector): treat ( like [ and {, i.e. allow a space in front of it for consistancy with text version 2023-12-19 Steven Eker * latexViewPrint.cc (SyntacticView::latexShowView): print mappings in math mode so that maudeBigRaw{} works * mixfixModule.hh (class MixfixModule): added decl for latexRaw() * latexCommon.cc (MixfixModule::latexRaw): added (MixfixModule::latexTokenVector): use latexRaw() * latexPreModulePrint.cc (SyntacticPreModule::latexAttributes): don't call Token::name() (SyntacticPreModule::latexStratDecl): ditto * latexModulePrint.cc (VisibleModule::latexPrintAttributes): don't call Token::name() (VisibleModule::latexPrintStrategyDecl): ditto (VisibleModule::latexShowAttributes): ditto (VisibleModule::latexShowPolymorphAttributes): ditto * printAttribute.cc (PrintAttribute::latexPrint): don't call Token::name() now that this is done in latexString() * latexTermPrint.cc (MixfixModule::latexHandleString): don't call Token::name() now that this is done in latexString() * latexDagNodePrint.cc (MixfixModule::latexHandleString): don't call Token::name() now that this is done in latexString() * mixfixModule.hh (MixfixModule::latexString): added code version * latexCommon.cc (MixfixModule::latexString): do Token::latexName() here rather than caller so we have the correct number of characters to make the big string decision * latexTermPrint.cc (MixfixModule::latexHandleQuotedIdentifier): use latexQid() * latexDagNodePrint.cc (MixfixModule::latexHandleQuotedIdentifier): use latexQid() * mixfixModule.hh (class MixfixModule): added decl for latexQid() * latexCommon.cc (MixfixModule::latexQid): added * latexPreModulePrint.cc (SyntacticPreModule::latexAttributes): use Token::latexName() rather than Token::name() for metadata to fix bad latex bug 2023-12-18 Steven Eker * printAttribute.cc (PrintAttribute::latexPrint): use MixfixModule::latexString() for text within print attribute * latexPreModulePrint.cc (SyntacticPreModule::latexAttributes): use MixfixModule::latexString() for metadata (SyntacticPreModule::latexStratDecl): use MixfixModule::latexString() for metadata * latexModulePrint.cc (VisibleModule::latexPrintAttributes): use latexString() for metadata (VisibleModule::latexPrintStrategyDecl): use latexString() for metadata (VisibleModule::latexShowAttributes): use latexString() for metadata (VisibleModule::latexShowPolymorphAttributes): use latexString() for metadata * latexTermPrint.cc: use latexString() * latexDagNodePrint.cc (MixfixModule::latexHandleString): use latexString() * latexCommon.cc (MixfixModule::latexString): added * mixfixModule.hh (class MixfixModule): added decl for latexString() 2023-12-15 Steven Eker * latexTermPrint.cc (MixfixModule::latexHandleIter): use latexNumber() (MixfixModule::latexHandleMinus): use latexNumber() (MixfixModule::latexHandleDivision): use latexNumber() (2 places) (MixfixModule::latexHandleSMT_Number): use latexNumber() (3 places) * latexDagNodePrint.cc (MixfixModule::latexHandleIter): use latexNumber() (MixfixModule::latexHandleMinus): use latexNumber() (MixfixModule::latexHandleDivision): use latexNumber() (2 places) (MixfixModule::latexHandleSMT_Number): use latexNumber() (3 places) * mixfixModule.hh (class MixfixModule): added decl for latexNumber() * latexCommon.cc (MixfixModule::latexNumber): added * interpreter.cc (Interpreter::quit): pass latexStream to MemoryCell::maybeShowResources() 2023-12-14 Steven Eker * interpreter.hh (class Interpreter): added decl for quit() * interact.cc (UserLevelRewritingContext::commandLoop): call Interpreter::quit() * interpreter.cc (Interpreter::quit): added ===================================Maude156=========================================== 2023-12-12 Steven Eker * lexer.ll: support big bracket commands in LATEX_MODE * latexCommon.cc (MixfixModule::latexFancySpace): replace \: with \maudeHardSpace and \; with \maudeIndent so they work at the start of a line 2023-12-11 Steven Eker * latexTermPrint.cc (MixfixModule::latexPrettyPrint): use latexPrintStructuredConstant() * latexCommon.cc: don't use outer braces for color changes to avoid messing up user's latex (such as \newline which doesn't work inside braces in math mode) * latexDagNodePrint.cc (MixfixModule::latexPrettyPrint): use latexPrintStructuredConstant() * mixfixModule.hh (class MixfixModule): added decl for latexPrintStructuredConstant() * latexCommon.cc (latexPrintStructuredConstant): added 2023-12-08 Steven Eker * latexTermPrint.cc (MixfixModule::latexPrettyPrint): use latexAttributePrint() (MixfixModule::latexPrettyPrint): don't handle automatic color in the latex attribute case (don't want it affecting subterms) * mixfixModule.hh (class MixfixModule): added decl for Term* version of latexAttributePrint() * latexTermPrint.cc (MixfixModule::latexAttributePrint): added * latexDagNodePrint.cc (MixfixModule::latexPrettyPrint): don't pass color to latexSuffix() (MixfixModule::latexPrettyPrint): handle color around prefix names (MixfixModule::latexPrettyPrint): use latexPrefix() * mixfixModule.hh (class MixfixModule): color = 0 default for DagNode* version of latexSuffix() * latexDagNodePrint.cc (MixfixModule::latexPrettyPrint): handle color around latexAttributePrint() 2023-12-07 Steven Eker * mixfixModule.hh (class MixfixModule): added decl for DagNode* version of latexAttributePrint() * latexDagNodePrint.cc (MixfixModule::latexAttributePrint): added 2023-12-06 Steven Eker * entry.cc (MixfixModule::addOpDeclaration): use unpackLatexMacro() * mixfixModule.hh (class MixfixModule): added decl for MixfixModule::unpackLatexMacro() * entry.cc (MixfixModule::unpackLatexMacro): added * latexToken.cc (Token::latexName): added warning comment about the non-existence of \textasciicircum and \textbackslash in math mode 2023-12-05 Steven Eker * latexModulePrint.cc (VisibleModule::latexShowPolymorphAttributes): handle latexMacro (VisibleModule::latexShowAttributes): handle latexMacro; fix bug where we were not putting space between format and metadata attributes * mixfixModule.hh (class MixfixModule): added decl for latexPrintLatexMacro() * latexCommon.cc (MixfixModule::latexPrintLatexMacro): added * latexRenaming.cc (Renaming::latexRenaming): handle latexMacro * renaming.cc (Renaming::makeCanonicalName): put parens rather than quotes around latexMacro (Renaming::printRenaming): handle latexMacro * renaming.hh (Renaming::getLatexMacro): added * renameModule.cc (ImportModule::donateOps2): handle latexMacro * renaming.cc (Renaming::makeCanonicalName): use new latexMacro convention (Renaming::isIdentityOpMapping): use new latexMacro convention (both versions) (Renaming::addSortConstantAndLabelMappings): use new latexMacro convention (Renaming::setLatexMacro): use new latexMacro convention * renaming.hh (class Renaming): made latexMacro into an int in struct OpMapping * mixfixModule.hh (MixfixModule::getLatexMacro): added (getPolymorphLatexMacro): added * visibleModule.cc (VisibleModule::showAttributes): handle latex macro * renameModule.cc (ImportModule::donateOps2): pass latexMacro = NONE to addPolymorph() and addOpDeclaration() * process.cc (SyntacticPreModule::processOps): pass latexMacro to addPolymorph() and addOpDeclaration() * ooProcess.cc (SyntacticPreModule::processClassOps): pass latexMacro = NONE to addOpDeclaration() (2 places) * mixfixModule.hh (class MixfixModule): updated decls for addOpDeclaration() and addPolymorph() * entry.cc (MixfixModule::addOpDeclaration): take latexMacro argument (MixfixModule::addPolymorph): take latexMacro argument * mixfixModule.hh (class MixfixModule): added data member latexMacroUnpacked to struct SymbolInfo 2023-12-04 Steven Eker * syntacticPreModule.hh (class SyntacticPreModule): deleted commented out classSymbol field from struct ClassDecl * syntacticPreModule.cc (SyntacticPreModule::OpDef::OpDef): deleted * syntacticPreModule.hh (class SyntacticPreModule): delete explicit ctor for OpDef and init prec and meta in the struct definition * mixfixModule.hh (class MixfixModule): turn latexMacro into an int and initialize it to NONE * command.cc (SyntacticPreModule::printAttributes): use new latexMacro representation * ops.cc (SyntacticPreModule::setLatexMacro): use new latexMacro representation * syntacticPreModule.hh (class SyntacticPreModule): made latexMacro and int in struct OpDef 2023-12-01 Steven Eker * latexCommon.cc (MixfixModule::latexPrintTails): fix bug where where we were using the wrong format word 2023-11-30 Steven Eker * mixfixModule.hh (class MixfixModule): added latexMacro field to struct SymbolInfo * command.cc (SyntacticPreModule::printAttributes): handle latex attribute ===================================Maude155=========================================== 2023-11-29 Steven Eker * mixfixModule.hh (class MixfixModule): updated decl for graphPrint() * prettyPrint.cc (MixfixModule::prettyPrint): pass printSettings to graphPrint() * graphPrint.cc (MixfixModule::graphPrint): take and pass printSettings * mixfixModule.hh (class MixfixModule): updated decls for printVariable(), Term* and DagNode* to ostream& versions of handleVariable() * dagNodePrint.cc (MixfixModule::handleVariable): take printSettings and pass to printVariable() (MixfixModule::prettyPrint): pass printSettings to handleVariable() * termPrint.cc (MixfixModule::handleVariable): take printSettings and pass to printVariable() (MixfixModule::prettyPrint): pass printSettings to handleVariable() * prettyPrint.cc (MixfixModule::printPrefixName): use printSettings rather than interpreter (MixfixModule::printVariable): take and use printSettings * mixfixModule.hh (class MixfixModule): updated decls for handleIter(), handleMinus(), handleDivision(), handleFloat(), handleString(),handleQuotedIdentifier(), handleVariable(), handleSMT_Number() * termPrint.cc (MixfixModule::prettyPrint): use prefix() * latexTermPrint.cc (MixfixModule::latexPrettyPrint): fix bug where we left (...) in code when in inserted latex version * termPrint.cc (MixfixModule::handleIter): don't take, use or pass color (MixfixModule::handleMinus): don't take or pass color (MixfixModule::handleDivision): ditto (MixfixModule::handleFloat): ditto (MixfixModule::handleString): ditto (MixfixModule::handleQuotedIdentifier): ditto (MixfixModule::handleVariable): ditto (MixfixModule::handleSMT_Number): ditto (MixfixModule::prettyPrint): don't pass color to handleIter(), handleMinus(), handleDivision(), handleFloat(), handleString(), handleQuotedIdentifier(), handleVariable(), handleSMT_Number() * mixfixModule.hh (class MixfixModule): updated decl for Term* to ostream& suffix() (class MixfixModule): color = nullptr default argument for ostream& prefix() * termPrint.cc (MixfixModule::suffix): get rid of color argument 2023-11-28 Steven Eker * sharedPrint.cc (MixfixModule::disambiguatorSort): moved here * termPrint.cc (MixfixModule::computeColor): code cleaning * latexTermPrint.cc (MixfixModule::latexPrettyPrint): use latexPrefix() * mixfixModule.hh (class MixfixModule): updated decls for the Term* versions of latexSuffix(), latexHandleIter(), latexHandleMinus(), latexHandleDivision(), latexHandleFloat(), latexHandleString(), latexHandleQuotedIdentifier(), latexHandleVariable(),latexHandleSMT_Number() * latexTermPrint.cc (MixfixModule::latexSuffix): don't take color argument (MixfixModule::latexHandleIter): don't take, use or pass color argument (MixfixModule::latexHandleIter): use latexPrefix; fix bug where we were using suffix rather than latexSuffix (MixfixModule::latexHandleMinus): don't take or pass color (MixfixModule::latexHandleDivision): ditto (MixfixModule::latexHandleFloat): ditto (MixfixModule::latexHandleString): ditto (MixfixModule::latexHandleQuotedIdentifier): ditto (MixfixModule::latexHandleVariable): ditto (MixfixModule::latexHandleSMT_Number): ditto (MixfixModule::latexPrettyPrint): don't pass color * mixfixModule.hh (class MixfixModule): latexPrefix() now has default color argument * latexDagNodePrint.cc (MixfixModule::latexPrettyPrint): get rid of unneccessary Mixfix:: qualification (MixfixModule::latexPrintDagNode): ditto * mixfixModule.hh (class MixfixModule): updated decls for latexPrintPrefixName(), latexPrintTokens(), latexPrintTails(), latexFancySpace() * latexTermPrint.cc (MixfixModule::latexHandleIter): pass printSettings to latexPrintPrefixName() (MixfixModule::latexPrettyPrint): pass printSettings to latexPrintPrefixName(), latexPrintTokens(), latexPrintTails() * latexDagNodePrint.cc (MixfixModule::latexHandleIter): pass printSettings to latexPrintPrefixName() (MixfixModule::latexPrettyPrint): pass printSettings to latexPrintPrefixName(), latexPrintTokens(), latexPrintTails() * latexCommon.cc (MixfixModule::latexFancySpace): take and use printSettings (MixfixModule::latexPrintPrefixName): take, use and pass printSettings (MixfixModule::latexPrintTokens): ditto (MixfixModule::latexPrintTails): ditto Intepreter:: -> PrintSettings:: * mixfixModule.hh (class MixfixModule): updated decl for Terms* version of latexHandleVariable() * latexTermPrint.cc (MixfixModule::latexHandleVariable): take and use printSettings (MixfixModule::latexPrettyPrint): pass printSettings to latexHandleVariable() * mixfixModule.hh (class MixfixModule): updated decl for DagNode* version of latexHandleVariable() * latexDagNodePrint.cc (MixfixModule::latexHandleVariable): take and use printSettings (MixfixModule::latexPrettyPrint): pass printSettings to latexHandleVariable() * mixfixModule.hh (class MixfixModule): updated decls for DagNode* versions of latexComputeColor(), latexHandleIter(), latexHandleMinus(), latexHandleDivision(), latexHandleFloat(), latexHandleString(), latexHandleQuotedIdentifier(), latexHandleSMT_Number(), latexPrettyPrint() * latexDagNodePrint.cc: Intepreter:: -> PrintSettings:: (MixfixModule::latexComputeColor): take and use printSettings (MixfixModule::latexHandleIter): take, use and pass printSettings (MixfixModule::latexHandleMinus): take and use printSettings (MixfixModule::latexHandleDivision): ditto (MixfixModule::latexHandleFloat): ditto (MixfixModule::latexHandleString): ditto (MixfixModule::latexHandleQuotedIdentifier): ditto (MixfixModule::latexHandleSMT_Number): ditto (MixfixModule::latexPrettyPrint): take, use and pass printSettings (MixfixModule::latexPrettyPrint) (MixfixModule::latexPrintDagNode): use clearIndent() (MixfixModule::latexPrettyPrint) (MixfixModule::latexPrintDagNode): pass printSettings * latexTermPrint.cc (MixfixModule::latexPrettyPrint): pass printSettings to main latexPrettyPrint() call * mixfixModule.hh (class MixfixModule): updated decl for Term* versions of latexHandleIter(), latexHandleMinus(), latexHandleDivision(), latexHandleFloat(), latexHandleString(), latexHandleQuotedIdentifier(), latexHandleSMT_Number(), latexPrettyPrint() * latexTermPrint.cc (MixfixModule::latexHandleIter): take and use printSettings; pass printSettings to latexPrettyPrint() (MixfixModule::latexHandleMinus): take and use printSettings (MixfixModule::latexHandleFloat): ditto (MixfixModule::latexHandleString): ditto (MixfixModule::latexHandleQuotedIdentifier): ditto (MixfixModule::latexHandleSMT_Number): ditto (MixfixModule::latexPrettyPrint): take and pass printSettings * mixfixModule.hh (class MixfixModule): updated decl for stream version of printPrefixName() (class MixfixModule): updated decl for fancySpace() * termPrint.cc (MixfixModule::prettyPrint): pass printSettings to printPrefixName() (MixfixModule::handleIter): ditto * dagNodePrint.cc (MixfixModule::handleIter): pass printSettings to printPrefixName() (MixfixModule::prettyPrint): ditto * prettyPrint.cc (MixfixModule::printPrefixName): take and pass printSettings * mixfixModule.hh (class MixfixModule): updated decls for stream versions of printTokens() and printTails() * dagNodePrint.cc (MixfixModule::prettyPrint): pass printSettings to printTails() and printTokens() * termPrint.cc (MixfixModule::prettyPrint): pass printSettings to printTails() and printTokens() * prettyPrint.cc (MixfixModule::fancySpace): take and use printSettings (MixfixModule::printTails): take, use and pass printSettings (MixfixModule::printTokens): ditto 2023-11-27 Steven Eker * mixfixModule.hh (class MixfixModule): updated decl for latexComputeColor() * latexTermPrint.cc (MixfixModule::latexComputeColor): take printSettings arg (MixfixModule::latexPrettyPrint): use latexComputeColor rather than computeColor() * latexDagNodePrint.cc (MixfixModule::latexPrettyPrint): use \maudeEllipsis * latexTermPrint.cc: Interpreter:: -> PrintSettings:: (MixfixModule::latexPrettyPrint): handle print conceal * termPrint.cc (MixfixModule::suffix): formatting * latexTermPrint.cc (MixfixModule::latexPrettyPrint): use clearIndent() * mixfixModule.hh (class MixfixModule): unfriend DagNode* operator<< (class MixfixModule): made StrategyExpression* prettyPrint() public (class MixfixModule): unfriend StrategyExpression* operator<< * prettyPrint.cc: (operator<<): (DagNode* version), use new MixfixModule::prettyPrint() * mixfixModule.hh (class MixfixModule): added decl for 3 argument DagNode* prettyPrint() * prettyPrint.cc (MixfixModule::prettyPrint): use clearIndent(), clearColor() (operator<<): (DagNode* version), use clearIndent(), clearColor() (MixfixModule::prettyPrint): added 3 argument DagNode* version * mixfixModule.hh (MixfixModule::clearIndent): added (MixfixModule::clearColor): added 2023-11-22 Steven Eker * bufferPrint.cc (MixfixModule::prettyPrint): support print conceal * specialTokens.cc: added ellipsis * termPrint.cc (MixfixModule::prettyPrint): support print conceal 2023-11-21 Steven Eker * mixfixModule.hh (class MixfixModule): make main Term* prettyPrint public 2023-11-20 Steven Eker * printSettings.hh (class PrintSettings): pass polarity = true by default for setPrintFlag() * mixfixModule.hh (class MixfixModule): updated decls for both versions of bufferPrint() * bufferPrint.cc (MixfixModule::bufferPrint): (StrategyExpression* version): pass printSettings (MixfixModule::bufferPrint): take printSettings (both versions) * mixfixModule.hh (class MixfixModule): updated decls for all 3 functions used to print strategies to buffer * bufferPrint.cc (MixfixModule::prettyPrint): (StrategyExpression* version): take and pass printSettings (MixfixModule::prettyPrint): (Vector version): take and pass printSettings (MixfixModule::prettyPrint): (ConditionFragment* version): take and pass printSettings * mixfixModule.hh (class MixfixModule): updated decls for buffer versions of printTokens(), printTails(), printPrefixName() * bufferPrint.cc (MixfixModule::bufferPrint): pass printSettings to prettyPrint() * mixfixModule.hh (class MixfixModule): updated decls for buffer versions of suffix(), prettyPrint(), handleVariable(), handleIter(), handleMinus(), handleDivision(), handleFloat(), handleString(), handleQuotedIdentifier(), handleSMT_NumberSymbol(), printKind(), printSort(), printDotSort(), printVarSort(), printTokens(), printTails(), printPrefixName() * bufferPrint.cc (MixfixModule::handleIter): take printSettings rather than printFlags (MixfixModule::suffix): ditto (MixfixModule::handleIter): ditto (MixfixModule::handleMinus): ditto (MixfixModule::handleDivision): ditto (MixfixModule::handleFloat): ditto (MixfixModule::handleString): ditto (MixfixModule::handleQuotedIdentifier): ditto (MixfixModule::handleVariable): ditto (MixfixModule::handleSMT_NumberSymbol): ditto (MixfixModule::prettyPrint): take, use and pass printSettings (MixfixModule::printKind): take and pass printSettings (MixfixModule::printSort): take printSettings (MixfixModule::printDotSort): ditto (MixfixModule::printVarSort): ditto (MixfixModule::printTokens): ditto (MixfixModule::printTails): ditto (MixfixModule::printPrefixName): ditto * termPrint.cc (MixfixModule::handleIter): pass printSettings to prettyPrint() * prettyPrint.cc (MixfixModule::prettyPrint): pass printSettings to Term* -> ostream prettyPrint() * termPrint.cc (MixfixModule::prettyPrint): take printSettings argument and pass it in recursive calls * mixfixModule.hh (class MixfixModule): updated decl for Term* -> ostream prettyPrint() * latexTermPrint.cc (MixfixModule::latexPrettyPrint): pass printSettings argument to computeColor() * termPrint.cc (MixfixModule::prettyPrint): pass printSettings argument to computeColor(), handleIter(), handleMinus(), handleDivision(), handleFloat(), handleString(), handleQuotedIdentifier(), handleSMT_Number() * mixfixModule.hh (class MixfixModule): updated decls for Term* versions of computeColor(), handleIter(), handleMinus(), handleDivision(), handleFloat(), handleString(), handleQuotedIdentifier(), handleSMT_Number() * termPrint.cc (MixfixModule::computeColor): take and use printSettings argument Interpreter:: -> PrintSettings:: everywhere (MixfixModule::handleIter): take and use printSettings argument (MixfixModule::handleMinus): ditto (MixfixModule::handleDivision): ditto (MixfixModule::handleFloat): ditto (MixfixModule::handleString): ditto (MixfixModule::handleQuotedIdentifier): ditto (MixfixModule::handleSMT_Number): ditto 2023-11-17 Steven Eker * bufferPrint.cc: Interpreter:: -> PrintSettings:: (MixfixModule::handleIter): handle PrintSettings::PRINT_DISAMBIG_CONST (MixfixModule::handleMinus): ditto (MixfixModule::handleDivision): ditto (MixfixModule::handleFloat): ditto (MixfixModule::handleString): ditto (MixfixModule::handleQuotedIdentifier): ditto (MixfixModule::handleSMT_NumberSymbol): ditto (MixfixModule::prettyPrint): made needDisambig, argRangeKnown calculations symmetric with ostream& case 2023-11-16 Steven Eker * latexTermPrint.cc (MixfixModule::latexHandleIter): handle PrintSettings::PRINT_DISAMBIG_CONST (MixfixModule::latexHandleMinus): ditto (MixfixModule::latexHandleDivision): ditto (MixfixModule::latexHandleFloat): ditto (MixfixModule::latexHandleString): ditto (MixfixModule::latexHandleQuotedIdentifier): ditto (MixfixModule::latexHandleSMT_Number): ditto * termPrint.cc (MixfixModule::handleIter): handle PrintSettings::PRINT_DISAMBIG_CONST (MixfixModule::handleMinus): handle PrintSettings::PRINT_DISAMBIG_CONST (MixfixModule::handleDivision): handle PrintSettings::PRINT_DISAMBIG_CONST (MixfixModule::handleFloat): ditto (MixfixModule::handleString): ditto (MixfixModule::handleQuotedIdentifier): ditto (MixfixModule::handleSMT_Number): ditto 2023-11-15 Steven Eker * dagNodePrint.cc (MixfixModule::prettyPrint): use printSettings.concealSymbol() * latexDagNodePrint.cc (MixfixModule::latexPrettyPrint): use new printConceal() convention * interpreter.hh (class Interpreter): deleted decl for concealedSymbol() * dagNodePrint.cc (MixfixModule::prettyPrint): use new printConceal() convention * printSettings.hh (class PrintSettings): added data member concealedSymbols * interpreter.hh (class Interpreter): deleted data member concealedSymbols * interpreter.cc (Interpreter::concealedSymbol): deleted (Interpreter::printConceal): moved here and use insertConcealed(), eraseConcealed() * printSettings.hh (PrintSettings::insertConcealed) (PrintSettings::eraseConcealed, PrintSettings::concealedSymbol): added * prettyPrint.cc: Interpreter:: -> PrintSettings:: (operator<<): pass printSettings to prettyPrint (DagNode* version); use safeCastNonNull() * mixfixModule.hh (class MixfixModule): updated decl for prettyPrint() (DagNode* version) * dagNodePrint.cc (MixfixModule::handleIter): pass printSettings to prettyPrint() (MixfixModule::prettyPrint): take printSettings argument * mixfixModule.hh (class MixfixModule): update decls for handleFloat(), handleString(), handleQuotedIdentifier(), handleIter(), handleMinus(), handleDivision(), handleSMT_Number() * dagNodePrint.cc (MixfixModule::handleIter): take printSettings argument (MixfixModule::handleMinus): take printSettings argument (MixfixModule::handleDivision): take printSettings argument (MixfixModule::handleFloat): take printSettings argument (MixfixModule::handleQuotedIdentifier): take printSettings argument (MixfixModule::handleString): take printSettings argument (MixfixModule::handleSMT_Number): take printSettings argument (MixfixModule::prettyPrint): pass printSettings to computeColor(), handleIter(), handleMinus(), handleDivision(), handleFloat(), handleString(), handleQuotedIdentifier(), handleSMT_Number(); use printSettings * mixfixModule.hh (class MixfixModule): updated decl for computeColor() (DagNode* version) * dagNodePrint.cc: Interpreter:: -> PrintSettings:: (MixfixModule::handleVariable): remove hack (MixfixModule::computeColor): take printSettings argument * commands.yy (kw_module): Interpreter:: -> PrintSettings:: * interpreter.cc (Interpreter::Interpreter): initialize PrintSettings base rather than printFlags member (Interpreter::setPrintFlag): deleted * mixfix.hh: added class PrintSettings * interpreter.hh (class Interpreter): derive from PrintSettings; delete enum PrintFlags (Interpreter::getPrintFlag): deleted * printSettings.hh (class PrintSettings): created * interpreter.hh (Interpreter::getPrintFlags): deleted 2023-11-14 Steven Eker * latexPreModulePrint.cc (SyntacticPreModule::latexTokenVector): symmetric change * token.cc (Token::printTokenVector): treat ( like [ { and put space in front of it if needSpace * quotedIdentifierOpSymbol.cc (QuotedIdentifierOpSymbol::printQid): put space before ( [ { if needSpace true ===================================Maude154=========================================== 2023-11-07 Steven Eker * latexCommon.cc (MixfixModule::latexPrintTokens): use \maudeAllowLineBreak before ) ] } if no whitespace is output (MixfixModule::latexPrintTails): similar scheme to above 2023-11-06 Steven Eker * latexCommon.cc (MixfixModule::latexPrintTokens): ouput \maudeAllowLineBreak after ( [ { , if they weren't followed by a space (MixfixModule::latexPrintTails): symmetric change for multi-token tails (MixfixModule::latexPrintTokens): fix bug where we were tests comma rather than token == comma (MixfixModule::latexPrintTails): fix symmetric bug; allowBreak now carries over between tails (MixfixModule::latexPrintTails): allowBreak after ) ] } This change from the text case is avoid a huge number of tails consisting only of these characters causing an overfull \hbox 2023-11-03 Steven Eker * latexModulePrint.cc (VisibleModule::latexShowVars): implement PRINT_COMBINE_VARS * commands.yy (printOption): added syntax for set print combine vars on/off . * top.yy: added KW_COMBINE * lexer.ll: added KW_COMBINE * visibleModule.cc (VisibleModule::showVars): implement PRINT_COMBINE_VARS * interpreter.hh (class Interpreter): added PRINT_COMBINE_VARS to enum PrintFlags 2023-11-02 Steven Eker * symbolType.hh (class SymbolType): add portal to SIMPLE_ATTRIBUTES * latexModulePrint.cc (VisibleModule::latexShowAttributes): handle portal attribute (VisibleModule::latexShowPolymorphAttributes): handle portal attribute * visibleModule.cc (VisibleModule::showPolymorphAttributes): handle portal attribute (VisibleModule::showAttributes): handle portal attribute * latexPreModulePrint.cc (SyntacticPreModule::latexAttributes): handle portal attribute * command.cc (SyntacticPreModule::printAttributes): handle portal attribute 2023-11-01 Steven Eker * mixfixModule.cc (MixfixModule::closeSignature): call addPortals() (MixfixModule::closeSignature): added DebugInfo() * entry.cc (MixfixModule::addOpDeclaration): add portalSymbols (MixfixModule::addOpDeclaration): check for illegal object & portal and msg & portal attribute combinations * mixfixModule.hh (class MixfixModule): added data member portalSymbols * symbolType.hh (class SymbolType): added PORTAL to enum Flags and renumbered later flags * modules.yy (attribute): added portal attribute * top.yy: added added KW_PORTAL * lexer.ll (id): added KW_PORTAL 2023-10-31 Steven Eker * latexPreModulePrint.cc (SyntacticPreModule::latexAttributes): move ctor to after poly; move id: and idem to after comm; move msg to after obj; move pconst to after iter * latexModulePrint.cc (VisibleModule::latexShowAttributes): move iter to after idem; move msg to after obj (VisibleModule::latexShowPolymorphAttributes): move iter to after idem; move msg to after obj * command.cc (SyntacticPreModule::printAttributes): move ctor to after poly; move id: and idem to after comm; move msg to after obj; move pconst to after iter * visibleModule.cc (VisibleModule::showAttributes): move iter to after idem; move msg to after obj 2023-10-30 Steven Eker * prettyPrint.cc (MixfixModule::printTokens) (MixfixModule::printTails): don't put space after comma if an explicit format statement is in play * latexCommon.cc (MixfixModule::latexPrintTails) (MixfixModule::latexPrintTokens): put space after comma (MixfixModule::latexPrintTokens, MixfixModule::latexPrintTails): but not if we have an explicit format statement * prettyPrint.cc (MixfixModule::printTokens): put space after comma (MixfixModule::printTails): put space after comma 2023-10-27 Steven Eker * latexViewPrint.cc (SyntacticView::latexShowProcessedView): pass showProcessed = true to latexRenaming() * moduleExpression.cc (ModuleExpression::latexPrint): fix missing \maudeRightParen after renaming * latexViewPrint.cc (SyntacticView::latexShowView): make expr a \maudeKeyword in strat->expr mappings * latexStrategyPrint.cc (VisibleModule::latexPrintStrategy): fix stray ( after top * viewExpression.cc (ViewExpression::latexPrint): make a recursive call in the instantiation case rather than accessing uninitialized name 2023-10-26 Steven Eker * latexViewPrint.cc (SyntacticView::latexShowProcessedView): fix space after var (SyntacticView::latexShowView): fix spacing in op->term and op->msg mappings * mixfixModule.hh (class MixfixModule): added decl for latexTokenVector() * latexCommon.cc (MixfixModule::latexTokenVector): added * syntacticView.hh (class SyntacticView): added decl for latexType() * latexViewPrint.cc (SyntacticView::latexShowView): handle view contents * latexViewPrint.cc (SyntacticView::latexShowProcessedView): only call latexRenaming() if there are sort mappings or op mappings * latexCommand.cc (MaudeLatexBuffer::generateSearch): fix bug where filter and delay keywords were printed with \maudeKeyWord 2023-10-25 Steven Eker * syntacticView.hh (class SyntacticView): added decl for latexShowView() * latexViewPrint.cc (SyntacticView::latexShowView): added stub * interpreter.cc (Interpreter::showView): added latex support * syntacticPreModule.hh (class SyntacticPreModule): made OpDef version of printAttributes() non-static const * command.cc (SyntacticPreModule::printAttributes): support PRINT_HOOKS flag * latexPreModulePrint.cc (SyntacticPreModule::latexAttributes): support PRINT_HOOKS flag (SyntacticPreModule::latexAttributes): use \maudeSpace after special 2023-10-24 Steven Eker * latexModulePrint.cc (VisibleModule::latexShowAttributes): support PRINT_HOOKS flag (VisibleModule::latexShowPolymorphAttributes): ditto * visibleModule.cc (VisibleModule::showAttributes): support PRINT_HOOKS flag (VisibleModule::showPolymorphAttributes): ditto * latexModulePrint.cc (VisibleModule::latexPrintAttributes): use use owner rather than global interpreter; made const * visibleModule.hh (class VisibleModule): made latexPrintAttributes() non-static and const * latexModulePrint.cc (VisibleModule::latexPrintMembershipAxiom): use owner rather than global interpreter (VisibleModule::latexPrintEquation): ditto (VisibleModule::latexPrintRule): ditto * interpreter.hh (class Interpreter): make PRINT_HOOKS the default * commands.yy (printOption): added print hooks * top.yy: added KW_HOOKS * lexer.ll: added KW_HOOKS * interpreter.hh (class Interpreter): added PRINT_HOOKS to enum PrintFlags 2023-10-23 Steven Eker * interpreter.cc (Interpreter::setCurrentModule): pass clearCaches flag to loseFocus() * syntacticPreModule.hh (class SyntacticPreModule): updated decl for loseFocus() * command.cc (SyntacticPreModule::loseFocus): take clearCaches flag * interpreter.hh (class Interpreter): make AUTO_CLEAR_CACHES true the default * lexer.ll: added KW_CACHES * top.yy: added token KW_CACHES * commands.yy: added set clear module caches on/off * interpreter.hh (class Interpreter): added AUTO_CLEAR_CACHES to enum Flags * commands.yy: added kw_module; use it for show module 2023-10-17 Steven Eker * moduleExpression.cc (ImportModule::latexModuleExpression): handle RENAMING case * latexImportModule.cc (ImportModule::latexModuleExpression): don't include a \maudeSpace in the seperator * moduleExpression.cc (ModuleExpression::latexPrint): need a recursive call for module instantiation * latexPreModulePrint.cc (SyntacticPreModule::latexShowModule): pass flatModule to ModuleExpression::latexPrint() * moduleExpression.hh (class ModuleExpression): updated decl for latexPrint() * moduleExpression.cc (ModuleExpression::latexPrint): take and pass enclosingModule argument * viewExpression.hh (class ViewExpression): updated decl for latexPrint() * viewExpression.cc (ViewExpression::latexPrint): implemented; take Module* parameter 2023-10-16 Steven Eker * viewExpression.hh (class ViewExpression): added decl for latexPrint() * viewExpression.cc (ViewExpression::latexPrint): added stub * moduleExpression.cc (ModuleExpression::latexPrint): handle the INSTANTIATION case * latexPreModulePrint.cc (SyntacticPreModule::latexOpDef): use \maudeConstantDecl * latexModulePrint.cc (VisibleModule::latexShowDecls): use latexConstant() (VisibleModule::latexShowPolymorphDecl): use latexConstant() (VisibleModule::latexShowPolymorphAttributes): use latexConstant(), latexPrettyOp(id) for op-hook ops (VisibleModule::latexShowAttributes): use latexConstant(), latexPrettyOp(id) for op-hook ops (VisibleModule::latexShowDecls) (VisibleModule::latexShowPolymorphDecl): don't output extra \maudeSpace in : -> case (VisibleModule::latexShowPolymorphDecl): use \maudeConstantDecl (VisibleModule::latexShowDecls): use \maudeConstantDecl * latexCommon.cc (MixfixModule::latexConstant): call latexStructuredConstant() (MixfixModule::latexConstant): call latexPrettyOp() * latexRenaming.cc (Renaming::latexRenaming): use MixfixModule::latexPrettyOp() for from and to operator names 2023-10-13 Steven Eker * syntacticPreModule.hh (class SyntacticPreModule): added decl for latexStratDecl() * latexPreModulePrint.cc (SyntacticPreModule::latexStratDecl): added (SyntacticPreModule::latexShowModule): use latexStratDecl * latexModulePrint.cc (VisibleModule::latexShowPolymorphAttributes): use latexPrintFormat() (VisibleModule::latexShowPolymorphAttributes): use latexPrintGather(() (VisibleModule::latexShowAttributes): use latexPrintFormat() (VisibleModule::latexShowAttributes): use latexPrintGather() * latexPreModulePrint.cc (SyntacticPreModule::latexShowModule): don't put \maudeSpace before \maudeHasSort (SyntacticPreModule::latexOpDef): don't put \maudeSpace after \maudeHasSort * latexToken.cc (Token::latexName): use \maudeTilde * latexPreModulePrint.cc (SyntacticPreModule::latexAttributes): use latexPrintFormat() (SyntacticPreModule::latexAttributes): handle special * mixfixModule.hh (class MixfixModule): added decl for latexPrintFormat() * latexCommon.cc (SyntacticPreModule::latexPrintFormat): added * latexPreModulePrint.cc (SyntacticPreModule::latexAttributes): use latexPrintGather() * mixfixModule.hh (class MixfixModule): added decl for latexPrintGather() * latexCommon.cc (MixfixModule::latexPrintGather): added 2023-10-12 Steven Eker * latexPreModulePrint.cc (SyntacticPreModule::latexShowModule): partial support for ops/msgs/vars * syntacticPreModule.hh (class SyntacticPreModule): added decl for latexAttributes() * latexPreModulePrint.cc (SyntacticPreModule::latexAttributes): added * latexModulePrint.cc (VisibleModule::latexShowPolymorphAttributes): fix bug where ctor wasn't being correctly printed * syntacticPreModule.hh (class SyntacticPreModule): added decl for latexOpDef() * latexPreModulePrint.cc (SyntacticPreModule::latexOpDef): added * command.cc (SyntacticPreModule::showModule): parens around & expression to make meaning clearer 2023-10-11 Steven Eker * latexModulePrint.cc (VisibleModule::latexShowPolymorphAttributes): treat identity range kind as known (VisibleModule::latexShowAttributes): treat identity range kind as known * visibleModule.cc (VisibleModule::showPolymorphAttributes): treat identity range kind as known (VisibleModule::showAttributes): treat identity range kind as known * latexPreModulePrint.cc (SyntacticPreModule::latexTokenVector): fix bug where we were checking for rightBracket and rightBrace rather than leftBracket and leftBrace * command.cc (SyntacticPreModule::showModule): use subclass or subclasses depending on the number of subclass relations * latexPreModulePrint.cc (SyntacticPreModule::latexShowModule): use range-based for loop for class attributes (SyntacticPreModule::latexType): handle kinds (SyntacticPreModule::latexShowModule): handle subclasses 2023-10-10 Steven Eker * latexPreModulePrint.cc (SyntacticPreModule::latexShowModule): handle subsorts and class declarations * syntacticPreModule.hh (class SyntacticPreModule): added decl for latexType() * latexPreModulePrint.cc (SyntacticPreModule::latexType): added * command.cc (SyntacticPreModule::showModule): use pluralize() for subsorts; use range-base for loop for sorts, subsorts * syntacticPreModule.hh (class SyntacticPreModule): deleted decl for latexStatementTokenVector() * latexPreModulePrint.cc (SyntacticPreModule::latexStatementTokenVector): deleted * syntacticPreModule.hh (class SyntacticPreModule): added decl for latexTokenVector() * latexPreModulePrint.cc (Token::latexTokenVector): added (SyntacticPreModule::latexShowModule): use latexTokenVector() 2023-10-09 Steven Eker * latexPreModulePrint.cc (SyntacticPreModule::latexShowModule): first attempt at imports, sort declarations, statements * syntacticPreModule.hh (class SyntacticPreModule): added decl for latexStatementTokenVector() * latexPreModulePrint.cc (SyntacticPreModule::latexStatementTokenVector): added * command.cc (SyntacticPreModule::showModule): use pluralize() for sorts * syntacticPreModule.hh (class SyntacticPreModule): added decl for latexSortTokenVector() * latexPreModulePrint.cc (SyntacticPreModule::latexSortTokenVector): added * moduleExpression.cc (ModuleExpression::latexPrint): added summation case 2023-10-06 Steven Eker * moduleExpression.hh (class ModuleExpression): added decl for latexPrint() * moduleExpression.cc (ModuleExpression::latexPrint): added * syntacticPreModule.hh (class SyntacticPreModule): added decl for latexShowModule() * latexPreModulePrint.cc: created * interpreter.cc (Interpreter::showPreModule): call SyntacticPreModule::latexShowModule() * visibleModule.hh (VisibleModule::latexPrintModuleName): deleted * latexModulePrint.cc (VisibleModule::latexShowModule): don't call latexPrintModuleName() * syntacticPreModule.hh (class SyntacticPreModule): remove default argument for showModule() * commands.yy (command): use interpreter.showPreModule() for show module * interpreter.hh (class Interpreter): added decl for showPreModule() * interpreter.cc (Interpreter::showPreModule): added * maudeLatexBuffer.hh (class MaudeLatexBuffer): updated decls for generateModuleName() and generateShow() * maudeLatexBuffer.cc (MaudeLatexBuffer::generateModuleName): take NamedEntity* rather than Module* so it works for PreModules * latexCommand.cc (MaudeLatexBuffer::generateShow): take NamedEntity* rather than Module* so it works for PreModules * commands.yy: added comments to explain why print attribute and print attribute new line are not handled by printOption 2023-10-05 Steven Eker * commands.yy (printOption): added label attribute * latexModulePrint.cc (VisibleModule::latexPrintMembershipAxiom): handle prefix labels (VisibleModule::latexPrintEquation): ditto (VisibleModule::latexPrintRule): ditto * prettyPrint.cc (MixfixModule::printAttributes): handle PRINT_LABEL_ATTRIBUTE (operator<<): SortConstraint* version: support prefix labels (operator<<): Equation* version: ditto (operator<<): Rule* version: ditto * interpreter.hh (class Interpreter): added PRINT_LABEL_ATTRIBUTE to PrintFlags 2023-10-04 Steven Eker * latexDagNodePrint.cc (MixfixModule::latexHandleIter): use \maudeIter command * latexTermPrint.cc (MixfixModule::latexHandleIter): use \maudeIter command * prettyPrint.cc (operator<<): ConditionFragment* version - be smart about sort disambiguation (operator<<): SortConstraint* version doesn't need sort disambiguation for term part (operator<<): Equation* version use MixfixModule::prettyPrint() for the rhs (operator<<): Rule* version ditto * mixfixModule.hh (class MixfixModule): Term* version of operator<<() is no longer a friend * prettyPrint.cc (operator<<): reimplement Term* version using 3 arg Term* prettyPrint() * mixfixModule.hh (class MixfixModule): added decl for 3 arg Term* prettyPrint() * prettyPrint.cc (MixfixModule::prettyPrint): added * latexModulePrint.cc (VisibleModule::latexPrintEquation): pass rangeKnown = true to latexPrettyPrint() for rhs (VisibleModule::latexPrintRule): symmetric change (VisibleModule::latexPrintMembershipAxiom): pass rangeKnown = true to latexPrettyPrint() for lhs (VisibleModule::latexPrintConditionFragment): pass rangeKnown = true to latexPrettyPrint() (4 places) * mixfixModule.hh (class MixfixModule): updated decl for Term* version of latexPrettyPrint() * latexTermPrint.cc (MixfixModule::latexPrettyPrint): take and pass rangeKnown flag ===================================Maude153=========================================== 2023-09-26 Steven Eker * interpreter.cc (Interpreter::parse): support latex * maudeLatexBuffer.hh (class MaudeLatexBuffer): added decl for Term* version of generateResult() * latexResult.cc (MaudeLatexBuffer::generateResult): added Term* version * maudeLatexBuffer.hh (class MaudeLatexBuffer): added decl for Term* version of generateCommand() * latexCommand.cc (MaudeLatexBuffer::generateCommand): added Term* version * maudeLatexBuffer.hh (class MaudeLatexBuffer): added decl for generateVariant() * getVariants.cc (Interpreter::doGetVariants): support latex (Interpreter::getVariantsCont): support latex * maudeLatexBuffer.cc (MaudeLatexBuffer::generateVariant): added * getVariants.cc (Interpreter::getVariants): use latex supporting pirntStats() 2023-09-25 Steven Eker * getVariants.cc (Interpreter::doGetVariants): call cleanUp() * maudeLatexBuffer.hh (class MaudeLatexBuffer): added decl for generateGetVariants() * getVariants.cc (Interpreter::getVariants): call generateGetVaraints() * latexCommand.cc (MaudeLatexBuffer::generateGetVariants): added 2023-09-22 Steven Eker * renaming.cc (Renaming::renameOp): DebugAlways() -> DebugInfo() 2023-09-21 Steven Eker * srewrite.cc (Interpreter::sRewrite): fix bug where we were passing depthSearch as number2 argument to generateCommand() * latexStrategyPrint.cc (VisibleModule::latexPrintStrategy): fix bug where one was printed with extra ( 2023-09-19 Steven Eker * interpreter.hh (class Interpreter): updated decl for doVariantMatching() * variantMatch.cc (Interpreter::variantMatch): call generateVariantMatch() (Interpreter::variantMatch): use new printStats() function (Interpreter::doVariantMatching): support latex (Interpreter::doVariantMatching): don't take timer argument (Interpreter::variantMatchCont): support latex; don't pass timer argument to doVariantMatching() (Interpreter::variantMatch): don't pass timer argument to doVariantMatching() * maudeLatexBuffer.hh (class MaudeLatexBuffer): added decl for generateVariantMatch() * latexCommand.cc (MaudeLatexBuffer::generateVariantMatch): added * interpreter.hh (class Interpreter): deleted decl for printSearchTiming() * search.cc (Interpreter::doSearching): use printStats() rather than printSearchTiming() (2 places) (Interpreter::printSearchTiming): deleted * srewrite.cc (Interpreter::doStrategicSearch): code cleaning; fix bug where we were using old showStats() which read the timer a second time * latexCommand.cc (MaudeLatexBuffer::generateContinue): handle debug flag * unify.cc (Interpreter::unifyCont): support latex * match.cc (Interpreter::matchCont): support latex * maudeLatexBuffer.hh (class MaudeLatexBuffer): added default debug = false to decl for generateContinue() * variantUnify.cc (Interpreter::variantUnifyCont): support latex * maudeLatexBuffer.cc (MaudeLatexBuffer::generateAdvisory): use \textcolor rather than \color (MaudeLatexBuffer::generateWarning): use\textcolor rather than \color * latexResult.cc (MaudeLatexBuffer::generateNonResult): check if we need a new line a clear needNewLine * variantUnify.cc (Interpreter::variantUnify): use new printStats() (Interpreter::doVariantUnification): rearrange and use new printStats() (2 places) * interpreter.hh (class Interpreter): added decl for new printStats(); removed default timingFlag value for old decl * execute.cc (Interpreter::printStats): added version with latex support 2023-09-18 Steven Eker * variantUnify.cc (Interpreter::doVariantUnification): call generateWarning() and generateAdvisory() * unify.cc (Interpreter::doUnification): call generateWarning() * maudeLatexBuffer.hh (class MaudeLatexBuffer): added decl for generateAdvisory() * maudeLatexBuffer.cc (MaudeLatexBuffer::generateAdvisory): added * variantUnify.cc (Interpreter::doVariantUnification): call generateResult() and generateSubstitution() * latexCommand.cc (MaudeLatexBuffer::generateUnify): use generateModifiers() (MaudeLatexBuffer::generateMatch): use generateModifiers() (MaudeLatexBuffer::generateCommand): use generateModifiers() (MaudeLatexBuffer::generateSearch): use generateModifiers() * variantUnify.cc (Interpreter::doVariantUnification): call cleanUp() * maudeLatexBuffer.hh (class MaudeLatexBuffer): added decl for generateVariantUnify() * latexCommand.cc (MaudeLatexBuffer::generateVariantUnify): added * maudeLatexBuffer.hh (class MaudeLatexBuffer): added decl for generateModifiers() * latexCommand.cc (MaudeLatexBuffer::generateUnify) (MaudeLatexBuffer::generateMatch): call Tty::unblockEscapeSequences() after printing comment (MaudeLatexBuffer::generateModifiers): added 2023-09-15 Steven Eker * maudeLatexBuffer.hh (class MaudeLatexBuffer): added decl for generic generateResult() * unify.cc (Interpreter::doUnification): call generateResult(), generateSubstitution(), generateNonResult() * latexResult.cc (MaudeLatexBuffer::generateNonResult): added generic version * unify.cc (Interpreter::doUnification): call cleanUp() * maudeLatexBuffer.hh (class MaudeLatexBuffer): added decl for generateUnify() * latexCommand.cc (MaudeLatexBuffer::generateUnify): added * match.cc (Interpreter::doMatching): call generateMatchResult() (Interpreter::doMatching): call generateSubstitution() * maudeLatexBuffer.hh (class MaudeLatexBuffer): added decl for generateMatchResult() * latexResult.cc (MaudeLatexBuffer::generateDecisionTime): fix missing closing paren (MaudeLatexBuffer::generateMatchResult): added 2023-09-14 Steven Eker * match.cc (Interpreter::printDecisionTime): call generateDecisionTime() (Interpreter::doMatching): call generateNonResult() * maudeLatexBuffer.hh (class MaudeLatexBuffer): added decls for generateDecisionTime(),generateNonResult() (message only version) * latexResult.cc (MaudeLatexBuffer::generateDecisionTime): added (MaudeLatexBuffer::generateNonResult): added message only version * match.cc (Interpreter::match): call generateMatch() (Interpreter::doMatching): call cleanUp() * maudeLatexBuffer.hh (class MaudeLatexBuffer): added decl for generateMatch() * latexCommand.cc (MaudeLatexBuffer::generateMatch): added * viewDatabase.cc (ViewDatabase::latexShowNamedViews): use latexViewExpression() * viewCache.cc (ViewCache::latexShowCreatedViews): use latexViewExpression() * latexImportModule.cc (ImportModule::latexModuleExpression): use latexViewExpression() * view.cc (View::latexViewExpression): added * view.hh (class View): added decl for latexViewExpression() 2023-09-13 Steven Eker * interpreter.cc (Interpreter::showViews): support latex * viewCache.cc (ViewCache::latexShowCreatedViews): added * viewCache.hh (class ViewCache): added decl for latexShowCreatedViews() * interpreter.cc (Interpreter::showModules): call cleanUp() * viewDatabase.cc (ViewDatabase::latexShowNamedViews): added * viewDatabase.hh (class ViewDatabase): added decl for latexShowNamedViews() * moduleCache.cc (ModuleCache::latexShowCreatedModules): pass parameterBrackets = true to latexModuleExpression() * importModule.hh (class ImportModule): updated decl for latexModuleExpression() * latexImportModule.cc (ImportModule::latexModuleExpression): handle PARAMETER case for show modules (ImportModule::latexModuleExpression): handle parameterBrackets argument * importModule.cc (ImportModule::ImportModule): init parameterCopyParameterName (both versions) * parameterization.cc (ImportModule::makeParameterCopy): set parameterCopyParameterName * importModule.hh (class ImportModule): added data member parameterCopyParameterName * moduleCache.cc (ModuleCache::latexShowCreatedModules): use latexModuleExpression() * interpreter.cc (Interpreter::showModules): support latex * maudeLatexBuffer.hh (class MaudeLatexBuffer): added decl for command only version of generateShow() * latexCommand.cc (MaudeLatexBuffer::generateShow): added command only version * moduleCache.cc (ModuleCache::latexShowCreatedModules): added * moduleCache.hh (class ModuleCache): added decl for latexShowCreatedModules() 2023-09-12 Steven Eker * moduleDatabase.cc (ModuleDatabase::latexShowNamedModules): added * moduleDatabase.hh (class ModuleDatabase): added decl for latexShowNamedModules() * latexModulePrint.cc (latexShowSortsAndSubsorts): disable hangindent to avoid confusing tabto package and revert to using \tab 2023-09-11 Steven Eker * latexModulePrint.cc (latexShowSortsAndSubsorts): try using tabbing rather than longtable for end of line wrapping (latexShowSortsAndSubsorts): tabbing does not wrap nicely; try maudeShowParagraph instead (latexShowSortsAndSubsorts): try \tab from the tabto package (latexShowSortsAndSubsorts): use \TabPositions ===================================Maude152=========================================== 2023-08-11 Steven Eker * interpreter.cc (Interpreter::showSummary): added latex support * latexModulePrint.cc (VisibleModule::latexShowSortsAndSubsorts): use longtable rather than tabular (VisibleModule::latexShowKinds): use \maudeBigIndent (VisibleModule::latexShowSummary): added * interpreter.cc (Interpreter::showKinds): added latex support * visibleModule.hh (class VisibleModule): added decl for latexShowKinds() * latexModulePrint.cc (VisibleModule::latexShowKinds): added * interpreter.cc (Interpreter::showStrats): added latex support (Interpreter::showSds): added latex support (Interpreter::showOps): added latex support * latexCommand.cc (MaudeLatexBuffer::generateCommand): set needNewline 2023-08-10 Steven Eker * interpreter.cc (Interpreter::showVars): support latex * visibleModule.hh (class VisibleModule): updated decl for latexShowVars() and made it public * latexModulePrint.cc (VisibleModule::latexShowVars): take indent arg (VisibleModule::latexShowModule): pass indent arg to latexShowVars() * interpreter.cc (showProcessedView): reimplemented using generateShow() * maudeLatexBuffer.hh (class MaudeLatexBuffer): added decl for View* version of generateShow() * latexCommand.cc (MaudeLatexBuffer::generateSearch): don't output \par at the start of command (MaudeLatexBuffer::generateCommand): don't output \par at the start of command (MaudeLatexBuffer::generateContinue): don't output \par at the start of command (MaudeLatexBuffer::generateShow): added View* version * interpreter.cc (Interpreter::showModule): reimplemented using generateShow() (Interpreter::showSortsAndSubsorts): reimplemented using generateShow() (Interpreter::showMbs): ditto (Interpreter::showEqs): ditto (Interpreter::showRls): ditto * maudeLatexBuffer.hh (class MaudeLatexBuffer): added decl for generateShow() * latexCommand.cc (MaudeLatexBuffer::generateShow): added * narrowing.cc (Interpreter::narrowingCont): pass showFlag arg to generateContinue() (Interpreter::vuNarrowingCont): ditto * search.cc (Interpreter::searchCont): pass showFlag arg to generateContinue() * srewrite.cc (Interpreter::sRewriteCont): pass showFlag arg to generateContinue() (Interpreter::dsRewriteCont): ditto * erewrite.cc (Interpreter::eRewriteCont): pass showFlag arg to generateContinue() * execute.cc (Interpreter::rewriteCont): pass showFlag arg to generateContinue() (Interpreter::fRewriteCont): ditto * maudeLatexBuffer.hh (class MaudeLatexBuffer): updated decl for generateContinue() * latexCommand.cc (MaudeLatexBuffer::generateContinue): take showCommand argument; set needNewline * latexResult.cc (MaudeLatexBuffer::generateNonResult): use needNewline to decide whether to output a \newline * latexCommand.cc (MaudeLatexBuffer::generateSearch): don't output \newline * maudeLatexBuffer.cc (MaudeLatexBuffer::generateSolutionNr): only output \newline if needNewline * maudeLatexBuffer.hh (class MaudeLatexBuffer): added data member need newline * maudeLatexBuffer.cc: init needNewline * latexCommand.cc (MaudeLatexBuffer::generateSearch): set needNewline * latexResult.cc (MaudeLatexBuffer::generateSearchNonResult): use needNewline flag to decide whether to start a newline (MaudeLatexBuffer::generateSearchResult): ditto * latexCommand.cc (MaudeLatexBuffer::generateSearch): print \newline after command * latexResult.cc (MaudeLatexBuffer::generateSearchResult): put \newline after rather than before solution (MaudeLatexBuffer::generateSearchNonResult): don't print \newline * latexCommand.cc (MaudeLatexBuffer::generateSearch): handle showCommand flag * maudeLatexBuffer.hh (class MaudeLatexBuffer): updated decl for generateSearch() * search.cc (Interpreter::search): pass showCommand flag to generateSearch() * maudeLatexBuffer.hh (class MaudeLatexBuffer): deleted decls for generateReduce(), generateRewrite(), generateFrewrite(), generateErewrite(), generateSrewrite() * latexCommand.cc (MaudeLatexBuffer::generateReduce) (MaudeLatexBuffer::generateRewrite) (MaudeLatexBuffer::generateFrewrite) (MaudeLatexBuffer::generateErewrite) (MaudeLatexBuffer::generateSrewrite): deleted * srewrite.cc (Interpreter::sRewrite): use generateCommand() rather than generateSrewrite() * erewrite.cc (Interpreter::eRewrite): use generateCommand() rather than generateErewrite() * execute.cc (Interpreter::reduce): use generateCommand() rather than generateReduce() (Interpreter::rewrite): use generateCommand() rather than generateRewrite() (Interpreter::fRewrite): use generateCommand() rather than generateFrewrite() * maudeLatexBuffer.hh (class MaudeLatexBuffer): update decl for generateCommand() and made it public * latexCommand.cc (MaudeLatexBuffer::generateCommand): take showCommand argument 2023-08-09 Steven Eker * search.cc (Interpreter::showSearchGraph): use generateSearchGraph() * maudeLatexBuffer.hh (class MaudeLatexBuffer): added decl for generateSearchGraph() * latexResult.cc (MaudeLatexBuffer::generateSearchGraph): added * search.cc (Interpreter::showSearchPathLabels): use generateSearchPathLabels() * maudeLatexBuffer.hh (class MaudeLatexBuffer): added decl for generateSearchPathLabels() * latexResult.cc (MaudeLatexBuffer::generateSearchPath): use \maudeEndCommand (MaudeLatexBuffer::generateSearchPathLabels): added 2023-08-08 Steven Eker * latexModulePrint.cc (VisibleModule::latexPrintRule): don't enclose rule in $s if indent is null * search.cc (Interpreter::showSearchPath): use generateSearchPath() * latexResult.cc (MaudeLatexBuffer::generateSearchPath): added * visibleModule.hh (class VisibleModule): updated decls for latexPrintMembershipAxiom(), latexShowMbs(), latexPrintEquation(), latexPrintRule(), latexShowRls() * latexModulePrint.cc (VisibleModule::latexPrintMembershipAxiom): made const (VisibleModule::latexShowMbs): made const (VisibleModule::latexPrintEquation): made const (VisibleModule::latexShowEqs): made const (VisibleModule::latexPrintRule): made const (VisibleModule::latexShowRls): made const * visibleModule.hh (class VisibleModule): made latexPrintRule() public (class VisibleModule): made latexPrintAttributes() static * latexModulePrint.cc (VisibleModule::latexPrintRule): only start a new line if indent is non-null * commutativeDecomposeEqualitySymbol.cc (CommutativeDecomposeEqualitySymbol::eqRewrite): check that both symbols are non-special before returning notEqual * specialSymbolTypes.cc: deleted DecomposeEqualitySymbol * fancySymbols.cc (MixfixModule::newFancySymbol): deleted DecomposeEqualitySymbol * mixfix.hh: deleted class DecomposeEqualitySymbol * decomposeEqualitySymbol.cc: deleted * decomposeEqualitySymbol.hh: deleted * commutativeDecomposeEqualitySymbol.cc (CommutativeDecomposeEqualitySymbol::hasImmediateSubterm): fix bugs where we were comparing pointers rather than using equal(); handle iter theory * commutativeDecomposeEqualitySymbol.hh (class CommutativeDecomposeEqualitySymbol): update decl for decomose() * commutativeDecomposeEqualitySymbol.cc (CommutativeDecomposeEqualitySymbol::decompose): handle iter theory; remove const because we need to place our own symbol in the new dag node 2023-08-07 Steven Eker * decomposeEqualitySymbol.cc (DecomposeEqualitySymbol::decompose): only handle commutative case if disjunctionSymbol is defined * commutativeDecomposeEqualitySymbol.cc (CommutativeDecomposeEqualitySymbol::decompose): only handle commutative case if disjunctionSymbol is defined * decomposeEqualitySymbol.hh (class DecomposeEqualitySymbol): updated decl for decompose(); made hasImmediateSubterm() const * decomposeEqualitySymbol.cc (DecomposeEqualitySymbol::decompose): handle commutative case, made const * commutativeDecomposeEqualitySymbol.hh (class CommutativeDecomposeEqualitySymbol): updated decl for decompose(); made hasImmediateSubterm() static * commutativeDecomposeEqualitySymbol.cc: init disjunctionSymbol (CommutativeDecomposeEqualitySymbol::attachSymbol): attach disjunctionSymbol (CommutativeDecomposeEqualitySymbol::copyAttachments): copy disjunctionSymbol (CommutativeDecomposeEqualitySymbol::getSymbolAttachments): handle disjunctionSymbol (CommutativeDecomposeEqualitySymbol::decompose): added support for CUI_Symbol (CommutativeDecomposeEqualitySymbol::decompose): made const * commutativeDecomposeEqualitySymbol.hh (class CommutativeDecomposeEqualitySymbol): added decl for hasImmediateSubterm(), make decompose() private (class CommutativeDecomposeEqualitySymbol): added data member disjunctionSymbol * commutativeDecomposeEqualitySymbol.cc (CommutativeDecomposeEqualitySymbol::hasImmediateSubterm): added (CommutativeDecomposeEqualitySymbol::eqRewrite): use hasImmediateSubterm() * decomposeEqualitySymbol.hh (class DecomposeEqualitySymbol): make decompose() private * decomposeEqualitySymbol.cc (DecomposeEqualitySymbol): init disjunctionSymbol (DecomposeEqualitySymbol::attachSymbol): attach disjunctionSymbol (DecomposeEqualitySymbol::copyAttachments): copy disjunctionSymbol (DecomposeEqualitySymbol::getSymbolAttachments): handle disjunctionSymbol (DecomposeEqualitySymbol::hasImmediateSubterm): added (DecomposeEqualitySymbol::eqRewrite): use hasImmediateSubterm() * decomposeEqualitySymbol.hh (class DecomposeEqualitySymbol): added data member disjunctionSymbol 2023-08-04 Steven Eker * narrowing.cc (Interpreter::doVuNarrowing): call cleanUp() * maudeLatexBuffer.hh (class MaudeLatexBuffer): added decl for Vector& version of generateSubstitution() * maudeLatexBuffer.cc (MaudeLatexBuffer::generateSubstitution): added Vector& version * maudeLatexBuffer.hh (class MaudeLatexBuffer): added decl for NarrowingVariableInfo& version of generateSubstitution() * narrowing.cc (Interpreter::doVuNarrowing): added latex support * maudeLatexBuffer.cc (MaudeLatexBuffer::generateSubstitution): added NarrowingVariableInfo& version * narrowing.cc (Interpreter::doVuNarrowing): use new printStats() (Interpreter::vuNarrowingCont): call MaudeLatexBuffer::generateContinue() * maudeLatexBuffer.hh (MaudeLatexBuffer::generateHeading): added * narrowing.cc (Interpreter::narrowingCont): call MaudeLatexBuffer::generateContinue() * search.cc (Interpreter::searchCont): call MaudeLatexBuffer::generateContinue() * maudeLatexBuffer.hh (class MaudeLatexBuffer): delete decl for generateDag() * maudeLatexBuffer.cc (MaudeLatexBuffer::generateDag): deleted * latexCommand.cc (MaudeLatexBuffer::generateCommand): don't start pendingClose with \n (MaudeLatexBuffer::generateContinue): don't start pending close with \n * latexResult.cc (MaudeLatexBuffer::generateResult): use MixfixModule::latexPrintDagNode() instead of generateDag() * latexCommand.cc (MaudeLatexBuffer::generateSearch): moved here (MaudeLatexBuffer::generateCommand): moved here (MaudeLatexBuffer::generateCommand): print $ after \par; use MixfixModule::latexPrintDagNode() rather than generateDag() (MaudeLatexBuffer::generateContinue): moved here (MaudeLatexBuffer::generateReduce): moved here (MaudeLatexBuffer::generateRewrite): moved here (MaudeLatexBuffer::generateFrewrite): moved here (MaudeLatexBuffer::generateErewrite): moved here (MaudeLatexBuffer::generateSrewrite): moved here * maudeLatexBuffer.hh (class MaudeLatexBuffer): deleted decls for generateTiming() and old version of generateStats() * maudeLatexBuffer.cc (MaudeLatexBuffer::generateTiming): deleted (MaudeLatexBuffer::generateStats): deleted old version * maudeLatexBuffer.hh (class MaudeLatexBuffer): updated decls for generateSearchResult(), generateSearchNonResult() * search.cc (Interpreter::doSearching): use new generateSearchNonResult() convention (Interpreter::doSearching): use new generateSearchResult() convention * latexResult.cc (MaudeLatexBuffer::generateStats): moved new version here (MaudeLatexBuffer::generateNonResult): moved here (MaudeLatexBuffer::generateResult): moved here (MaudeLatexBuffer::generateSearchNonResult): moved here; use new generateStats() (MaudeLatexBuffer::generateSearchResult): moved here; use new generateStats() (MaudeLatexBuffer::generateStats): output extra space after nrStates * narrowing.cc (Interpreter::doNarrowing): use new generateNonResult() convention (Interpreter::doNarrowing): use new generateStats() (Interpreter::doNarrowing): use new printStats() (2 places) * maudeLatexBuffer.hh (class MaudeLatexBuffer): updated decl for generateNonResult() * srewrite.cc (Interpreter::doStrategicSearch): use new generateNonResult() convention * maudeLatexBuffer.cc (MaudeLatexBuffer::generateNonResult): take cpuTime and realTime; use new generateStats() * srewrite.cc (Interpreter::doStrategicSearch): use new printStats() and new generateResult() convention * maudeLatexBuffer.hh (class MaudeLatexBuffer): updated decl for generateResult() * execute.cc (Interpreter::endRewriting): call cleanUp(); use new generateResult() conventions * maudeLatexBuffer.cc (MaudeLatexBuffer::generateResult): redesigned to take cpuTime and realTime rather than timer * execute.cc (Interpreter::endRewriting): rewritten to use new printStats() * interpreter.hh (class Interpreter): added decl for new printStats() * maudeLatexBuffer.hh (class MaudeLatexBuffer): added decl for new generateStats() * execute.cc (Interpreter::printStats): added new version that takes cpuTime and realTime * maudeLatexBuffer.cc (MaudeLatexBuffer::generateTiming): fixed bug where we were dividing real by 100 rather than 1000 (MaudeLatexBuffer::generateStats): added new version that takes cpuTime and realTime 2023-08-03 Steven Eker * narrowing.cc (Interpreter::doNarrowing): call generateStats() * maudeLatexBuffer.hh (class MaudeLatexBuffer): made generateStats() public * maudeLatexBuffer.cc (MaudeLatexBuffer::generateSearch): call Tty::unblockEscapeSequences() * narrowing.cc (Interpreter::doNarrowing): call cleanUp() * maudeLatexBuffer.hh (class MaudeLatexBuffer): added decl for generateState() * narrowing.cc (Interpreter::doNarrowing): use generateNonResult(), generateWarning(), generateSolutionNr(), generateState(), generateSubstitution() * maudeLatexBuffer.cc (MaudeLatexBuffer::generateSolutionNr): use \maudeNumber{} (MaudeLatexBuffer::generateState): added * maudeLatexBuffer.hh (class MaudeLatexBuffer): added decl for generateWarning() * maudeLatexBuffer.cc (MaudeLatexBuffer::generateWarning): added * search.cc (Interpreter::doSearching): call generateSubstitution() * maudeLatexBuffer.hh (class MaudeLatexBuffer): added decl for generateSubstitution() * maudeLatexBuffer.cc (MaudeLatexBuffer::generateSearch): don't start pendingClose with \n (MaudeLatexBuffer::generateSearchNonResult) (MaudeLatexBuffer::generateSearchResult): pass nrStates to generateStats() (MaudeLatexBuffer::generateSearch): print \begin{maudeResultParagraph} (MaudeLatexBuffer::generateSubstitution): added * maudeLatexBuffer.hh (class MaudeLatexBuffer): updated decl for generateStats() * maudeLatexBuffer.cc (MaudeLatexBuffer::generateSearchNonResult): added (MaudeLatexBuffer::generateSearchResult): added (MaudeLatexBuffer::generateSearch): \maudeKeyWord -> \maudeKeyword (MaudeLatexBuffer::generateSearch): added \maudeSpace after : (MaudeLatexBuffer::generateStats): handle nrStates * search.cc (Interpreter::doSearching): use generateSearchNonResult(), generateSearchResult() (Interpreter::doSearching): call cleanUp() 2023-08-02 Steven Eker * search.cc (Interpreter::search): use latexBuffer->generateSearch() * maudeLatexBuffer.hh (class MaudeLatexBuffer): added decl for generateSearch() * maudeLatexBuffer.cc (MaudeLatexBuffer::generateSearch): added * visibleModule.hh (class VisibleModule): made latexPrintCondition() public * latexDagNodePrint.cc (MixfixModule::latexPrintDagNode): added * mixfixModule.hh (class MixfixModule): added decl for latexPrintDagNode() 2023-08-01 Steven Eker * interpreter.cc (Interpreter::updateSet): fixed bug where range erase() was used to delete a range from a set other than *this * maudeLatexBuffer.hh (class MaudeLatexBuffer): deleted decl for generateModifiers() * maudeLatexBuffer.cc (MaudeLatexBuffer::generateCommand): use \maudeEndCommand (MaudeLatexBuffer::generateContinue): use \maudeEndCommand (MaudeLatexBuffer::generateModifiers): deleted * latexModulePrint.cc (VisibleModule::latexPrintMembershipAxiom) (VisibleModule::latexPrintEquation) (VisibleModule::latexPrintRule): start math mode just after \par (VisibleModule::latexPrintStrategyDecl) (VisibleModule::latexPrintStrategyDefinition): start math mode just after \par (VisibleModule::latexShowImports): start math mode just after \par (VisibleModule::latexShowSorts): typeset whole line in math mode (VisibleModule::latexShowVars): start math mode just after \par (VisibleModule::latexShowDecls): start math mode just after \par (VisibleModule::latexShowSubsorts): typeset whole line in math mode (VisibleModule::latexShowPolymorphDecl): start math mode just after \par * srewrite.cc (Interpreter::sRewriteCont): call generateContinue() (Interpreter::dsRewriteCont): call generateContinue() * maudeLatexBuffer.hh (class MaudeLatexBuffer): made generateType(), generateDag(), generateModifiers(), generateCommand() private * maudeLatexBuffer.cc (MaudeLatexBuffer::generateResult): use cleanUp() (MaudeLatexBuffer::generateNonResult): don't handle pendingClose * srewrite.cc (Interpreter::doStrategicSearch): call cleanUp() * maudeLatexBuffer.hh (class MaudeLatexBuffer): made generateStats(), generateTiming() private * srewrite.cc (Interpreter::doStrategicSearch): use MaudeLatexBuffer::generateNonResult() * maudeLatexBuffer.cc (MaudeLatexBuffer::generateCommand): pass command by reference * maudeLatexBuffer.hh (class MaudeLatexBuffer): added decl for generateNonResult() (class MaudeLatexBuffer): updated decl for generateCommand() * maudeLatexBuffer.cc (MaudeLatexBuffer::generateNonResult): added * execute.cc (Interpreter::endRewriting): pass result to MaudeLatexBuffer::generateResult() * maudeLatexBuffer.hh (class MaudeLatexBuffer): updated decl for generateResult() * maudeLatexBuffer.cc (MaudeLatexBuffer::generateResult): take result argument * maudeLatexBuffer.hh (class MaudeLatexBuffer): added decl for generateSrewrite() * srewrite.cc (Interpreter::sRewrite): add latex support (Interpreter::doStrategicSearch): add latex support * maudeLatexBuffer.hh (class MaudeLatexBuffer): updated decl for generateCommand() * maudeLatexBuffer.cc (MaudeLatexBuffer::generateCommand): take strategy argument (MaudeLatexBuffer::generateSrewrite): added * maudeLatexBuffer.hh (class MaudeLatexBuffer): updated decl for generateResult() (class MaudeLatexBuffer): added decl for generateSolutionNr() * maudeLatexBuffer.cc (MaudeLatexBuffer::generateResult): take finished argument (MaudeLatexBuffer::generateSolutionNr): added * execute.cc (Interpreter::endRewriting): deleted commented out test of serialization code * maudeLatexBuffer.cc (MaudeLatexBuffer::generateContinue): put comment outside of \begin{maudeResultParagraph} (MaudeLatexBuffer::generateCommand): put comment outside of \begin{maudeResultParagraph} * execute.cc (Interpreter::endRewriting): use cleanUp() * maudeLatexBuffer.cc (MaudeLatexBuffer::generateResult): output pendingClose (MaudeLatexBuffer::generateCommand): set pendingClose (MaudeLatexBuffer::generateContinue): set pendingClose (~MaudeLatexBuffer): output pendingClose * maudeLatexBuffer.hh (class MaudeLatexBuffer): added data member pendingClose (MaudeLatexBuffer::cleanUp): added 2023-07-31 Steven Eker * maudeLatexBuffer.hh (class MaudeLatexBuffer): updated decls for generateReduce(), generateContinue(), generateRewrite(), generateFrewrite(), generateErewrite() * erewrite.cc (Interpreter::eRewrite): echo debug modifier, both in regular output and latex (Interpreter::eRewriteCont): echo debug modifier in latex * execute.cc (Interpreter::reduce, Interpreter::rewrite) (Interpreter::fRewrite): echo debug modifier, both in regular output and latex (Interpreter::rewriteCont, Interpreter::fRewriteCont): echo debug modifier in latex * maudeLatexBuffer.cc (MaudeLatexBuffer::generateReduce) (MaudeLatexBuffer::generateRewrite) (MaudeLatexBuffer::generateFrewrite) (MaudeLatexBuffer::generateErewrite) (MaudeLatexBuffer::generateContinue): handle debug flag * visibleModule.hh (class VisibleModule): made latexPrintStrategy() public * latexViewPrint.cc (SyntacticView::latexShowProcessedView): handle strat to expr mappings * latexRenaming.cc (Renaming::latexRenaming): handle strat mappings; handle attr mappings with sorts 2023-07-28 Steven Eker * visibleModule.hh (class VisibleModule): updated decl for latexPrintStrategy() * latexStrategyPrint.cc (VisibleModule::latexPrintStrategy): made const * mixfixModule.hh (class MixfixModule): updated decl for latexPrintStrategyTerm() * latexTermPrint.cc (MixfixModule::latexPrintStrategyTerm): made const * visibleModule.hh (class VisibleModule): made latexPrintStrategy() non-static * latexStrategyPrint.cc (VisibleModule::latexPrintStrategy): finished implementation * visibleModule.hh (class VisibleModule): made latexPrintConditionFragment() and latexPrintCondition() (both versions) static * latexStrategyPrint.cc (VisibleModule::latexPrintStrategy): renamed from latexPrettyPrint and moved from class MixfixModule to class VisibleModule * latexTermPrint.cc (MixfixModule::latexPrintStrategyTerm): moved here * latexStrategyPrint.cc (MixfixModule::latexPrintStrategyTerm): use simpler latexPrettyPrint() * mixfixModule.hh (class MixfixModule): updated decl for latexPrettyPrint() (StrategyExpression* version) * latexModulePrint.cc (VisibleModule::latexPrintEquation): use simpler latexPrettyPrint() (2 places) (VisibleModule::latexPrintRule): use simpler latexPrettyPrint() (2 places) (VisibleModule::latexShowAttributes): use simpler latexPrettyPrint() (2 places) (VisibleModule::latexShowPolymorphAttributes): use simpler latexPrettyPrint() (2 places) (VisibleModule::latexPrintMembershipAxiom): use simpler latexPrettyPrint() (VisibleModule::latexPrintConditionFragment): use simpler lexPrettyPrint() (7 places) 2023-07-27 Steven Eker * mixfixModule.hh (class MixfixModule): added decl for Strategy* version of latexPrettyPrint() (class MixfixModule): added decl for latexPrintStrategyTerm() * latexStrategyPrint.cc: created * visibleModule.hh (class VisibleModule): added decl for latexPrintStrategyDefinition() * latexModulePrint.cc (VisibleModule::latexPrintStrategyDefinition): added * visibleModule.hh (class VisibleModule): added decl for latexPrintStrategyDecl() * latexModulePrint.cc (VisibleModule::latexShowRls) (VisibleModule::latexShowEqs, VisibleModule::latexShowMbs): use size() (VisibleModule::latexShowDecls): code cleaning (VisibleModule::latexShowPolymorphDecl): code cleaning (VisibleModule::latexPrintStrategyDecl): added (VisibleModule::latexShowImportscode): cleaning * visibleModule.hh (class VisibleModule): added decls for latexShowStrats(), latexShowSds() * latexModulePrint.cc (VisibleModule::latexShowStrats): added (VisibleModule::latexShowSds): added (VisibleModule::latexShowModule): call latexShowStrats() and latexShowSds() * decomposeEqualitySymbol.cc (DecomposeEqualitySymbol::domainSortAlwaysLeqThan): added comment (DecomposeEqualitySymbol::decompose): code cleaning (DecomposeEqualitySymbol::attachSymbol): code cleaning (DecomposeEqualitySymbol::postInterSymbolPass): code cleaning * commutativeDecomposeEqualitySymbol.cc (CommutativeDecomposeEqualitySymbol::domainSortAlwaysLeqThan): added comment (CommutativeDecomposeEqualitySymbol::decompose): code cleaning * decomposeEqualitySymbol.cc (DecomposeEqualitySymbol::eqRewrite): only consider decomposition if conjunctionSymbol is defined * commutativeDecomposeEqualitySymbol.cc (CommutativeDecomposeEqualitySymbol::eqRewrite): only consider decomposition if conjunctionSymbol is defined 2023-07-26 Steven Eker * specialSymbolTypes.cc: added CommutativeDecomposeEqualitySymbol * fancySymbols.cc (MixfixModule::newFancySymbol): added CommutativeDecomposeEqualitySymbol * symbolType.hh (class SymbolType): added COMMUTATIVE_DECOMPOSE_EQUALITY_SYMBOL to BasicTypes * mixfix.hh: added class CommutativeDecomposeEqualitySymbol * commutativeDecomposeEqualitySymbol.cc: created * commutativeDecomposeEqualitySymbol.hh: created * decomposeEqualitySymbol.hh: fix comment 2023-07-25 Steven Eker * decomposeEqualitySymbol.cc (DecomposeEqualitySymbol::decompose): use getPolymorphIndex() (DecomposeEqualitySymbol::DecomposeEqualitySymbol): fix bug where we were forgetting to initialized conjunctionSymbol * mixfixModule.hh (getPolymorphIndex): added (getSymbolType): made argument const * decomposeEqualitySymbol.hh (class DecomposeEqualitySymbol): added decl for decompose() * decomposeEqualitySymbol.cc (DecomposeEqualitySymbol::decompose): added * mixfix.hh: added class DecomposeEqualitySymbol * decomposeEqualitySymbol.cc (DecomposeEqualitySymbol::eqRewrite): only support standard, eager strategy 2023-07-24 Steven Eker * decomposeEqualitySymbol.cc: added * decomposeEqualitySymbol.hh: added * symbolType.hh (class SymbolType): added DECOMPOSE_EQUALITY_SYMBOL * fancySymbols.cc (MixfixModule::newFancySymbol): added DecomposeEqualitySymbol * specialSymbolTypes.cc: added DecomposeEqualitySymbol ===================================Maude151=========================================== 2023-07-21 Steven Eker * latexModulePrint.cc (VisibleModule::latexShowModule): use ImportModule:: latexModuleExpression() for parameter theories * latexViewPrint.cc (SyntacticView::latexShowProcessedView): use ImportModule:: latexModuleExpression() for fromTheory and toModule (SyntacticView::latexShowProcessedView): use ImportModule:: latexModuleExpression() for parameter theories * latexRenaming.cc (Renaming::latexRenaming): handle syntactic attributes * latexImportModule.cc (ImportModule::latexModuleExpression): insert parens where needed; fix bug in SUMMATION * latexCommon.cc (MixfixModule::latexStructuredName): rewritten to fix bug * latexModulePrint.cc (VisibleModule::latexShowImports): use ImportModule::latexModuleExpression() * importModule.hh (class ImportModule): added decl for latexImportModule() * latexImportModule.cc: created * mixfixModule.hh (class MixfixModule): updated decl for latexConstant() * latexCommon.cc (MixfixModule::latexConstant): take const Module* * latexRenaming.cc (Renaming::latexRenaming): made Module* arguments const * renaming.hh (class Renaming): updated decl for latexRenaming() * mixfixModule.hh (class MixfixModule): updated decl for latexSort() * latexCommon.cc (MixfixModule::latexSort): made module arg const Module* * renaming.cc (Renaming::printRenamingType): remove const qualifier * renaming.hh (class Renaming): added decl for latexRenamingType(); made printRenamingType() static * latexRenaming.cc (Renaming::latexRenamingType): added (Renaming::latexRenaming): use latexRenamingType() 2023-07-20 Steven Eker * latexViewPrint.cc (SyntacticView::latexShowProcessedView): use getNrSortMappings() + getNrOpMappings() to decide whether we need to end a line (SyntacticView::latexShowProcessedView): handle variable aliases (SyntacticView::latexShowProcessedView): handle op->term mappings 2023-07-19 Steven Eker * interpreter.cc (Interpreter::showProcessedView): echo command * latexViewPrint.cc (SyntacticView::latexShowProcessedView): call latexRenaming() * renaming.hh (class Renaming): added decl for latexRenaming() * latexRenaming.cc: created * mixfixModule.hh (class MixfixModule): added decl for latexConstant() * latexCommon.cc (MixfixModule::latexConstant): added * mixfixModule.hh (class MixfixModule): added decl for code version of latexSort() * latexCommon.cc (MixfixModule::latexSort): added code version * latexToken.cc (Token::latexName): follow < and > with empty group to prevent << and >> being transformed into guillemets * mixfixModule.hh (class MixfixModule): deleted decls for hasNonAlpha(), latexName() (both versions), latexIdentifier() * latexCommon.cc (MixfixModule::latexStructuredConstant): use Token::latexIdentifier() (MixfixModule::latexPrettyOp): use Token::latexIdentifier() (MixfixModule::latexIdentifier): deleted (MixfixModule::hasNonAlpha): deleted (MixfixModule::latexName): delete (both versions) * visibleModule.hh (VisibleModule::latexPrintModuleName): Token::latexName() (VisibleModule::latexPrintViewName): use Token::latexName() * latexModulePrint.cc (VisibleModule::latexShowVars): use Token::latexIdentifier() (VisibleModule::latexShowAttributes): use Token::latexIdentifier() (VisibleModule::latexShowPolymorphAttributes): use Token::latexIdentifier() * latexTermPrint.cc (MixfixModule::latexHandleVariable): use Token::latexIdentifier (MixfixModule::latexPrettyPrint): use Token::latexIdentifier() (MixfixModule::latexHandleIter): use Token::latexIdentifier() * latexDagNodePrint.cc (MixfixModule::latexHandleIter): use Token::latexIdentifier() (MixfixModule::latexHandleVariable): use Token::latexIdentifier() (MixfixModule::latexPrettyPrint): use Token::latexIdentifier() * latexCommon.cc (MixfixModule::latexStructuredName): use Token::latexName() (MixfixModule::latexSort): don't use Token::sortName() in the non-Token::AUX_STRUCTURED_SORT becaue it doesn't do anything special in this case; use Token::latexName() (MixfixModule::latexPrettyOp): use Token::latexName() (MixfixModule::latexPrintTokens): use Token::latexName() * maudeLatexBuffer.cc (MaudeLatexBuffer::generateModuleName): use Token::latexName() (MaudeLatexBuffer::generateModifiers): use Token::latexName() (MaudeLatexBuffer::generateCommand): use Token::latexName() * latexViewPrint.cc (SyntacticView::latexShowProcessedView): use Token::latexName() (3 places) * latexTermPrint.cc (MixfixModule::latexHandleString): use Token::latexName() (MixfixModule::latexHandleQuotedIdentifier): use Token::latexName() * latexModulePrint.cc (VisibleModule::latexPrintAttributes): use Token::latexName() (2 places) (VisibleModule::latexShowImports): use Token::latexName() (VisibleModule::latexShowModule): use Token::latexName() (2 places) (VisibleModule::latexShowAttributes): use Token::latexName() (6 places) (VisibleModule::latexShowPolymorphAttributes): use Token::latexName() (6 places) * latexDagNodePrint.cc (MixfixModule::latexHandleString): use Token::latexName() (MixfixModule::latexHandleQuotedIdentifier): use Token::latexName() * token.hh (class Token): added decls for latexName() (4 versions), latexIdentifier(), hasNonAlphanumeric() * latexToken.cc: created 2023-07-18 Steven Eker * interpreter.cc (Interpreter::showProcessedView): call latexShowProcessedView() * visibleModule.hh (class VisibleModule): made latexPrintModuleName() public * latexViewPrint.cc: created * latexModulePrint.cc (VisibleModule::latexShowPolymorphDecl): use latexPrettyOp() * token.cc (Token::prettyOpName): don't remove backquotes from ( or ) since it causes problems with op declarations * latexModulePrint.cc (VisibleModule::latexShowDecls): use latexPrettyOp() * mixfixModule.hh (class MixfixModule): added decl for latexPrettyOp() * token.hh (class Token): added decl for prettyOpName() * token.cc (Token::prettyOpName): added * latexCommon.cc (MixfixModule::latexPrettyOp): added 2023-07-17 Steven Eker * latexModulePrint.cc (VisibleModule::latexShowPolymorphDecl): call latexShowPolymorphAttributes() * visibleModule.hh (class VisibleModule): added decl for latexShowPolymorphAttributes() * latexModulePrint.cc (VisibleModule::latexShowPolymorphAttributes): added * latexCommon.cc (MixfixModule::latexPrintTails): don't use latexIdentifier() - directly generate \maudeSymbolic{} (MixfixModule::latexPrintTokens): ditto * latexTermPrint.cc (MixfixModule::latexPrettyPrint): use latexStructuredConstant() * latexDagNodePrint.cc (MixfixModule::latexPrettyPrint): use latexStructuredConstant() * latexModulePrint.cc (VisibleModule::latexShowDecls): use latexStructuredConstant() (VisibleModule::latexShowPolymorphDecl): use latexStructuredConstant() * mixfixModule.hh (class MixfixModule): added decl for latexStructuredConstant() * latexCommon.cc (MixfixModule::latexStructuredConstant): added * mixfixModule.hh (class MixfixModule): updated decl for latexStructuredName(); added decl for latexSort() * latexCommon.cc (MixfixModule::latexStructuredName): new calling convention (MixfixModule::latexSort): added (MixfixModule::latexType): use latexSort() 2023-07-14 Steven Eker * latexCommon.cc (MixfixModule::latexType): use latexStructuredName() * mixfixModule.hh (class MixfixModule): added decl for latexStructuredName() * latexCommon.cc (MixfixModule::latexStructuredName): added 2023-06-26 Steven Eker * latexModulePrint.cc (VisibleModule::latexShowAttributes): added * interpreter.hh (class Interpreter): updated decl for outputBanner() * interpreter.cc (Interpreter::outputBanner): pass date and time to generateBanner() * banner.cc (printBanner): take date and time arguments * maudeLatexBuffer.cc (MaudeLatexBuffer::generateBanner): take date and time arguments * maudeLatexBuffer.hh (class MaudeLatexBuffer): updated decl for generateBanner() * maudeLatexBuffer.cc (MaudeLatexBuffer::generateDag): take seconds argument * interpreter.cc (Interpreter::outputBanner): pass seconds to generateBanner() * interpreter.hh (class Interpreter): updated decl for outputBanner() * banner.cc (printBanner): take seconds as an argument * maudeLatexBuffer.hh (class MaudeLatexBuffer): added decl for generateBanner() * interpreter.hh (class Interpreter): added decl for outputBanner() * interpreter.cc (Interpreter::outputBanner): added * maudeLatexBuffer.cc (MaudeLatexBuffer::generateBanner): added 2023-06-23 Steven Eker * interpreter.cc (Interpreter::showSortsAndSubsorts): support latex * visibleModule.hh (class VisibleModule): added decl for latexShowSortsAndSubsorts() * latexModulePrint.cc (VisibleModule::latexShowSortsAndSubsorts): added * latexCommon.cc (MixfixModule::latexPrintTokens): use latexIdentifier() (MixfixModule::latexPrintTails): use latexIdentifier() * mixfixModule.hh (class MixfixModule): deleted decl for code version of latexName() * latexCommon.cc (MixfixModule::latexName): deleted code version * latexDagNodePrint.cc (MixfixModule::latexSuffix): use \maudeDisambigDot (MixfixModule::latexHandleIter): use latexIdentifier() (MixfixModule::latexHandleVariable): use latexIdentifier() (MixfixModule::latexPrettyPrint): use latexIdentifier() * latexTermPrint.cc (MixfixModule::latexSuffix): use \maudeDisambigDot (MixfixModule::latexHandleIter): use latexIdentifier() (MixfixModule::latexHandleVariable): use latexIdentifier() (MixfixModule::latexPrettyPrint): use latexIdentifier() * latexDagNodePrint.cc (MixfixModule::latexPrettyPrint): added Assert(), deleted #ifndef code; handle structured constant case * latexTermPrint.cc (MixfixModule::latexPrettyPrint): pick off structured constant case * latexModulePrint.cc (VisibleModule::latexShowVars): use latexIdentifier() (VisibleModule::latexShowDecls): use latexIdentifier() instead of latexName() on token codes (VisibleModule::latexShowPolymorphDecl): use latexIdentifier() instead of latexName() on token codes; use \maudeStructuredConstant * mixfixModule.hh (class MixfixModule): added decl for latexIdentifier() * latexCommon.cc (MixfixModule::latexIdentifier): added * latexModulePrint.cc (VisibleModule::latexShowDecls): use \maudeStructuredConstant 2023-06-22 Steven Eker * latexModulePrint.cc (VisibleModule::latexShowPolymorphDecl): space after poly * latexDagNodePrint.cc (MixfixModule::latexPrettyPrint): use latexSuffix() * latexCommon.cc (MixfixModule::latexType): use Rope version of latexName() * latexModulePrint.cc (VisibleModule::latexShowDecls): use Token::sortName() for constants which may be parameterized (VisibleModule::latexShowModule): use \maudeParameter for parameter names and \maudeParameterColon for :: * mixfixModule.hh (class MixfixModule): added decl for Rope version of latexName() * latexCommon.cc (MixfixModule::latexName): added rope version * latexModulePrint.cc (VisibleModule::latexShowPolymorphDecl): added (VisibleModule::latexShowPolymorphs): added (VisibleModule::latexShowModule): use latexShowPolymorphs() * visibleModule.hh (class VisibleModule): updated decls for latexShowMbs(), latexShowEqs(), latexShowRls() * latexModulePrint.cc (VisibleModule::latexShowEqs): don't take endWithNewline argument (VisibleModule::latexShowRls): don't take endWithNewline argument (VisibleModule::latexShowMbs): don't take endWithNewline argument * latexDagNodePrint.cc (MixfixModule::latexPrettyPrint): use \maudeComma * latexTermPrint.cc (MixfixModule::latexPrettyPrint): use \maudeComma * latexModulePrint.cc (VisibleModule::latexShowModule): \n after end module keyword (VisibleModule::latexPrintRule): changed positions of $s (VisibleModule::latexPrintEquation): changed positions of $s (VisibleModule::latexPrintMembershipAxiom): changed positions of $s * latexTermPrint.cc (MixfixModule::latexHandleVariable): use \maudeVariableColon * latexDagNodePrint.cc (MixfixModule::latexHandleVariable): use \maudeVariableColon * latexCommon.cc (MixfixModule::latexType): use \maudeComma * latexModulePrint.cc (VisibleModule::latexShowSubsorts): use \maudeLessThan (VisibleModule::latexShowModule): use \maudeComma * latexCommon.cc (MixfixModule::latexType): fix comma bug 2023-06-21 Steven Eker * latexCommon.cc (MixfixModule::latexType): use \maudeLeftBracket, \maudeRightBracket * latexModulePrint.cc (VisibleModule::latexShowModule): use latexShowOps() * visibleModule.hh (class VisibleModule): added decls for latexShowOps(), latexShowDecls() * latexModulePrint.cc (VisibleModule::latexShowOps): added (VisibleModule::latexShowDecls): added * latexDagNodePrint.cc (MixfixModule::latexHandleVariable): use latexName() * latexTermPrint.cc (MixfixModule::latexHandleVariable): use latexName() * latexModulePrint.cc (VisibleModule::latexShowModule): use latexShowVars() * visibleModule.hh (class VisibleModule): added decl for latexShowVars() * latexModulePrint.cc (VisibleModule::latexShowVars): added * latexModulePrint.cc (VisibleModule::latexPrintAttributes): use \maudeLabel (VisibleModule::latexPrintMembershipAxiom) (VisibleModule::latexShowEqs, VisibleModule::latexShowRls): use \par at start rather than \newline at end (VisibleModule::latexShowImports) (VisibleModule::latexShowSorts, VisibleModule::latexShowSubsorts): use \par at start rather than \newline at end (VisibleModule::latexShowModule): use \par at start rather than \newline at end of header and tail * latexCommon.cc (MixfixModule::latexType): make arg const * mixfixModule.hh (class MixfixModule): updated decl for latexType() * visibleModule.hh (class VisibleModule): added decl for latexShowSubsorts() * latexModulePrint.cc (VisibleModule::latexShowSubsorts): added (VisibleModule::latexShowModule): call latexShowSubsorts() * visibleModule.hh (class VisibleModule): added decl for latexShowSorts() * latexModulePrint.cc (VisibleModule::latexShowSorts) (VisibleModule::latexPrintMembershipAxiom) (VisibleModule::latexPrintEquation) (VisibleModule::latexPrintRule) (VisibleModule::latexShowImports): use \maudeEndStatement (VisibleModule::latexShowModule): call latexShowSorts 2023-06-20 Steven Eker * visibleModule.hh (class VisibleModule): added decl for latexShowImports() * latexModulePrint.cc (VisibleModule::latexShowImports): added * interpreter.cc (Interpreter::showModule): added latex support * visibleModule.hh (VisibleModule::latexPrintModuleName): added (VisibleModule::latexPrintViewName): added (class VisibleModule): added decl for latexShowModule() * latexModulePrint.cc (VisibleModule::latexPrintConditionFragment): \maudeSortTest -> \maudeHasSort (VisibleModule::latexPrintMembershipAxiom): \maudeSortTest -> \maudeHasSort (VisibleModule::latexShowModule): added partial implementation * interpreter.cc (Interpreter::showMbs): added latex support * visibleModule.hh (class VisibleModule): added decls for latexShowMbs(), latexPrintMembershipAxiom() * latexModulePrint.cc (VisibleModule::latexPrintMembershipAxiom) (VisibleModule::latexShowMbs): added * interpreter.cc (Interpreter::showRls): added latex support * visibleModule.hh (class VisibleModule): added decls for latexShowRls(), latexPrintRule() * latexModulePrint.cc (VisibleModule::latexPrintAttributes): use latexPrint() (VisibleModule::latexPrintRule, VisibleModule::latexShowRls): added * latexTermPrint.cc (MixfixModule::latexPrettyPrint): added static version * printAttribute.hh (class PrintAttribute): added decl for latexPrint() * printAttribute.cc (PrintAttribute::latexPrint): added * mixfixModule.hh (class MixfixModule): added decl for static Term* latexPrettyPrint() * latexModulePrint.cc (VisibleModule::latexPrintEquation): call latexPrintAttributes() * visibleModule.hh (class VisibleModule): added decl for latexPrintAttributes() * latexModulePrint.cc (MixfixModule::latexPrintAttributes): added 2023-06-19 Steven Eker * visibleModule.hh (class VisibleModule): added decls for latexPrintCondition() (2 versions), latexPrintConditionFragment() * latexModulePrint.cc (VisibleModule::latexPrintEquation): call latexPrintCondition() (VisibleModule::latexPrintConditionFragment): added (VisibleModule::latexPrintEquation): use \maudeEquals (MixfixModule::latexPrintCondition): added 2 versions * visibleModule.hh (class VisibleModule): latexShowEq() -> latexPrintEquation() * latexModulePrint.cc (VisibleModule::latexShowEq): becomes latexPrintEquation (VisibleModule::latexShowEqs): use latexPrintEquation() * visibleModule.hh (class VisibleModule): updated decl for latexShowEqs() * latexModulePrint.cc (VisibleModule::latexShowEqs): take endWithNewline argument * latexDagNodePrint.cc (MixfixModule::latexHandleVariable): use latexType() * interpreter.cc (Interpreter::showEqs): show module name, generate latex comment * maudeLatexBuffer.cc (~MaudeLatexBuffer): don't use flushleft * maudeLatexBuffer.ccM (MaudeLatexBuffer): don't use flushleft * interpreter.cc (Interpreter::showEqs): use maudeShowParagraph * maudeLatexBuffer.cc (MaudeLatexBuffer::generateResult): MaudeParagraph -> maudeResultParagraph (MaudeLatexBuffer::generateCommand) (MaudeLatexBuffer::generateContinue): maudeParagraph -> maudeResultParagraph * latexTermPrint.cc (MixfixModule::latexHandleVariable): use latexType() * mixfixModule.hh (class MixfixModule): updated decls for latexHandleMinus(), latexHandleDivision(), latexHandleFloat(), latexHandleString(), latexHandleQuotedIdentifier(), latexHandleVariable() * latexTermPrint.cc (MixfixModule::latexHandleVariable): \maudeIdentifer -> \maudeIdentifier * latexDagNodePrint.cc (MixfixModule::latexHandleVariable): \maudeIdentifer -> \maudeIdentifier * visibleModule.hh (class VisibleModule): added decls for latexShowEqs(), latexShowEq() * latexTermPrint.cc (MixfixModule::latexHandleMinus): made const (MixfixModule::latexHandleDivision): made const (MixfixModule::latexHandleFloat): made const (MixfixModule::latexHandleString): made const (MixfixModule::latexHandleQuotedIdentifier): made const (MixfixModule::latexHandleVariable): made const * sharedPrint.cc (MixfixModule::ambiguous): made const * mixfixModule.hh (class MixfixModule): updated decl for ambiguous(), latexPrintPrefixName() * latexCommon.cc (MixfixModule::latexPrintPrefixName): made SymbolInfo& argument const * mixfixModule.hh (class MixfixModule): made Term* version of latexPrettyPrint() protected * interpreter.cc (Interpreter::showEqs): handle latexBuffer * maudeLatexBuffer.hh (MaudeLatexBuffer::getStream): added * latexModulePrint.cc: created 2023-06-16 Steven Eker * mixfixModule.hh (class MixfixModule): added decl for Term* version of latexPrettyPrint() * latexTermPrint.cc (MixfixModule::latexHandleVariable): added (MixfixModule::latexHandleSMT_Number): added (MixfixModule::latexPrettyPrint): added * mixfixModule.hh (class MixfixModule): added decls for Term* versions of latexHandleDivision(), latexHandleFloat(), latexHandleString(), latexHandleQuotedIdentifier() * latexTermPrint.cc (MixfixModule::latexHandleDivision): added (MixfixModule::latexHandleFloat): added (MixfixModule::latexHandleString): added (MixfixModule::latexHandleQuotedIdentifier): added * mixfixModule.hh (class MixfixModule): added decl for Term* version of latexHandleIter() * latexTermPrint.cc (MixfixModule::latexHandleIter): added * termPrint.cc (MixfixModule::handleIter): use saved nat rather than calling getNat() a second time * latexDagNodePrint.cc (MixfixModule::latexHandleIter): use safeCastNonNull<>() * mixfixModule.hh (class MixfixModule): added decls for Term* versions of latexComputeColor(), latexSuffix(), latexHandleMinus() * latexTermPrint.cc: created * latexCommon.cc (MixfixModule::latexPrintPrefixName): moved here * mixfixModule.hh (class MixfixModule): made latexPrefix(), latexSuffix(), latexPrintTails(), latexPrintTails(), latexComputeColor() static * latexCommon.cc: moved latexRed, latexGreen, latexBlue, latexCyan, latexMagenta, latexYellow, latexResetColor definitions here (MixfixModule::latexPrefix): moved here (MixfixModule::latexPrintTokens): moved here (MixfixModule::latexPrintTails): moved here * mixfixModule.hh (class MixfixModule): made latexFancySpace() static * latexCommon.cc (MixfixModule::latexFancySpace): moved here * mixfixModule.hh (class MixfixModule): hasAlpha() decl -> hasNonAlpha() * latexCommon.cc (MixfixModule::latexName): moved here (both versions) (MixfixModule::hasAlpha): moved here and becomes hasNonAlpha() (MixfixModule::latexName): use hasNonAlpha() (MixfixModule::latexType): moved here * latexDagNodePrint.cc: made latexRed, latexGreen, latexBlue, latexCyan, latexMagenta, latexYellow latexResetColor local to MixfixModule * mixfixModule.hh (class MixfixModule): added static const for latexRed, latexGreen, latexBlue, latexCyan, latexMagenta, latexYellow, latexResetColor 2023-06-15 Steven Eker * latexDagNodePrint.cc (MixfixModule::latexName): convert ' to \textquotesingle because '' means something different in LaTeX (MixfixModule::latexHandleQuotedIdentifier): use \textquotesingle for lead quote (MixfixModule::latexName): use \maudeSingleQuote for ' (MixfixModule::latexHandleQuotedIdentifier): use \maudeQid; use \maudeSingleQuote for ' * erewrite.cc (Interpreter::eRewriteCont): use MaudeLatexBuffer::generateContinue() * execute.cc (Interpreter::fRewriteCont): use MaudeLatexBuffer::generateContinue() * maudeLatexBuffer.hh (class MaudeLatexBuffer): added decl for generateErewrite() * maudeLatexBuffer.cc (MaudeLatexBuffer::generateErewrite): added * erewrite.cc (Interpreter::eRewrite): use MaudeLatexBuffer::generateErewrite() * maudeLatexBuffer.cc (MaudeLatexBuffer::generateReduce) (MaudeLatexBuffer::generateRewrite) (MaudeLatexBuffer::generateFrewrite): use generateCommand() * maudeLatexBuffer.hh (class MaudeLatexBuffer): added decl for generateCommand() * maudeLatexBuffer.cc (MaudeLatexBuffer::generateRewrite): use printModifiers(), generateModifiers() (MaudeLatexBuffer::generateReduce): use printModifiers(), generateModifiers() (MaudeLatexBuffer::generateCommand): added * execute.cc (Interpreter::fRewrite): use MaudeLatexBuffer::generateFrewrite() * maudeLatexBuffer.hh (class MaudeLatexBuffer): added decls for generateModifiers(), generateFrewrite() * maudeLatexBuffer.cc (MaudeLatexBuffer::generateModifiers): added (MaudeLatexBuffer::generateFrewrite): added * mixfixModule.hh (class MixfixModule): added decl for printModifiers() * prettyPrint.cc (MixfixModule::printModifiers): added 2023-06-14 Steven Eker * execute.cc (Interpreter::rewriteCont): call generateContinue() on latexBuffer (Interpreter::rewrite): call generateRewrite() latexBuffer * maudeLatexBuffer.hh (class MaudeLatexBuffer): added decls for generateStats(), generateTiming(), generateContinue(), generateRewrite() * maudeLatexBuffer.cc (MaudeLatexBuffer::generateStats): added (MaudeLatexBuffer::generateTiming): added (MaudeLatexBuffer::generateResult): call generateStats() (MaudeLatexBuffer::generateStats): support show breakdown (MaudeLatexBuffer::generateContinue): added (MaudeLatexBuffer::generateContinue): added 2023-06-13 Steven Eker * latexDagNodePrint.cc (MixfixModule::latexPrintPrefixName): use latexFancySpace() (2 places) (MixfixModule::latexPrintTokens): use latexFancySpace() (2 places) (MixfixModule::latexPrintTails): use latexFancySpace() (2 places) (MixfixModule::latexType): don't use \left[ and \right] for kinds use \maudeLeftParen, \maudeRightParen everywhere (MixfixModule::latexName): treat < > as \maudeSingleChar{} (MixfixModule::latexName): treat ; : & $ # _ as \maudeSingleChar{} (MixfixModule::latexHandleIter): use latexName() to clean up latex special characters (MixfixModule::latexFancySpace): handle foreground colors * mixfixModule.hh (class MixfixModule): added decl for latexFancySpace() * latexDagNodePrint.cc (MixfixModule::latexHandleQuotedIdentifier): use \maudeString{} (MixfixModule::latexHandleString): use \maudeString{} (MixfixModule::latexPrettyPrint): set globalIndent = 0 (MixfixModule::latexFancySpace): added * maudeLatexBuffer.cc (MaudeLatexBuffer::generateReduce) (MaudeLatexBuffer::generateResult): use maudeParagraph environment (MaudeLatexBuffer::generateReduce): use comment environment * mixfixModule.hh (class MixfixModule): added decl for hasAlpha() * latexDagNodePrint.cc (MixfixModule::latexName): use \maudeAllowBreak (MixfixModule::latexSuffix): use latexType() (MixfixModule::hasAlpha): added (MixfixModule::latexName): use hasAlpha() and \maudeSymbolic * maudeLatexBuffer.cc (MaudeLatexBuffer::generateReduce): use Tty::blockEscapeSequences(), Tty::unblockEscapeSequences() to avoid escape sequences in latex comments * latexDagNodePrint.cc (MixfixModule::latexPrettyPrint): fix missing \right) * maudeLatexBuffer.cc (MaudeLatexBuffer::generateReduce): generate latex comment (MaudeLatexBuffer::MaudeLatexBuffer): use article; use geometry 2023-06-12 Steven Eker * maudeLatexBuffer.hh (class MaudeLatexBuffer): added decl for generateModuleName() * maudeLatexBuffer.cc (MaudeLatexBuffer::generateModuleName): added (MaudeLatexBuffer::generateReduce): use generateModuleName() * latexDagNodePrint.cc (MixfixModule::latexName): moved \maudeIdentifier{}, \maudeSingleChar{} code from const char* version to int version (MixfixModule::latexType): use \maudeSort{} * maudeLatexBuffer.cc (MaudeLatexBuffer::generateResult): use \newline * mixfixModule.hh (class MixfixModule): added decl for code version of latexName() * latexDagNodePrint.cc (MixfixModule::latexType): convert rope to C string (MixfixModule::latexName): added code version * mixfixModule.hh (class MixfixModule): updated decl for latexName() * latexDagNodePrint.cc (MixfixModule::latexName): take const char* rather than token code (MixfixModule::latexType): use Token::sortName() and new latexName() convention * maudeLatexBuffer.hh (class MaudeLatexBuffer): generateSort() -> generateType() * maudeLatexBuffer.cc (MaudeLatexBuffer::generateSort): becomes generateType(); use latexType() (MaudeLatexBuffer::generateResult): use generateType() * mixfixModule.hh (class MixfixModule): added declaration for latexType() * latexDagNodePrint.cc (MixfixModule::latexType): added * mixfixModule.hh (class MixfixModule): made latexName() public and static * latexDagNodePrint.cc (MixfixModule::latexPrettyPrint): use latexName() in prefix case (MixfixModule::latexPrintTokens): use latexName() (MixfixModule::latexName): handle 10 characters with special meanings in latex * mixfixModule.hh (class MixfixModule): added decl for latexName() * latexDagNodePrint.cc (MixfixModule::latexComputeColor): handle color (MixfixModule::latexPrefix): handle color (MixfixModule::latexSuffix): handle color (MixfixModule::latexHandleIter): handle color (MixfixModule::latexPrintTokens): handle color (MixfixModule::latexPrintTails): handle color (MixfixModule::latexPrettyPrint): handle color (MixfixModule::latexPrintPrefixName): added (MixfixModule::latexHandleIter): use latexPrintPrefixName() (MixfixModule::latexPrettyPrint): use latexPrintPrefixName() (2 places) (MixfixModule::latexHandleDivision): use \maudeNumber{} (MixfixModule::latexHandleIter): use \maudeNumber{} (2 places) (MixfixModule::latexHandleMinus): use \maudeNumber{} (MixfixModule::latexHandleSMT_Number): use \maudeNumber{} (MixfixModule::latexPrintTokens): use \maudeSpace (MixfixModule::latexPrintTails): use \maudeSpace (MixfixModule::latexName): added 2023-06-09 Steven Eker * mixfixModule.hh (class MixfixModule): added decl for static latexPrettyPrint() (class MixfixModule): added decls for latexComputeColor(), latexPrefix(), latexSuffix(), latexHandleIter(), latexHandleMinus(), latexHandleDivision(), latexHandleFloat(), latexHandleString(), latexHandleQuotedIdentifier(), latexHandleVariable(), latexHandleSMT_Number(), latexPrettyPrint(), latexPrintTokens(), latexPrintTails() * latexDagNodePrint.cc: created * maudeLatexBuffer.hh (class MaudeLatexBuffer): added decl for generateSort() * maudeLatexBuffer.cc (MaudeLatexBuffer::generateSort): added 2023-06-07 Steven Eker * execute.cc (Interpreter::endRewriting): use latexBuffer (Interpreter::reduce): use latexBuffer * interpreter.cc (Interpreter::Interpreter): init latexBuffer rather than latexLog * mixfix.hh: added class MaudeLatexBuffer * interpreter.hh (class Interpreter): replace data member latexLog with latexBuffer * interpreter.cc (Interpreter::beginLatexLog): use MaudeLatexBuffer (Interpreter::endLatexLog): delete latexBuffer * maudeLatexBuffer.cc: created * maudeLatexBuffer.hh: created 2023-06-06 Steven Eker * interpreter.hh (class Interpreter): added data member latexLog * interpreter.cc (Interpreter::Interpreter): init latexLog (Interpreter::beginLatexLog): added (Interpreter::endLatexLog): added * interact.cc (UserLevelRewritingContext::commandLoop): call endLatexLog() * interpreter.hh (class Interpreter): added decls for beginLatexLog(), endLatexLog() 2023-06-02 Steven Eker * importTranslation.cc (ImportTranslation::translateStrategy): replaced FOR_EACH_CONST with regular for loop (ImportTranslation::translateRegularSymbol): ditto 2023-05-17 Steven Eker * top.yy: added token KW_RESOURCES * commands.yy: add set show resources * interact.cc (UserLevelRewritingContext::commandLoop): call MemoryCell::maybeShowResources() on normal exit 2023-05-15 Steven Eker * interact.cc (UserLevelRewritingContext::commandLoop): use FAST_QUIT to determine if we delete the interpreter or not ===================================Maude150=========================================== 2023-05-10 Steven Eker * specialSymbolTypes.cc: added PrngManagerSymbol * fancySymbols.cc (MixfixModule::newFancySymbol): added support for PrngManagerSymbol * symbolType.hh (class SymbolType): added PRNG_MANAGER_SYMBOL 2023-04-26 Steven Eker * token.cc (Token::split): rewritten to use buffer (int& version) (Token::splitKind): rewritten to use buffer 2023-04-13 Steven Eker * top.yy: deleted polarity * commands.yy (polarityDot): added; use to replace polarity '.' (polarity): deleted * top.yy: added KW_ON_DOT KW_OFF_DOT polarityDot * lexer.ll: added KW_ON_DOT and KW_OFF_DOT to INITIAL mode ===================================Maude146=========================================== * banner.cc (printBanner): adjust indentation for 3.3.1 * modules.yy (toAttribute): overparse latex attribute without string (attribute): overparse latex attribute without string * termPrint.cc (MixfixModule::prettyPrint): use empty() * loopMode.cc (Interpreter::contLoop): use empty() * bufferPrint.cc (MixfixModule::prettyPrint): use empty() * fixUp.cc (SyntacticPreModule::fixUpSymbol): use empty() (SyntacticPreModule::fixUpPolymorph): use empty() * dagNodePrint.cc (MixfixModule::prettyPrint): use empty() 2023-04-12 Steven Eker * syntacticPreModule.hh (class SyntacticPreModule): Bool -> bool * entry.cc (MixfixModule::addOpDeclaration): use empty() (MixfixModule::addPolymorph): use empty() 2023-04-11 Steven Eker * quotedIdentifierSymbol.cc (QuotedIdentifierSymbol::attachData): use empty() * loopSymbol.cc (LoopSymbol::attachData): use empty() * ops.cc (SyntacticPreModule::makeDeclsConsistent): use empty() (2 places) * modules.yy (attribute): overparse prec/gather/format/strat/strategy/poly attributes without required information (toAttribute): overparse prec/gather/format attributes without required information (moduleExprDot): use Token* version of operator<<() (skipStrayArrow): use Token* version of operator<<() (parameter): use Token* version of operator<<() (declaration): use Token* version of operator<<() (skipStrayColon): use Token* version of operator<<() (domainRangeAttr): use Token* version of operator<<(); use $1 rather than lineNumber (viewStratMap): use Token* version of operator<<() * token.hh: added decl for Token* version of operator<<() * token.cc (operator<<): added Token* version * interact.cc (UserLevelRewritingContext::internalErrorHandler): call exit() rather than _exit() to avoid losing message on Macs (UserLevelRewritingContext::stackOverflowHandler): call exit() rather than _exit() to avoid losing message on Macs 2023-04-10 Steven Eker * interact.cc (UserLevelRewritingContext::stackOverflowHandler): fix grammar in message ===================================Maude145=========================================== 2023-04-07 Steven Eker * instantiateModuleWithFreeParameters.cc (ImportModule::handleInstantiationByParameter): added check for the parameter clashing with one of our pseudo-parameters (ImportModule::handleBoundParameters): added check for bound parameter clashing with one of our pseudo-parameters * renameModule.cc (ImportModule::localSort2): Assert() -> AlwaysAssert() (ImportModule::localSort2): QUOTE() copy in AlwaysAssert() 2023-04-06 Steven Eker * importModule.cc (ImportModule::addImport): check for pseudo-parameter capture * importModule.hh (class ImportModule): added data members pseudoParameters, pseudoParametersComputed; added decls for accumulatePseudoParameters() and getPseudoParameters() * pseudoParameters.cc: created 2023-04-04 Steven Eker * mixfixParser.cc (MixfixParse): pass nrTokensGuess to tokenSet * makeGrammar.cc (MixfixModule::makeSpecialProductions): getTokenMap() -> getTokenSet() * mixfixParser.cc (MixfixParser::parseSentence): use tokenSet * mixfixParser.hh (MixfixParser::tokenToIndex): use tokenSet (MixfixParser::getNrTerminals): use tokenSet (class MixfixParser): restored IntMap; use for variableTerminals, iterSymbolTerminals * mixfixParser.cc (MixfixParser::translateSpecialToken): use tokenSet * mixfixParser.hh (class MixfixParser): TokenMap -> TokenSet, tokenMap -> tokenSet (MixfixParser::getTokenSet): renamed from getTokenMap(), made inline and moved here 2023-04-03 Steven Eker * makeGrammar.cc (MixfixModule::makeGrammar): pass nrTokensGuess to MixfixParser() * mixfixParser.hh (class MixfixParser): updated decl for ctor * mixfixParser.cc (MixfixParser): take nrTokensGuess and use it to specify the initial number of buckets in tokenMap * instantiateModuleWithBoundParameters.cc (ImportModule::instantiateRenaming): use instantiateSortName() to instantiate operator names so that we catch parameterized constants * renaming.hh (class Renaming): updated decl for addOpMappingPartialCopy() * renaming.cc (Renaming::addOpMappingPartialCopy): take newFromName and newToName parameters 2023-03-31 Steven Eker * instantiateViewWithFreeParameters.cc (View::makeInstantiation): added 3 DebugInfo()s * instantiateModuleWithFreeParameters.cc (ImportModule::handleParameterizedConstant): handle polymorphic parameterized constants (ImportModule::handleParameterizedConstant): don't consider constants or polymorphic constants from a parameter theory * renaming.cc (Renaming::renameOp): more detailed warning when multiple mappings apply (Renaming::typeMatch): fix bug where we were not checking that the number of types matched the number of sort names (Renaming::renameOp): added DebugInfo() * importTranslation.cc: more detailed AlwaysAssert() 2023-03-30 Steven Eker * token.hh (class Token): added decl for computeSpecialProperty() * token.cc (Token::computeSpecialProperty): added; fix bug where something that starts with " but isn't a string can't be anything else (Token::checkForSpecialProperty): use computeSpecialProperty() and push_back() 2023-03-28 Steven Eker * mixfixParser.hh (class MixfixParser): deleted typedef IntMap * mixfixParser.cc (MixfixParser::translateSpecialToken): use auto for result of find() on variableTerminals and iterSymbolTerminals * mixfixParser.hh (class MixfixParser): use TokenMap for variableTerminals and iterSymbolTerminals * makeGrammar.cc (MixfixModule::makeSpecialProductions): use getTokenMap() * mixfixParser.cc (MixfixParser::insertProduction): use tokenToIndex() rather than tokens.insert() (MixfixParser::insertBubbleProduction): use tokenToIndex() rather than tokens.insert() (3 places) (MixfixParser::insertSpecialTerminal) (MixfixParser::insertVariableTerminal) (MixfixParser::insertIterSymbolTerminal): use tokenToIndex() rather than tokens.insert() (MixfixParser::translateSpecialToken): use tokenMap.size() rather than tokens.cardinality() (MixfixParser::parseSentence): use tokenMap.find() * mixfixParser.hh (MixfixParser::tokenToIndex): added * mixfixParser.cc (MixfixParser::getTokenSet): becomes getTokenMap() * mixfixParser.hh (class MixfixParser): added typedef TokenMap (class MixfixParser): replaced tokens with tokenMap (MixfixParser::getNrTerminals): use tokenMap * modules.yy: store() -> tokensStore() * top.yy: store() -> tokensStore(); converted tokensClear(), tokensStore(), fragClear(),fragStore(token) macros to inline functions * modules.yy: clear() -> tokensClear() * commands.yy (numbersModuleTerm4): clear() -> tokensClear() * top.yy: clear() macro to tokensClear() * entry.cc (MixfixModule::addPolymorph): contractTo(0) -> clear() (MixfixModule::addOpDeclaration): contractTo(0) -> clear() (2 places) * loopSymbol.cc (LoopSymbol::extractQidList): contractTo(0) -> clear() * makeGrammar.cc (MixfixModule::makePolymorphProductions): contractTo(0) -> clear() * compiler.cc (Compiler::inputGraph): contractTo(0) -> clear() * top.yy: contractTo(0) -> clear() * fileTable.cc (FileTable::abortEverything): contractTo(0) -> clear() (2 places) * commands.yy (command): contractTo(0) -> clear() (21 places) * makeGrammar.cc (MixfixModule::makeStrategyLanguageProductions): use clear() (MixfixModule::makeSymbolProductions): use clear() * renaming.cc (Renaming::addStratTarget): use pop_back() * token.cc (Token::dropChar): use string::pop_back() * ops.cc (SyntacticPreModule::makeDeclsConsistent): use empty(), back() and pop_back() 2023-03-27 Steven Eker * token.cc (Token::fixUp): use buffer.data() (both versions) (Token::bubbleToPrefixNameCode): use buffer.data() * token.hh (class Token): buffer becomes Vector * token.cc: buffer becomes Vector * renaming.hh (class Renaming): use Vector<> rather than vector<> for typedef AttrMap 2023-03-23 Steven Eker * entity.hh (class Entity): struct UserLt not needed because the default std::less provides an implementation defined strict total order over pointers (Entity::getNrUsers): remove the inefficient comment because size() is guaranteed constant time from C++98 onwards ===================================Maude144=========================================== 2023-03-21 Steven Eker * top.yy: added KW_GENERATE_BY * commands.yy (importMode): added generate-by * lexer.ll: added generate-by 2023-03-20 Steven Eker * dagNodePrint.cc (MixfixModule::handleVariable): added and commented out code to print variable index and variable dag node address for debugging purposes 2023-03-14 Steven Eker * banner.cc (printBanner): center name string * search.cc (Interpreter::showSearchPath): print rule labels when showRule == false 2023-03-10 Steven Eker * importTranslation.cc (ImportTranslation::translateExpr): initialize index to avoid compiler warning (ImportTranslation::translateTerm): initialize index to avoid compiler warning * modules.yy (fromSpec): don't use domainAndRange to avoid reduce/reduce conflict (viewEndOpMap): don't use domainAndRange to avoid reduce/reduce conflict (domainAndRange): deleted 2023-03-06 Steven Eker * mixfixParser.cc (MixfixParser::makeTerm): fixed spelling error in IssueWarning() ===================================Maude143=========================================== 2023-03-03 Steven Eker * modules.yy (domainAndRange): added (viewEndOpMap): use domainAndRange (fromSpec): use domainAndRange * token.hh (class Token): deleted decl for reallocateBuffer() (class Token): data member buffer becomes a vector; data member bufferLength deleted (Token::bufferExpandTo): deleted * token.cc (Token::fixUp): rewritten using vector buffer (both versions) (Token::bubbleToPrefixNameCode): rewritten using vector buffer (Token::reallocateBuffer): deleted * modules.yy (finalPair): use attributeName (cPair): use attributeName (attributeName): added (declaration): check for null module expression (moduleExprDot): handle missing module expression by returning null * top.yy: added attributeName * modules.yy (sortToken): refactored token types * top.yy: deleted nonterminals identifier inert startKeyword midKeyword attrKeyword; '@' takes a return value * modules.yy (stratName): define stratName * top.yy: added stratName nonterminal * modules.yy: stragegy uses of identifier moved to stratName * top.yy: KW_OO no longer declared to return a value * lexer.ll (id): added pconst to BAR_OP_ATTRIBUTE termination tokens; KW_OO no longer returns a value; added comment to explain while we still need a return value for KW_VIEW 2023-03-02 Steven Eker * modules.yy (sortToken): use attrKeyword rather than attrKeyword2 (sortToken): add KW_COLON2 for consistency * top.yy: deleted attrKeyword2 * modules.yy (inert): move '[' | ']' here (attrKeyword2): merged with attrKeyword * top.yy: deleted startKeyword2 * modules.yy (inert): moved ',' | KW_TO here from identifier (tokenBarDot): no longer need ',' | KW_TO (startKeyword2): merged into startKeyword * interpreter.cc (Interpreter::makeModule): added comment to explain why we don't leak memory on failure * variantUnify.cc (Interpreter::variantUnify): use range-based for loops * variantMatch.cc (Interpreter::variantMatch): use range-based for loops * syntacticView.cc (SyntacticView::handleVarDecls): use range-based for loop * search.cc (Interpreter::search): use range-based for loop * interpreter.cc (Interpreter::updateSet): use range erase() (Interpreter::makeModule): use range-based for loop * getVariants.cc (Interpreter::getVariants): use range-based for loops * instantiateViewWithFreeParameters.cc (View::handleInstantiationByModuleView): use range-based for loop and safeCastNonNull<>() (View::handleOpToTermMappings): use range-based for loop (View::handleStratToExprMappings): use range-based for loop * moduleExpression.cc (ModuleExpression::deepSelfDestruct): use range-based for loops (operator<<):use range-based for loop * instantiateModuleWithFreeParameters.cc (ImportModule::handleInstantiationByParameter): use range-based for loop (ImportModule::handleRegularImports): use Index and range-based for loop * instantiateModuleWithBoundParameters.cc (ImportModule::handleSummation): use Index and range-based for loop * mixfixModule.cc (MixfixModule::checkFreshVariableNames): use range-based for loops (~MixfixModule): use range-based for loops (MixfixModule::getSMT_Info): use range-based for loops (MixfixModule::validForSMT_Rewriting): use Index and range-based for loops * entry.cc (MixfixModule::checkIterated): use range-based for loop 2023-03-01 Steven Eker * modules.yy (kind): added (typeName1Dot): use kind (typeName1): use kind * top.yy: added type decl for typeName1Dot * modules.yy (moduleExprDot): use tokenDot (sortDot): use tokenDot (endBubble): use tokenDot (dot): use tokenDot (endSortNameList): use tokenDot (classDecl): don't parse period here (classDef): use expectedDot (cPairList): rewritten to have dangling comma and allow empty list (typeName1Dot): added (finalPair): use typeName1Dot * top.yy: added type decl for tokenDot * modules.yy (endSortNameList): added (declaration): use endSortNameList for sort (endSubsortList): added (declaration): use endSubsortList for subsort (declaration): use endSubsortList for subclass (subsortList): redefined to have trailing '<' (tokenDot): added (classDecl): added (declaration): use classDecl * command.cc (SyntacticPreModule::showModule): only use sortName() for constants that have Token::AUX_STRUCTURED_SORT (SyntacticPreModule::showModule): put parens around parameterized constant names in ops declaration 2023-02-28 Steven Eker * makeGrammar.cc (MixfixModule::makeParameterizedSortProductions): use range-based for loop (MixfixModule::makeLabelProductions): use range-based for loop (MixfixModule::makeSpecialProductions): use range-based for loop; deleted commented out print statement * interpreter.cc (Interpreter::cleanCaches): added comment to explain the need to iterate * modules.yy (view): call cleanCaches() if we displace a view * syntacticPreModule.cc (SyntacticPreModule::finishModule): call cleanCaches() rather than destructUnusedModules() (SyntacticPreModule::finishModule): only call cleanCaches() if we displaced a module. * interpreter.hh (class Interpreter): added decl for cleanCaches() * interpreter.cc (Interpreter::cleanCaches): added * moduleCache.cc (ModuleCache::regretToInform): use safeCastNonNull<>() * viewCache.hh (class ViewCache): updated decl for destructUnusedViews() * viewCache.cc (ViewCache::destructUnusedViews): rewritten (ViewCache::regretToInform): use safeCastNonNull<>() * moduleCache.cc (ModuleCache::destructUnusedModules): rewritten to work in forwards direction after all * viewCache.cc (ViewCache::destructUnusedViews): added DebugAdvisory() * moduleCache.hh (class ModuleCache): updated decl for destructUnusedModules() * moduleCache.cc (ModuleCache::destructUnusedModules): return number of destructed modules * moduleCache.hh (class ModuleCache): updated decl for destructUnusedModules() * moduleCache.cc (ModuleCache::destructUnusedModules): reimplemented; make a since reverse pass through the cache and return a true if we destructed a module 2023-02-27 Steven Eker * lexerAux.hh: added decl for missingToken() * lexerAux.cc (bubbleEofError): call analyzeEofError() (analyzeEofError): count parentheses (missingToken): added * lexerAux.hh: added decls for startOfStatement(), analyzeEofError() * sharedTokens.hh (class SharedTokens): added analyzeEofError() as a friend * lexerAux.cc (startOfStatement): added (analyzeEofError): added * lexer.ll (id): added gb and generated-by to * top.yy: added KW_STATE * lexer.ll: added KW_STATE * commands.yy (command): new showSearchPath; added show path state command * interpreter.hh (class Interpreter): updated decl for showSearchPath(); * search.cc (Interpreter::showSearchPath): take showRule argument * preModule.cc (~PreModule): use range-based for loop (2 places) (PreModule::processParameters): use range-based for loop (PreModule::processExplicitImports): use range-based for loop * viewExpression.cc (ViewExpression::deepSelfDestruct): use range-based for loop * bottom.yy (deepSelfDestructViewExpressionVector): use range-based for loop * enclosingObject.cc (EnclosingObject::findFirstClash): use range-based for loop (EnclosingObject::addConflictsWithBoundParameters): use range-based for loop * command.cc (SyntacticPreModule::printAttributes): use range-based for loop * bufferPrint.cc (MixfixModule::printSort): use range-based for loop (MixfixModule::printDotSort): use range-based for loop (MixfixModule::printVarSort): use range-based for loop * auxProperty.cc (Token::joinParameterList): use range-based for loop * importModule.cc (ImportModule::importSorts): use range-based for loop (2 places) (ImportModule::donateSorts): use range-based for loop (ImportModule::importOps): use range-based for loop (2 places) (ImportModule::donateOps): use range-based for loop (ImportModule::fixUpImportedOps): use range-based for loop (2 places) (ImportModule::fixUpDonatedOps): use range-based for loop (ImportModule::importStatements): use range-based for loop (2 places) (ImportModule::donateStatements): use range-based for loop ===================================Maude142=========================================== 2023-02-24 Steven Eker * renaming.hh (class Renaming): added override annotations for addParameter2(), addVarDecl(), addType() * lexerAux.cc (bubbleEofError): give both line number of EOF and line number of first token in the bubble * top.yy (top): don't recognize empty sentence anymore; it only arises with ^C and yyterminate() will force parser to exit * ooSorts.cc (ImportModule::uniqueClassIdSortCandidate): use ContinueWarning() (ImportModule::findAtttributeSort): use ContinueWarning() * modules.yy (viewDeclaration): handle END_OF_INPUT and CHANGE_FILE error inside a view * top.yy (item): clear suppressParserErrorMessage if CHANGE_FILE was benign * bottom.yy (yyerror): only check suppressParserErrorMessage now that it subsumes UserLevelRewritingContext::interrupted() * lexer.ll (id): HARD_EOF -> END_OF_INPUT * modules.yy (declaration): HARD_EOF -> END_OF_INPUT * top.yy (top): recognize error followed by HARD_EOF or CHANGE_FILE HARD_EOF -> END_OF_INPUT * modules.yy (declaration): recognise error followed by CHANGE_FILE; call fileTable.endModule() in the two YYABORT cases to keep lineNumber to module mapping straight * interact.cc (UserLevelRewritingContext::commandLoop): bump lineNumber on interrupt or error if interactiveFlag is set * interpreter.cc (Interpreter::makeClean): take line number from currentview and print currentView name in message * interact.cc (UserLevelRewritingContext::commandLoop): don't print \n after parseError or ctrlC_Flag 2023-02-24 Steven Eker * top.yy (top): treat HARD_EOF as a quit directive; tread CHANGE_FILE as a no-op * lexer.ll (id): use CHANGE_FILE token * top.yy: added CHANGE_FILE token 2023-02-23 Steven Eker * bottom.yy (yyerror): honor suppressParserErrorMessage (cleanUpParser): clear suppressParserErrorMessage * top.yy: added global variable suppressParserErrorMessage * lexerAux.cc (bubbleEofError): set suppressParserErrorMessage to true * lexer.ll: added extern for suppressParserErrorMessage * lexerAux.cc (bubbleEofError): added * lexer.ll (id): call bubbleEorError() if we see an actual EOF inside a bubble and then yyterminate() * interpreter.cc (makeClean): use currentModule for the line number (addSelected): deleted commented out code * modules.yy (declaration): recognize error followed by HARD_EOF * interact.cc (commandLoop): yyparse() returns int, not bool * top.yy (item): allow HARD_EOF as a top item * lexer.ll (id): return HARD_EOF when an actual end-of-file is seen * top.yy: added token HARD_EOF * syntacticPreModule.cc (finishModule): insert OO includes into autImports * syntacticPreModule.hh (SyntacticPreModule): deleted data member ooIncludes * process.cc (processImports): don't use ooIncludes * moduleDatabase.cc (setOoInclude): use ImportMap rather than ImportSet * moduleDatabase.hh (ModuleDatabase): use ImportMap rather than ImportSet for OO includes 2023-02-22 Steven Eker * syntaxContainer.hh (SyntaxContainer): put attributeSuffixLength = 3 since I'm sure sure that strlen() is constexpr * ooProcess.cc (addHonoraryAttributeSymbols): use hasAttributeSuffix(); added DebugInfo() * syntacticPreModule.cc (stripAttributeSuffix): added Assert * syntaxContainer.hh (SyntaxContainer): added constexpr attributeSuffixLength * syntacticPreModule.hh (SyntacticPreModule): added decl for hasAttributeSuffix() * syntacticPreModule.cc (hasAttributeSuffix): added * ooProcess.cc (processClassSorts): use findClassIdSort() instead of findClassIdSortName() (findClassIdSortName): deleted * syntacticPreModule.hh (SyntacticPreModule): added decl for findClassIdSort() * importModule.hh (ImportModule): added decls for insertClassIdSortCandidates() and uniqueClassIdSortCandidate() * ooProcess.cc (findClassIdSort): added * ooSorts.cc (insertClassIdSortCandidates): added (uniqueClassIdSortCandidate): added (findClassIdSort): reimplemented using insertClassIdSortCandidates() and uniqueClassIdSortCandidate() 2023-02-21 Steven Eker * syntacticPreModule.cc (stripAttributeSuffix): added * syntacticPreModule.hh (SyntacticPreModule): added decl for stripAttributeSuffix() * ooProcess.cc (checkAttributes): use ATTRIBUTE() * ooTransform.cc (analyzeAttributeSetArgument): use ATTRIBUTE() * syntacticPreModule.hh (SyntacticPreModule): updated decl for analyzeAttributeSetArgument() (ATTRIBUTE): added * ooTransform.cc (analyzeAttributeSetArgument): take classSort argument and check attributes of a pure class (gatherObjects): pass classSort (or null) to analyzeAttributeSetArgument() (2 places) * process.cc (process): call purgeImpureClasses() after checkAttributes() * syntacticPreModule.hh (SyntacticPreModule): added decl for checkAttributes() * process.cc (process): call checkAttributes(); don't call purgeImpureClasses() * ooProcess.cc (processClassSorts): pureClasses -> localClasses (processClassOps): keep track of the attribute symbols we add for each class (checkAttributes): added * syntacticPreModule.hh (SyntacticPreModule): added decl for purgeImpureClasses(); pureClasses -> localClasses * process.cc (process): call purgeImpureClasses() * ooProcess.cc (purgeImpureClasses): added * syntacticPreModule.hh (SyntacticPreModule): deleted data member classSymbol from struct ClassDecl * ooProcess.cc (processClassSorts): record unproblematic local classes in pureClasses (processClassOps): don't record classSymbol * process.cc (process): clear pureClasses * syntacticPreModule.hh (SyntacticPreModule): added typedef SymbolSet; use for data member attributeSymbols; added typedef ClassAttrMap; use IdSet for data member classNames; added data member pureClasses * process.cc (process): deleted commented out attributeSetSort = 0 * ooProcess.cc (processClassSorts): delete commented out set classNames 2023-02-21 Steven Eker * instantiateViewWithFreeParameters.cc (View::handleAwkwardCase): added DebugEnter(); changed DebugNew() to DebugExit() * visibleModule.cc (VisibleModule::showKinds): use Sort::KIND rather than 0 * mixfixModule.cc (MixfixModule::instantiateSortTest): use Sort::KIND rather than 0 * instantiateViewWithFreeParameters.cc (View::handleAwkwardCase): fix comment * syntaxContainer.hh (class SyntaxContainer): added decl for default virtual destructor * renaming.hh (class Renaming): update decl for ~Renaming() * renaming.cc (~Renaming): added * parameterization.cc (ImportModule::addOpMappingsFromView): pass gcTargetTerm arg to addOpTargetTerm() * renaming.hh (class Renaming): updated decl for addOpTargetTerm() * renaming.cc (Renaming::printRenaming): term -> toTerm (Renaming::addSortConstantAndLabelMappings): term -> toTerm (Renaming::addOpTargetTerm): term -> toTerm (Renaming::addOpTargetTerm): take and store gcTargetTerm arg * renaming.hh (class Renaming): added member gcToTerm to struct struct OpMapping (Renaming::getOpTargetTerm): term -> toTerm 2023-02-20 Steven Eker * instantiateViewWithFreeParameters.cc (View::handleInstantiationByTheoryView): parameterCopyOfArgumentViewToTheory no longer const * importModule.hh (class ImportModule): updated decl for addOpMappingsFromView() - targetTheoryParameterCopy cannot be const because translating into it may instantiate sort test symbols for example * parameterization.cc (ImportModule::addOpMappingsFromView): don't look for other mappings for an op, once we've seen an op->term mapping for it in the view (ImportModule::addOpMappingsFromView): make a deepCopy() of toTerm if we're handling a theory-view * importTranslation.cc (ImportTranslation::ImportTranslation): handle preserveVariableIndicesFlag argument (ImportTranslation::preserveVariableIndices): added (ImportTranslation::findTargetVersionOfSymbol): added DebugAdvisory() for variable case since we don't expect it to be used. * importTranslation.hh (class ImportTranslation): added member function preserveVariableIndices(), data member preserveVariableIndicesFlag, ctor argument preserveVariableIndicesFlag * importTranslation.cc (ImportTranslation::findTargetVersionOfSymbol): use safeCastNonNull<>(), Assert() that we translated the sort for sort test (ImportTranslation::findTargetVersionOfSymbol): use safeCastNonNull<>(), Assert() that we translated the sort for variable; added DebugInfo()s (ImportTranslation::findTargetVersionOfSymbol): added more Assert()s (ImportTranslation::findTargetVersionOfSymbol): use safeCastNonNull<>() to recover the fromModule 2023-02-17 Steven Eker * syntacticPreModule.hh (class SyntacticPreModule): deleted decls for findAtttributeSetSort(), findAtttributeSort() (class SyntacticPreModule): deleted attributeSetSort data member * ooProcess.cc (SyntacticPreModule::findAtttributeSetSort): deleted (SyntacticPreModule::findAtttributeSort): deleted (SyntacticPreModule::processClassOps): use ImportModule::findAtttributeSort(); don't call findAtttributeSetSort() * process.cc (SyntacticPreModule::process): comment out clearing of attributeSetSort * ooTransform.cc (SyntacticPreModule::transformPatternAttributes): get attributeSetSort from attributeSetSymbol * ooRenaming.cc (Renaming::convertAttrMappings): use getLineNr() in IssueAdvisory() (Renaming::convertClassMappings): use getLineNr() in 4 IssueAdvisory()s * token.hh (Token::getLineNr): added * token.cc (Token::removeBoundParameterBrackets): fix bug where we were falling into '{' case and removing brackets from renamings * renaming.hh (class Renaming): deleted ATTR from enum class MappingType * renaming.cc (Renaming::printRenaming): don't check for MappingType::ATTR (Renaming::canonicalizeOpMappings): don't check for MappingType::ATTR (3 places) (Renaming::renameOp): don't check for MappingType::ATTR (Renaming::renameOp): deleted Assert() for MappingType::ATTR * renaming.hh (Renaming::isAttrMapping): deleted * ooView.cc (View::handleAttrMappings): rewritten to use AttrMap * ooRenaming.cc (Renaming::convertAttrMappings): rewritten to use AttrMap (Renaming::addClassMapping): moved here * modules.yy (fromAttrSpec): use typeName1 and addAttrType() * renaming.cc (Renaming::printRenaming): handle attr mappings separately * ooRenaming.cc (Renaming::convertClassMappings): moved here (Renaming::convertAttrMappings): moved here (Renaming::addAttrType): added (Renaming::addAttrMapping): moved here; rewritten (Renaming::addAttrTarget): moved here; rewritten * renaming.hh (class Renaming): added struct AttrMapping, typedef AttrMap, data member attrMap (Renaming::getNrAttrMappings): added (Renaming::getFromAttr): added (Renaming::getAttrTypeSorts): added (Renaming::getToAttr): added 2023-02-16 Steven Eker * importTranslation.cc (ImportTranslation::translate): RewriteStrategy* version, use strategyMap (ImportTranslation::translate): use range-based for loop (ImportTranslation::translateLabel): use range-based for loop (ImportTranslation::translateRegularSymbol): deleted commented out and unreachable code * importTranslation.hh (class ImportTranslation): added typedef StrategyMap and data member strategyMap; deleted data member directMap * importTranslation.cc (ImportTranslation::translate): Symbol* version, use symbolMap * importTranslation.hh (class ImportTranslation): added typedef SymbolPointerMap and data member symbolMap * syntacticPreModule.hh (class SyntacticPreModule): use Symbol::LessThan for typedef AttributeMap, so the user visible ordering doesn't depend on the vagaries of the memory allocator (class SyntacticPreModule): update comment on struct ObjectOccurrence 2023-02-15 Steven Eker * lexer.ll (): fix bug where we omitted endoth and an end of mixfix statement symbol ===================================Maude141=========================================== 2023-02-14 Steven Eker * renaming.cc (Renaming::printRenaming): Token::sortName for constant mappings * visibleModule.cc (VisibleModule::showPolymorphDecl): use Token::sortName for constants * viewDatabase.cc (ViewDatabase::showNamedViews): use range-based for loop * visibleModule.cc (VisibleModule::showVars): use range-based for loop * moduleDatabase.cc (ModuleDatabase::showNamedModules): use range-based for loop * syntacticView.cc (SyntacticView::showView): don't use static_cast (SyntacticView::showProcessedView): don't use static_cast * ooSorts.cc (ImportModule::findClassIdSort): improve warning messages (ImportModule::findAtttributeSort): improve warning messages * syntacticView.cc (SyntacticView::showView): print bubbles for strat->expr mappings * token.hh (class Token): deleted commented out declaration for splitParameterInstanceName() * token.cc (Token::codeToRope): deleted commented out function (Token::printTokenVector): don't put space in front of ( in fancySpacing mode (Token::splitParameterInstanceName): deleted commented out function * syntacticView.cc (SyntacticView::showView): print bubbles rather than terms for op->term and msg->term mappings * visibleModule.cc (VisibleModule::showImports): use removeBoundParameterBrackets() * syntacticView.cc (SyntacticView::showProcessedView): use removeBoundParameterBrackets() * token.hh (class Token): added decl for removeBoundParameterBrackets() * token.cc (Token::removeBoundParameterBrackets): added * moduleCache.cc (ModuleCache::showCreatedModules): removed #if 0'd out code * renaming.hh (class Renaming): made isAttrMapping() public 2023-02-13 Steven Eker * renaming.cc (Renaming::renameOp): ignore attr mappings in concrete version and Assert() they never arise in abstract version * renaming.hh (class Renaming): updated decl for printRenaming() (class Renaming): init nrUserSortMappings and nrUserOpMappings to NONE * renaming.cc (printRenaming): take showProcesed argument and use it to decide whether to print class/attr/msg mappings or generated sort/op mappings * interpreter.cc (showProcessedView): added * interpreter.hh (class Interpreter): added decl for showProcessedView() * commands.yy (command): added show processed view * top.yy: added KW_PROCESSED * lexer.ll: added processed * syntacticView.hh (class SyntacticView): added decl for showProcessedView * syntacticView.cc (SyntacticView::showProcessedView): added * ooProcess.cc: use getParameterTheoryCopy() * importModule.hh (ImportModule::getParameterTheoryCopy): added * syntacticPreModule.hh (class SyntacticPreModule): added decl for ImportModule* version of addHonoraryClassNames() * ooProcess.cc (SyntacticPreModule::addHonoraryClassNames): added ImportModule* version (SyntacticPreModule::addHonoraryClassNames): use ImportModule* version; handle parameter theories as well. * renaming.hh (class Renaming): move typeMatch() con set from private: to protected: * ooView.cc (View::handleAttrMappings): implemented * renaming.hh (Renaming::isAttrMapping): added (class Renaming): made isMsgMapping() protected * view.cc (View::evaluate): call recordUserMappings() if it is the first time we evaluate this view * view.hh (View::finishView): don't call recordUserMappings() here 2023-02-10 Steven Eker * view.cc (View::regretToInform): call purgeGeneratedMappings() * view.hh (View::finishView): call recordUserMappings() * renaming.hh (class Renaming): added decl for purgeGeneratedMappings() * renaming.cc (Renaming:: purgeGeneratedMappings): added * renaming.hh (Renaming::startAddingGeneratedMappings): added * ooView.cc (View::handleClassMappings): use hasSortMapping() * renaming.hh (hasSortMapping): added * view.cc (View::evaluate): call handleClassMappings() and handleAttrMappings() * view.hh (class View): added decls for getClassSortAndSymbol(), handleClassMappings(), handleAttrMappings() * ooView.cc: created * renaming.hh (Renaming::getFromClass): added (Renaming::getToClass): added * view.cc (View::checkSorts): use range-based for loop 2023-02-09 Steven Eker * importModule.cc (ImportModule::importModeString): use switch rather than constant array for robustness * syntacticPreModule.cc (SyntacticPreModule::addImport): added gb and generatedBy * specialTokens.cc: added gb and generatedBy * lexer.ll (id): added gb and generated-by * importModule.cc (ImportModule::importModeString): add generated-by * importModule.hh (class ImportModule): added GENERATED_BY to enum ImportMode 2023-02-08 Steven Eker * instantiateViewWithFreeParameters.cc (View::makeInstantiation): call handleParameterizedConstants() * prettyPrint.cc (operator<<): added Symbol* version which handles parameterized constants * command.cc (SyntacticPreModule::showModule): use sortName() for symbols whose prefix name has the AUX_STRUCTURED_SORT property (SyntacticPreModule::showModule): print constants using sortName() to handle parameterization * importModule.hh (class ImportModule): added decl for handleParameterizedConstants() * instantiateModuleWithFreeParameters.cc: (ImportModule::handleParameterizedConstants): added (ImportModule::makeInstantiation): call handleParameterizedConstants() * renaming.cc (Renaming::addSortMapping): add \n before this * instantiateViewWithFreeParameters.cc (View::handleInstantiationByTheoryView) (View::handleInstantiationByParameter) (View::handleInstantiationByModuleView): added DebugEnter()/DebugExit() (View::handleInstantiationByModuleView): added DebugInfo() (View::handleInstantiationByModuleView): fix bug where we were checking our toModule rather than the argument view's toModule to see if was a theory (View::handleInstantiationByTheoryView): parameterCopyOfTheory -> parameterCopyOfParameterTheory (View::handleInstantiationByTheoryView): pass parameterCopyOfArgumentViewToTheory to addOpMappingsFromView() * renaming.cc (Renaming::addSortMapping): more detailed Assert() 2023-02-07 Steven Eker * instantiateViewWithFreeParameters.cc (View::handleInstantiationByParameter): call addConstantRenamingsForParameterChange() (View::handleInstantiationByParameter): pass toModule rather than parameterCopyOfTheory to addConstantRenamingsForParameterChange() as the user of parameterCopyOfTheory * ooProcess.cc (SyntacticPreModule::processClassOps): use PCONST flag for class symbols in a theory * syntacticPreModule.cc (SyntacticPreModule::finishModule): use PreModule::isTheory() * preModule.cc (PreModule::addParameter): use PreModule::isTheory() * preModule.hh (PreModule::isTheory): added * parameterization.cc: (ImportModule::addOpMappingsFromView): take targetTheoryParameterCopy argument (ImportModule::addOpMappingsFromView): handle the theory-view case where the parameter copy of the target theory might map newName to X$newName * importModule.hh (class ImportModule): addOpMappingsFromView() now takes an argument targetTheoryParameterCopy * instantiateModuleWithFreeParameters.cc (ImportModule::makeInstantiation): use range-based for loop (ImportModule::handleInstantiationByTheoryView): parameterTheory -> targetTheoryParameterCopy; pass targetTheoryParameterCopy to addOpMappingsFromView() * parameterization.cc: (ImportModule::addOpMappingsFromView): rewritten to look at mapped-to name in parameter copy rather than PCONST 2023-02-06 Steven Eker * instantiateModuleWithFreeParameters.cc: (ImportModule::handleInstantiationByParameter): call addConstantRenamingsForParameterChange() * importModule.hh (class ImportModule): deleted decl for addConstantMappingsFromModuleView() (class ImportModule): added decl for addConstantRenamingsForParameterChange() * parameterization.cc: (ImportModule::addConstantMappingsFromModuleView): deleted * instantiateModuleWithFreeParameters.cc: (ImportModule::handleInstantiationByModuleView): don't call addConstantMappingsFromModuleView() * parameterization.cc (ImportModule::addConstantRenamingsForParameterChange): added (ImportModule::translateComponent): fix wrong comment; we find a connected component in parameterCopyUser (ImportModule::addFromPartOfRenaming): handle pconst case (ImportModule::addOpMappingsFromView): handle pconst constants after all * instantiateModuleWithFreeParameters.cc (ImportModule::handleInstantiationByModuleView): use range-based for loop * parameterization.cc (ImportModule::addOpMappingsFromView): don't handle constanst with pconst here * instantiateModuleWithFreeParameters.cc (ImportModule::handleInstantiationByModuleView): use Index and getNrParameters() * parameterization.cc (ImportModule::makeParameterCopy): addSortAndLabelMappings() -> addSortConstantAndLabelMappings() (ImportModule::makeParameterCopy): handle pconsts before imported modules since addSortConstantAndLabelMappings() can handle dups * renaming.hh (class Renaming): addSortAndLabelMappings() -> addSortConstantAndLabelMappings() * renaming.cc (Renaming::addSortAndLabelMappings): becomes addSortConstantAndLabelMappings(); handle constant mappings generated by pconst * entry.cc (MixfixModule::addPolymorph): use nrArgs rather than domainAndRange.length() - 1; * validateAttributes.cc (MixfixModule::validateAttributes): don't allow pconst for polymorphic constants * entry.cc (MixfixModule::addPolymorph): don't test for iter because we already do this in validateAttributes() 2023-02-03 Steven Eker * instantiateModuleWithFreeParameters.cc (handleInstantiationByModuleView): call addConstantMappingsFromModuleView() * importModule.hh (class ImportModule): added decl for addConstantMappingsFromModuleView() * parameterization.cc (ImportModule::makeParameterCopy): use range-base for loop (2 places) (ImportModule::makeSummation): use range-base for loop (ImportModule::makeParameterCopy): map pconst constants c -> X$c (ImportModule::addConstantMappingsFromModuleView): added * visibleModule.cc (VisibleModule::showPolymorphAttributes): added pconst * command.cc (SyntacticPreModule::printAttributes): added pconst * visibleModule.cc (VisibleModule::showAttributes): added pconst * lexer.ll (id): added KW_PCONST * modules.yy (attribute): added KW_PCONST (attrKeyword): added KW_PCONST * top.yy: added KW_PCONST * symbolType.hh (class SymbolType): added PCONST to enum Flags * syntacticPreModule.hh (class SyntacticPreModule): updated decls of checkVariables() and :analyzeAttributeSetArgument() (both versions) * ooTransform.cc (SyntacticPreModule::StatementInfo::checkVariables): moved from outer class (SyntacticPreModule::transformSortConstraint) (SyntacticPreModule::transformEquation) (SyntacticPreModule::transformRule): new checkVariables() convention (SyntacticPreModule::garbageCollectAttributeSet): fixed comment (SyntacticPreModule::analyzeAttributeSetArgument): fixed missing space in IssueAdvisory() (SyntacticPreModule::gatherObjects): made const (both versions) * symbolType.hh (class SymbolType): added ITER to SIMPLE_ATTRIBUTES to fix a bug where we were not printing a warning if the attribute was given twice ===================================Maude140=========================================== 2023-02-02 Steven Eker * ooTransform.cc (SyntacticPreModule::gatherObjects): give full list intialization in push_back() to appease clang (SyntacticPreModule::gatherObjects): use default ctor and manually assign field to appease clang * syntacticPreModule.hh (class SyntacticPreModule): add missing overrides * ooTransform.cc (SyntacticPreModule::StatementInfo::chooseFreshVariableName): start numbered variables at 2 * ooProcess.cc (SyntacticPreModule::processClassOps): use attributeSuffix * renaming.cc (Renaming::convertAttrMappings): use attributeSuffix (2 places) * syntaxContainer.hh (class SyntaxContainer): added attributeSuffix * renaming.cc (Renaming::convertAttrMappings): ":_" -> "`:_" (2 places) * ooProcess.cc (SyntacticPreModule::processClassOps): ":_" -> "`:_" * ooTransform.cc (SyntacticPreModule::gatherObjects): use CONDITION_SUBJECT and CONDITION_PATTERN (SyntacticPreModule::gatherObjects): quietly ignore new objects in SUBJECT and CONDITION_SUBJECT positions * syntacticPreModule.hh (class SyntacticPreModule): remove DISALLOW from enum class GatherMode, add CONDITION_SUBJECT and CONDITION_PATTERN * modules.yy (cPair): detect missing colon * syntacticPreModule.hh (class SyntacticPreModule): added decl for addAttributePairNoColon() * syntacticPreModule.cc (SyntacticPreModule::addAttributePairNoColon): added 2023-02-01 Steven Eker * view.cc (View::checkSorts): fix warning text in the case a module declared sort in implicitly mapped to a sort declared in the target theory * importModule.hh (ImportModule::moduleDeclared): fix bug where we were not considering local declared sorts in a module * renameModule.cc (ImportModule::donateSorts2): removed commented out code and added comment about the 5/2/19 change * view.cc (View): use range-based for loop (~View): use range-based for loop (2 places) (View::clearOpTermMap): use range-based for loop (View::clearStratExprMap): use range-based for loop (View::insertStratToExprMapping): use range-based for loop (3 places) 2023-01-31 Steven Eker * ooTransform.cc (SyntacticPreModule::transformEquation): symmetric changes (SyntacticPreModule::transformSortConstraint): symmetric changes (SyntacticPreModule::checkVariables): don't set si.ignore = true after advisory since we're returning false which will stop progress (5 places) * syntacticPreModule.hh (class SyntacticPreModule): updated decls for doTransformation(), transformPatternAttributes(), transformSubjectAttributes() * ooTransform.cc (SyntacticPreModule::garbageCollectAttributeSet): fixed bug where we were not immediately returning after deleting attributeSet (SyntacticPreModule::transformSubjectAttributes): added DebugInfo()s (SyntacticPreModule::transformRule): call Verbose() (SyntacticPreModule::doTransformation): return bool to indicate if anything was transformed (SyntacticPreModule::transformPatternAttributes): return bool to indicate if transform took place (SyntacticPreModule::transformSubjectAttributes): return bool to indicate if transform took place (SyntacticPreModule::transformRule): use doTransformation() return value * syntacticPreModule.hh (class SyntacticPreModule): updated decls for transformSortConstraint(), transformEquation(), transformRule() * entry.cc (MixfixModule::handleSortConstraint) (MixfixModule::handleEquation, MixfixModule::handleRule): use new StatementTransformer convention * ooTransform.cc (SyntacticPreModule::transformSortConstraint) (SyntacticPreModule::transformEquation) (SyntacticPreModule::transformRule): return StatementTransformer::Outcome * statementTransformer.hh (class StatementTransformer): added enum class Outcome (class StatementTransformer): virtual functions now return Outcome * mixfixParser.cc (MixfixParser::makeStatementPart): call handleSortConstraint(), handleEquation(), handleRule() before adding print attribute because we need to know what variables are bound * entry.cc (MixfixModule::handleSortConstraint): don't call insertSortConstraint() (MixfixModule::handleEquation): don't call insertEquation() (MixfixModule::handleRule): don't call insertRule() * mixfixParser.cc (MixfixParser::makeStatementPart): call insertSortConstraint(); call handleSortConstraint() after attributes inserted; call insertEquation(); call handleEquation() after attributes inserted; call client.insertRule(rl); call handleRule() after attributes inserted * importModule.cc (ImportModule::donateStatements2): call checkSortConstraint() (ImportModule::donateStatements2): call checkEquation() * entry.cc (MixfixModule::handleSortConstraint): call checkSortConstraint() (MixfixModule::handleEquation): call checkEquation() (MixfixModule::handleRule): call checkRule() * ooProcess.cc (SyntacticPreModule::addHonoraryAttributeSymbols): rewritten to allow multiple declarations for an attribute operator * syntacticPreModule.hh (class SyntacticPreModule): transformOccurrence() -> transformClassArgument() * ooTransform.cc (SyntacticPreModule::transformPatternAttributes): "Attrs" -> "Atts" (SyntacticPreModule::garbageCollectAttributeSet): added (SyntacticPreModule::transformSubjectAttributes): call garbageCollectAttributeSet() (SyntacticPreModule::transformPatternAttributes): call garbageCollectAttributeSet() (SyntacticPreModule::transformOccurrence): DebugAlways() -> DebugAdvisory() (SyntacticPreModule::doTransformation): DebugAlways() -> DebugAdvisory() (SyntacticPreModule::transformEquation): call checkVariables() and doTransformation() (SyntacticPreModule::transformSortConstraint): call checkVariables() and doTransformation() (SyntacticPreModule::gatherObjects): added Assert()s (SyntacticPreModule::transformOccurrence): becomes transformClassArgument() (SyntacticPreModule::doTransformation): transformOccurrence() -> transformClassArgument() * syntacticPreModule.hh (class SyntacticPreModule): added decl for transformSubjectAttributes() * ooTransform.cc (SyntacticPreModule::analyzeAttributeSetArgument): check for second variable (SyntacticPreModule::transformSubjectAttributes): added (SyntacticPreModule::doTransformation): call transformSubjectAttributes() on each subject occurrence 2023-01-30 Steven Eker * syntacticPreModule.hh (class SyntacticPreModule): added decl for transformPatternAttributes() * ooTransform.cc (analyzeAttributeSetArgument): check for duplicate attributes (SyntacticPreModule::checkVariables): check consistancy of attribute set variables (SyntacticPreModule::gatherObjects): deepSelfDestruct() objectName as soon as we know we don't need it (SyntacticPreModule::transformPatternAttributes): added (SyntacticPreModule::doTransformation): call transformPatternAttributes() * syntacticPreModule.hh (class SyntacticPreModule): added decl for analyzeAttributeSetArgument() * ooTransform.cc (analyzeAttributeSetArgument): added * syntacticPreModule.hh (class SyntacticPreModule): added variableTerm data member to struct ObjectOccurrence * ooTransform.cc (SyntacticPreModule::transformRule): call checkVariables() (SyntacticPreModule::StatementInfo::chooseFreshVariableName): fix bug where we had + rather that += * syntacticPreModule.hh (class SyntacticPreModule): added decl for transformOccurrence() * ooTransform.cc (SyntacticPreModule::transformOccurrence): added * syntacticPreModule.hh (class SyntacticPreModule): patternOccurrence data member in struct ObjectInfo is now an ObjectOccurrence * ooTransform.cc (SyntacticPreModule::gatherObjects): use new patternOccurrence data type (SyntacticPreModule::checkVariables): use new patternOccurrence data type * syntacticPreModule.hh: moved here * ooTransform.cc (SyntacticPreModule::gatherObjects): use push_back() for subjectOccurrences (SyntacticPreModule::checkVariables): added * syntacticPreModule.hh (class SyntacticPreModule): added struct ObjectOccurrence (class SyntacticPreModule): added typedef ObjectOccurrences (class SyntacticPreModule): use ObjectOccurrences for subjectOccurrences in struct ObjectInfo * ooProcess.cc (SyntacticPreModule::processClassOps): call addHonoraryAttributeSymbols(); accumulate attribute symbols we generate * syntacticPreModule.hh (class SyntacticPreModule): added decl for addHonoraryAttributeSymbols() * ooProcess.cc (SyntacticPreModule::addHonoraryAttributeSymbols): added * process.cc (SyntacticPreModule::process): clear object-oriented processing data after we're done * syntacticPreModule.hh (class SyntacticPreModule): added data member attributeSymbols 2023-01-27 Steven Eker * ooTransform.cc (SyntacticPreModule::transformRule): use doTransformation() * syntacticPreModule.hh (class SyntacticPreModule): deleted decls for transformStatements(), classComplete(); added decl for doTransformation() * ooTransform.cc (SyntacticPreModule::transformStatements): deleted (SyntacticPreModule::classComplete): deleted (SyntacticPreModule::doTransformation): added * entry.cc (MixfixModule::handleSortConstraint): moved here (MixfixModule::handleEquation): moved here (MixfixModule::handleRule): moved here * mixfixModule.hh (MixfixModule::handleSortConstraint): added AdvisoryCheck() (MixfixModule::handleEquation): added AdvisoryCheck() (MixfixModule::handleEquation): added AdvisoryCheck() * process.cc (SyntacticPreModule::process): call installStatementTransformer(); don't call transformStatements() * ooTransform.cc (SyntacticPreModule::transformSortConstraint): added (SyntacticPreModule::transformEquation): added (SyntacticPreModule::transformRule): added * syntacticPreModule.hh (class SyntacticPreModule): derive from StatementTransformer (class SyntacticPreModule): added override declarations for transformSortConstraint(), transformEquation(), transformRule() * mixfixParser.hh (class MixfixParser): deleted static constexpr int DNT_FLAG * mixfixParser.cc (MixfixParser::makeStatementPart): use handleSortConstraint() don't use DNT_FLAG (MixfixParser::makeStatementPart): use handleEquation(), don't use DNT_FLAG (MixfixParser::makeStatementPart): use handleRule(), don't use DNT_FLAG * mixfixModule.hh (class MixfixModule): added data member statementTransformer (MixfixModule::installStatementTransformer): added (MixfixModule::handleRule): added (MixfixModule::handleEquation): added (MixfixModule::handleSortConstraint): added * mixfix.hh: added class StatementTransformer * statementTransformer.hh (class StatementTransformer): created * ooTransform.cc (SyntacticPreModule::gatherObjects): do class argument checking (SyntacticPreModule::recordClassArgument): added (SyntacticPreModule::isClassSort): added (SyntacticPreModule::findCorrespondingClassSort): added (SyntacticPreModule::gatherObjects): fix bug where I was using the Symbol id rather than the VariableTerm id to keep track of variable names * renameModule.cc (ImportModule::makeRenamedCopy): use Index, range-based for loop (ImportModule::localStatementsComplete): use range-base for loop (5 places); removed comment abut transitive imports (ImportModule::donateSorts2): use Index (5 places) (ImportModule::localSort2): removed commented out DebugAdvisoryCheck() now it is an Assert() (ImportModule::donateOps2): use Index and size() many places; remove old BUG comment; domainAndRangeLength -> domainAndRangeSize (ImportModule::fixUpDonatedOps2): use Index and size(); domainAndRangeLength -> domainAndRangeSize (ImportModule::localStatementsComplete): use range-based for loop for parameters and removed comment about checking whether collecting parameter labels is necessary 2023-01-26 Steven Eker * process.cc (SyntacticPreModule::process): call processingComplete() (SyntacticPreModule::process): pass unmodified type to VisibleModule() * mixfixModule.hh (MixfixModule::processingComplete): added * mixfixParser.cc (MixfixParser::makeAttributePart): use member function verion of isObjectOriented() * mixfixModule.hh (class MixfixModule): moduleType is no longer a const (MixfixModule::isObjectOriented): added member function * ooTransform.cc (SyntacticPreModule::transformStatements): respect ixfixParser::DNT_FLAG * mixfixParser.cc (MixfixParser::makeStatementPart): place DNT_FLAG in statement if DNT set * mixfixParser.hh (class MixfixParser): added static constexpr DNT_FLAG * lexer.ll (id): remove classes from list of keywords detected as ending current statement * mixfixParser.cc (MixfixParser::makeAttributePart): handle dnt attribute * mixfixParser.hh (class MixfixParser): added MAKE_DNT_ATTRIBUTE to enum SemanticActions (class MixfixParser): added DNT to enum Flags * makeGrammar.cc (MixfixModule::makeAttributeProductions): added dnt attribute * specialTokens.cc: added dnt 2023-01-25 Steven Eker * ooTransform.cc (SyntacticPreModule::classComplete): added * syntacticPreModule.hh (class SyntacticPreModule): deleted data member ignore from struct ObjectInfo (class SyntacticPreModule): added classNames data member * ooTransform.cc (SyntacticPreModule::gatherObjects): count the number of occurrences of each variable * syntacticPreModule.hh (class SyntacticPreModule): added decl for chooseFreshVariableName() (class SyntacticPreModule): added typedef VarCountMap (class SyntacticPreModule): added data member varCountMap to struct StatementInfo * ooTransform.cc (SyntacticPreModule::StatementInfo::chooseFreshVariableName): added 2023-01-24 Steven Eker * ooTransform.cc (SyntacticPreModule::gatherObjects): accumulate forbiddenNames * syntacticPreModule.hh (class SyntacticPreModule): added struct StatementInfo (SyntacticPreModule::StatementInfo::~StatementInfo): added (class SyntacticPreModule): added typedef IdSet; added forbiddenNames data member to StatementInfo * process.cc (SyntacticPreModule::process): use transformStatements() * ooTransform.cc: created * syntacticPreModule.hh (class SyntacticPreModule): added typedef ObjectMap (class SyntacticPreModule): added decls for transformStatements(), gatherObjects() (2 versions); added enum class GatherMode * view.cc (View::checkPolymorphicOps): check that if a msg mapping is used, both the from and to polymorphic symbols have the msg attribute (View::checkOps): include line number of view in msg advisories * renaming.cc (Renaming::renameOp): deleted commented out statements (renamePolymorph): check for multiple applicable mappings 2023-01-23 Steven Eker * view.cc (View::checkOps): check that if a msg mapping is used, both the from and to symbols have the msg attribute * renaming.hh (Renaming::isMsgMapping): added * syntacticView.cc (SyntacticView::handleTermAndExprMappings): track messages (SyntacticView::showView): rewrote op->term loop to handle msg->term mappings (SyntacticView::handleTermAndExprMappings): added AdvisoryCheck()s that the from and to symbols have the msg attribute if this is a msg mapping * syntacticView.hh (class SyntacticView): added typedef MessageSet and data member messages * syntacticView.cc (SyntacticView::handleTermAndExprMappings) (SyntacticView::addOpTermMapping): use OpTermMapping (SyntacticView::handleTermAndExprMappings): use range-based for loop * syntacticView.hh (class SyntacticView): added struct OpTermMapping (class SyntacticView): updated typedef OpTermList * syntacticView.cc (SyntacticView::showView): use range-based for loop (two places) * syntacticView.hh (class SyntacticView): updated decl for addOpTermMapping() * syntacticView.cc (SyntacticView::addOpTermMapping): take and store msgFlag argument * syntacticView.hh (class SyntacticView): added msg flag to struct BubblePair * modules.yy (endMsgMap): added (viewDeclaration): use endMsgMap * renaming.cc (Renaming::addOpMapping): rely on default initializer for prec (both versions) (Renaming::addAttrMapping): rely on default initializer for prec (Renaming::addOpTarget): reply on default initializers for fromTerm, toTerm (both versions) (Renaming::addOpTargetTerm): reply on default initializers for fromTerm, toTerm (Renaming::addAttrTarget): reply on default initializers for fromTerm, toTerm * modules.yy (viewDeclaration): use viewEndOpMap for msg mapping so that msg->term mapping syntax is supported (viewFromSpec): deleted 2023-01-20 Steven Eker * modules.yy (viewDeclaration): added syntax for attr mappings (viewDeclaration): added syntax for msg mappings * syntacticView.cc (SyntacticView::showView): use getNrClassMappings() to figure out how to end view * renaming.hh (Renaming::getNrClassMappings): added * modules.yy (mapping): restrict class mappings in renaming to sortName rather than token (viewDeclaration): added syntax for class mappings 2023-01-19 Steven Eker * syntacticPreModule.hh (class SyntacticPreModule): added struct ObjectInfo stub * renaming.hh (class Renaming): deleted commented out declaration for addOpMappingSimpleCopy() * renaming.cc (Renaming::canonicalizeOpMappings): check for polymorphs without the attribute being mapped by msg mappin (Renaming::addOpMappingPartialCopy): rely on default initialization of term (Renaming::addOpMapping): rely on default initialization of term (Renaming::addAttrMapping): rely on default initialization of term (Renaming::addOpMappingSimpleCopy): deleted commented out function * renaming.hh (class Renaming): added decl for polymorph version of isIdentityOpMapping() * renaming.cc (Renaming::isIdentityOpMapping): added polymorph version (Renaming::canonicalizeOpMappings): check for identity mapping on polymorphs * mixfixModule.hh (MixfixModule::getPrec): make arg const (MixfixModule::getFormat): make arg const (MixfixModule::getGather): make arg const * renaming.cc (Renaming::canonicalizeStrategyMappings): use range-based for loop (2 places); fix missing strategy name in specific advisory (Renaming::isIdentityOpMapping): added (Renaming::canonicalizeOpMappings): use isIdentityOpMapping(); rely on default initializer for term data member 2023-01-18 Steven Eker * renaming.cc (Renaming::canonicalizeOpMappings): issue advisory if generic or specific msg mapping renames an op without the msg attribute * renaming.hh (class Renaming): added decl for equal() * renaming.cc (Renaming::convertClassMappings): quietly skip identity mappings (Renaming::convertAttrMappings): quietly skip identity mappings (Renaming::pruneSortMappings): quietly skip identity mappings (Renaming::pruneLabelMappings): quietly skip identity mappings (Renaming::canonicalizeOpMappings): quietly skip identity mappings (Renaming::equal): added * renaming.hh (class Renaming): added decl for canonicalizeStrategyMappings() * renaming.cc (Renaming::canonicalizeOpMappings): restructured nested ifs to avoid spurious advisory (Renaming::canonicalizeStrategyMappings): added (Renaming::makeCanonicalVersion): use canonicalizeStrategyMappings() * modules.yy (sortToken): allow KW_FROM as a sort name/fragment 2023-01-17 Steven Eker * renaming.cc: use convertAttrMappings() * renaming.hh (class Renaming): added decl for convertAttrMappings() * renaming.cc (convertAttrMappings): added * mixfixModule.hh (class MixfixModule): added decls for findFirstUnarySymbol(), findNextUnarySymbol() * mixfixModule.cc (MixfixModule::findFirstUnarySymbol): added (MixfixModule::findNextUnarySymbol): added * renaming.cc (Renaming::canonicalizeOpMappings): use Index, ignore attr mapppings, use range-based for loop * renaming.hh (class Renaming): added decl for canonicalizeOpMappings() * renaming.cc (Renaming::canonicalizeOpMappings): added (Renaming::makeCanonicalVersion): use canonicalizeOpMappings() * renaming.hh (class Renaming): added decls for convertClassMappings(), pruneSortMappings() * renaming.cc (Renaming::makeCanonicalVersion): check and convert class mappings (Renaming::convertClassMappings): added (Renaming::makeCanonicalVersion): use convertClassMappings() (Renaming::convertClassMappings): make sure sorts are in the same component before we compare them (Renaming::pruneSortMappings): added; changed Assert() to AdvisoryCheck() for the duplicate case (Renaming::pruneLabelMappings): added (Renaming::makeCanonicalVersion): use pruneSortMappings(), pruneLabelMappings() * renaming.hh (class Renaming): provide default initializers for fromTerm and term in struct OpMapping (class Renaming): provide default initializer OpMapping::prec * importModule.hh (class ImportModule): added decl for findClassIdSort() * ooSorts.cc (SyntacticPreModule::findClassIdSort): added * renaming.cc (Renaming::addSortAndLabelMappings): use range-based for loop (2 places) (Renaming::makeCanonicalVersion): use range-based for loop (2 places) * importModule.hh (class ImportModule): added decl for findAtttributeSort() * ooSorts.cc: created 2023-01-13 Steven Eker * renaming.cc (Renaming::printRenaming): print msg and attr mappings * top.yy: moved KW_ATTR to start keywords block * modules.yy (startKeyword2): moved KW_ATTR from inert to startKeyword2 * renaming.hh (Renaming::markAsMsg): added * modules.yy (mapping): added syntax for msg mappings * renaming.cc (Renaming::printRenamingType): use range-based for loop (Renaming::setFormat): use range-based for loop (Renaming::setGather): use range-based for loop (Renaming::addType): (const Vector& tokens version) use range-based for loop (Renaming::setType): added comment to explain why we need to add all sorts to the type and not just the maximal ones. (Renaming::makeTypeName): use range-base for loop (Renaming::makeCanonicalName): use range-base for loop (4 places) * syntacticView.cc (SyntacticView::addParameter2): removed commented out IssueAdvisory() * renaming.cc (Renaming::printRenaming): print classMap; use range-based for loop to print sortMap, opMap, labelMap * renaming.hh (class Renaming): added struct ClassMapping; typedef ClassMap and data member classMap; (Renaming::addClassMapping): added * modules.yy (mapping): added class mapping syntax 2023-01-12 Steven Eker * lexer.ll: added attr as a keyword for scanning modules * top.yy: declare KW_ATTR * modules.yy (inert): added KW_ATTR * renaming.hh (class Renaming): deleted decl for setOpMsgFlag(); added decls for addAttrMapping() and addAttrTarget() * renaming.cc (Renaming::setOpMsgFlag): deleted (Renaming::addAttrMapping): added (Renaming::addAttrTarget): added * modules.yy (fromAttrSpec): added (mapping): removed opOrMsg; added attr mapping * top.yy: deleted opOrMsg * modules.yy (opOrMsg): deleted * renaming.hh (class Renaming): replaced msgFlag with MappingType; added enum class MappingType 2023-01-11 Steven Eker * top.yy: added opOrMsg to nonterminals that return yyBool * modules.yy (opOrMsg): added (mapping): use opOrMsg and call setOpMsgFlag() * renaming.hh (class Renaming): added decl for setOpMsgFlag() * renaming.cc (Renaming::setOpMsgFlag): added * renaming.hh (class Renaming): added data member msgFlag to struct OpMapping * syntacticPreModule.hh (class SyntacticPreModule): processClassSorts() -> processClassTypes(); added decl for computeAttributeTypes() * process.cc (SyntacticPreModule::process): call processAttributeTypes() * ooProcess.cc (SyntacticPreModule::computeAttributeTypes): added (SyntacticPreModule::processClassOps): use sort data member (SyntacticPreModule::checkAttributeTypes): use checkType() * process.cc (SyntacticPreModule::process): call checkAttributeTypes() rather than checkAttributeSorts() * syntacticPreModule.cc (SyntacticPreModule::addAttributePair): pass initializer for sort data member * syntacticPreModule.hh (class SyntacticPreModule): added sort data member to struct AttributePair * ooProcess.cc (SyntacticPreModule::checkAttributeSorts): becomes checkAttributesTypes() * modules.yy (cPair): pass kind flag to addAttributePair() * syntacticPreModule.hh (class SyntacticPreModule): struct AttributePair now has a Type * ooProcess.cc (SyntacticPreModule::checkAttributeSorts): use type (SyntacticPreModule::processClassOps): use type * syntacticPreModule.hh (class SyntacticPreModule): updated decl for addAttributePair() * syntacticPreModule.cc (SyntacticPreModule::addAttributePair): take kind flag * command.cc (SyntacticPreModule::showModule): use type rather than sortName * ooProcess.cc (SyntacticPreModule::processClassOps): use attribute typeName (SyntacticPreModule::checkAttributeSorts): moved here; use typeName * syntacticPreModule.hh (class SyntacticPreModule): updated decl for addAttributePair() (class SyntacticPreModule): updated struct AttributePair * syntacticPreModule.cc (SyntacticPreModule::addAttributePair): take typeName rather than sortName * modules.yy (cPair): use typeName1 * top.yy: added typeName1 to nonterminals that return yyBool * modules.yy (typeName1): added 2023-01-10 Steven Eker * process.cc (SyntacticPreModule::processImports): don't check for theories when handling autoImports since in the theory case this will be empty following the change below * syntacticPreModule.cc (SyntacticPreModule::finishModule): don't copy autoImports for theories; we tried this before and it seemed to break strategies, but in fact it fixes a bug in all theories at the metalevel, and the old test output was bad * process.cc (SyntacticPreModule::checkType): use range-based for loop (SyntacticPreModule::checkOpTypes): use range-based for loop (SyntacticPreModule::computeOpTypes): use range-based for loop (SyntacticPreModule::processOps): use range-based for loop (SyntacticPreModule::computeType): use Index (SyntacticPreModule::processStatements): use range-based for loop * command.cc (SyntacticPreModule::printAttributes): don't print ctor in msg statement * ops.cc (SyntacticPreModule::endMsg): messages are automatically ctors * ooProcess.cc (SyntacticPreModule::addHonoraryClassNames) (SyntacticPreModule::findClassIdSortName) (SyntacticPreModule::findAtttributeSetSort) (SyntacticPreModule::findAtttributeSort) (SyntacticPreModule::processClassSorts) (SyntacticPreModule::processClassOps): moved here * process.cc (SyntacticPreModule::processSubsorts): major simplification now that surface parser enforces good syntax for subsort declarations (SyntacticPreModule::processClassSorts): simplify subclass processing now that surface parser enforces good syntax for subclass declaration * syntacticPreModule.hh (SyntacticPreModule::addSortDecl): don't check for empty sortDecl since surface syntax no longer allows this * modules.yy (sortNameList): make nonempty (subsortList): enforce sortName+ < sortName+ (< sortName)* * syntacticPreModule.hh (class SyntacticPreModule): added decl for processSubsorts() * process.cc (SyntacticPreModule::insertSubsorts): switch nesting since smaller is more likely to be empty (SyntacticPreModule::processSubsorts): reimplemented subsort code and moved it here 2023-01-09 Steven Eker * process.cc (SyntacticPreModule::processClassSorts): don't create class sort for class names that contain an underscore (SyntacticPreModule::processClassOps): don't process classes whose name contains an underscore; don't add ops for attributes whose name contains an underscrore (SyntacticPreModule::processSorts): use range based loop (2 places) * token.hh (Token::containsUnderscore): added * makeGrammar.cc (MixfixModule::makeSymbolProductions): only make empty attribute set production if attributeSetSymbol has correct attributes * mixfixParser.cc (MixfixParser::makeTerm): don't allow empty attribute set syntax in operator declarations and create a fake term in the case it occurs 2023-01-06 Steven Eker * ops.cc (SyntacticPreModule::endMsg): remove bad msg(s) from opDefs and opDecls (SyntacticPreModule::setMetadata): deleted commented out setting of flag SymbolType::METADATA since this flag no longer exists * modules.yy (declaration): call endMsg() at the end of a msg or msgs declaration * syntacticPreModule.hh (class SyntacticPreModule): added decl for endMsg() * ops.cc (SyntacticPreModule::endMsg): added 2023-01-05 Steven Eker * syntacticPreModule.cc (SyntacticPreModule::addClassDecl): moved here (SyntacticPreModule::addAttributePair): moved here (SyntacticPreModule::addClassDecl): only allow class declaration in omod or oth (SyntacticPreModule::addAttributePair): ignore attribute pair unless we are an omod or an oth (SyntacticPreModule::addSubclassDecl): moved here; only allow subclass declaration in omod or oth * command.cc (SyntacticPreModule::showModule): use Token::sortName() for printing class names and attribute sorts * modules.yy (cPair): use sortName rather than token for attribute sorts (declaration): use sortName rather than token for class names * makeGrammar.cc (MixfixModule::makeSymbolProductions): added production for AKE_OBJECT_WITH_EMPTY_ATTRIBUTE_SET for ObjectConstructorSymbol symbols * mixfixParser.cc (MixfixParser::makeTerm): handle MAKE_OBJECT_WITH_EMPTY_ATTRIBUTE_SET case * objectConstructorSymbol.hh (ObjectConstructorSymbol::getAttributeSetSymbol): added * mixfixParser.hh (class MixfixParser): added MAKE_OBJECT_WITH_EMPTY_ATTRIBUTE_SET to semantic actions * process.cc (SyntacticPreModule::addHonoraryClassNames): only look at system modules and theories; require that sort have a constant of the same name with a single decl that is a ctor * mixfixModule.hh (MixfixModule::isSystem): added static and non-static versions * banner.cc (printBanner): update year 2023-01-04 Steven Eker * process.cc (SyntacticPreModule::processClassOps): use findAtttributeSort(); insert attribute operators (SyntacticPreModule::processClassOps): use gather (&) for attribute operators; use ctor for class and attribute operators (SyntacticPreModule::checkAttributeSorts): added (SyntacticPreModule::findClassIdSortName): only consider ops with ctor attribute (SyntacticPreModule::findAtttributeSetSort): only consider ops with ctor attribute (SyntacticPreModule::addHonoraryClassNames): added (SyntacticPreModule::processClassSorts): use addHonoraryClassNames * syntacticPreModule.hh (class SyntacticPreModule): added decl for findAtttributeSort() * process.cc (SyntacticPreModule::processClassSorts): use classIdSort data member (SyntacticPreModule::processClassOps): use attributeSetSort data member (SyntacticPreModule::findAtttributeSort): added * syntacticPreModule.hh (class SyntacticPreModule): added data members classIdSort, attributeSetSort, attributeSort * process.cc (SyntacticPreModule::processClassSorts): use new findClassIdSortName() convention * syntacticPreModule.hh (class SyntacticPreModule): updated decl for findClassIdSortName() * process.cc (SyntacticPreModule::findClassIdSortName): return sort rather than name code 2023-01-03 Steven Eker * mixfix.hh: added class ObjectConstructorSymbol * process.cc (SyntacticPreModule::findClassIdSortName): made const (SyntacticPreModule::processClassOps): call findAtttributeSetSort() * syntacticPreModule.hh (class SyntacticPreModule): updated decl for findClassIdSortName() * process.cc (SyntacticPreModule::processClassSorts): mark module as bad if we can't find the Cid sort (SyntacticPreModule::findClassIdSortName): only consider symbols with the ObjectConstructorSymbol id-hook (SyntacticPreModule::findAtttributeSetSort): added * fancySymbols.cc (MixfixModule::newFancySymbol): added ObjectConstructorSymbol * specialSymbolTypes.cc: added ObjectConstructorSymbol * objectConstructorSymbol.cc: created * objectConstructorSymbol.hh: created * symbolType.hh (class SymbolType): added OBJECT_CONSTRUCTOR_SYMBOL to enum BasicTypes 2022-12-23 Steven Eker * syntacticPreModule.hh (class SyntacticPreModule): added decl for processClassOps() * process.cc (SyntacticPreModule::processClassOps): added * syntacticPreModule.hh (class SyntacticPreModule): added data member classSymbol to struct ClassDecl * process.cc (SyntacticPreModule::process): use processClassOps() * syntacticPreModule.hh (class SyntacticPreModule): added data member classSort to struct ClassDecl * process.cc (SyntacticPreModule::processClassSorts): handle subclasses (SyntacticPreModule::insertSubsorts): added (SyntacticPreModule::processClassSorts): use insertSubsorts() (SyntacticPreModule::processClassSorts): save sort for each class * syntacticPreModule.hh (class SyntacticPreModule): added decl for processClassSorts() * process.cc (SyntacticPreModule::process): use findClassIdSortName(); try to add subsorts for class names (SyntacticPreModule::processClassSorts): added (SyntacticPreModule::process): use processClassSorts() * syntacticPreModule.hh (class SyntacticPreModule): added decl for findClassIdSortName() * process.cc (SyntacticPreModule::findClassIdSortName): added * mixfixModule.hh (getObjectSymbols): added 2022-12-22 Steven Eker * process.cc (SyntacticPreModule::processOps): clear SymbolType::MSG_STATEMENT before passing symbolType to flatModule ===================================Maude139=========================================== * lexer.ll: %option noyy_top_state * deserializer.ll: option noinput * tokenizer.ll: option noinput * deserializer.ll: %option nounput * tokenizer.ll: %option nounput * lexer.ll: %option nounput * top.yy: fix decl for yyerror() * bottom.yy (yyerror): make second argument const 2022-12-21 Steven Eker * userLevelRewritingContext.hh (class UserLevelRewritingContext): added OUT_OF_MEMORY to enum ExitCodes * interact.cc (UserLevelRewritingContext::setHandlers): malloc() rather than statically allocate alt stack, because SIGSTKSZ may not be known at compile time 2022-12-16 Steven Eker * syntacticPreModule.hh (SyntacticPreModule::addAttributePair): removed commented out code * syntaxContainer.cc (operator<<): fix bug where first token in kind was printed directly rather than with Token::sortName() * command.cc (SyntacticPreModule::printAttributes): use range-based for loop rather than FOR_EACH_CONST() 2022-12-15 Steven Eker * process.cc (SyntacticPreModule::process): convert omods to mods and oths to ths 2022-12-14 Steven Eker * command.cc (SyntacticPreModule::showModule): print classDecls (SyntacticPreModule::showModule): print subclassDecls * modules.yy (declaration): use addClassDecl() (cPair): use addAttributePair() * syntacticPreModule.hh (class SyntacticPreModule): added structs AttributePair and ClassDecl; added data member classDecls (SyntacticPreModule::addClassDecl): added (SyntacticPreModule::addAttributePair): added 2022-12-13 Steven Eker * command.cc (SyntacticPreModule::showModule): handle SymbolType::MSG_STATEMENT (SyntacticPreModule::printAttributes): handle SymbolType::MSG_STATEMENT * modules.yy (declaration): set SymbolType::MSG_STATEMENT for operators that get their SymbolType::MESSAGE flag from a msg or msgs statement rather than an attribute * symbolType.hh (class SymbolType): added MSG_STATEMENT to enum Flags * modules.yy (classDef): allow class C . rather than class C | . 2022-12-08 Steven Eker * viewCache.cc (ViewCache::makeViewInstantiation): DebugAlways() -> DebugInfo() (2 places) (ViewCache::showCreatedViews): DebugAlways() -> DebugInfo() * visibleModule.cc: DebugAlways() -> DebugInfo() * viewCache.cc (ViewCache::makeViewInstantiation): get the actual characters of cleanName from Token; fixes a longstanding bug where views that were instantiated twice got a bad cleanName * moduleCache.cc (ModuleCache::showCreatedModules): use range-based for loop * viewCache.cc (ViewCache::showCreatedViews): use range-based for loop 2022-12-07 Steven Eker * viewCache.cc: added DebugAlways() so I can see the internal name of instantiated view (ViewCache::makeViewInstantiation): added DebugAlways()s so I can see the name and clean name being built (ViewCache::makeViewInstantiation): start cleanName from view->getCleanName() * visibleModule.cc: added DebugAlway()s so I can see the internal name of each sort ===================================Maude138=========================================== 2022-02-21 Steven Eker * banner.cc (printBanner): tweak spacing ===================================Maude137b=========================================== 2022-01-25 Steven Eker * banner.cc (printBanner): updated copyright year 2021-10-01 Steven Eker * loopMode.cc (Interpreter::contLoop2): fix bug where we were not checking that savedState was actually a CacheableRewritingContext 2021-09-09 Steven Eker * yices2_Bindings.cc (VariableGenerator::assertDag): fix bug where we were calling yices_assert_formula(smtContext, t) twice 2021-07-20 Steven Eker * process.cc (SyntacticPreModule::processImports): removed unnecessary if statement * syntacticPreModule.cc (SyntacticPreModule::finishModule): make deep copies for autoImports and ooIncludes conditional (SyntacticPreModule::finishModule): reverted change for autoImports because it is breaking strategies * syntacticPreModule.hh (class SyntacticPreModule): added data member ooIncludes * syntacticPreModule.cc (SyntacticPreModule::finishModule): copy object-oriented includes * process.cc (SyntacticPreModule::processImports): handle default object-oriented includes * mixfixModule.hh (MixfixModule::isObjectOriented): added * moduleDatabase.hh (class ModuleDatabase): setOmodInclude() -> setOoInclude() * commands.yy: use setOoInclude() * moduleDatabase.cc (ModuleDatabase::setOmodInclude): becomes setOoInclude(); use defaultOpIncludes * moduleDatabase.hh (getOmodIncludes): becomes getOoIncludes(); use defaultOoIncludes (class ModuleDatabase): data member defaultOmodIncludes becomes defaultOoIncludes * process.cc (SyntacticPreModule::processImports): use range-based for loop instead of FOR_EACH_CONST * syntacticPreModule.cc (SyntacticPreModule::compatible): added oth/endoth * specialTokens.cc: added oth and endoth * syntacticPreModule.cc (SyntacticPreModule::SyntacticPreModule): support OBJECT_ORIENTED_THEORY, OBJECT_ORIENTED_MODULE * top.yy: delete startModule * modules.yy (startModule): deleted (module): use KW_MOD rather than startModule * top.yy: KW_OMOD changed to KW_OO * commands.yy: use KW_OO rather than KW_OMOD * lexer.ll: make omod return KW_MOD and add oo 2021-07-19 Steven Eker * lexer.ll (id): recognise oth and endoth * mixfixModule.cc (MixfixModule::moduleTypeString): handle oth and omod (MixfixModule::moduleEndString): handle endoth and endom * mixfixModule.hh (class MixfixModule): added OBJECT_ORIENTED to enum Bits, and OBJECT_ORIENTED_MODULE, OBJECT_ORIENTED_THEORY to enum ModuleType * lexer.ll: added comment to explain why omod is separated out 2021-07-16 Steven Eker * command.cc (SyntacticPreModule::showModule): use importModeString() * mixfixModule.cc (MixfixModule::moduleTypeString): made typeStrings const (MixfixModule::moduleEndString): made typeStrings const * visibleModule.cc: use importModeString() and getImportMode() * importModule.hh (class ImportModule): added decl for importModeString() * importModule.cc (ImportModule::importModeString): added * importModule.hh (class ImportModule): added data member importModes (ImportModule::getImportMode): added * importModule.cc (ImportModule::addImport): set mode to INCLUDING for theories imported by other modes; store imporation mode * visibleModule.hh (class VisibleModule): added decl for showImports() * visibleModule.cc: added * importModule.hh (ImportModule::getNrImports): added (ImportModule::getImportedModule): added 2021-07-15 Steven Eker * commands.yy (command): added show desugared . * top.yy: added KW_DESUGARED * lexer.ll: added desuguared to INITIAL 2021-06-29 Steven Eker * modules.yy (declaration): use addSubclassDecl() * syntacticPreModule.hh (class SyntacticPreModule): added data member subclassDecls (SyntacticPreModule::addSubclassDecl): added ===================================Maude137=========================================== 2021-04-27 Steven Eker * specialSymbolTypes.cc: added DirectoryManagerSymbol * symbolType.hh (class SymbolType): added STREAM_MANAGER_SYMBOL to enum BasicTypes * fancySymbols.cc (MixfixModule::newFancySymbol): handle case DIRECTORY_MANAGER_SYMBOL ===================================Maude136=========================================== 2021-03-24 Steven Eker * interact.cc (UserLevelRewritingContext::interruptSeen): added * userLevelRewritingContext.hh (class UserLevelRewritingContext): added decl for interruptSeen() 2021-03-10 Steven Eker * global.hh: added decl for setDebugMode() * interact.cc (UserLevelRewritingContext::changePrompt): call setDebugMode() * commands.yy: handle KW_IMPLIED_STEP * top.yy: added KW_IMPLIED_STEP * lexer.ll: handle implied step commands * lexerAux.hh: added decl for generateImpliedStep() * lexerAux.cc: added variable debugMode (setDebugMode): added (generateImpliedStep): added 2021-03-09 Steven Eker * userLevelRewritingContext.hh (class UserLevelRewritingContext): added static data member timeAtLastInterrupt * interact.cc (UserLevelRewritingContext::handleInterrupt): check for two interrupts happening in the space of a second ===================================Maude135=========================================== 2021-03-01 Steven Eker * symbolType.hh (class SymbolType): added TIME_MANAGER_SYMBOL * fancySymbols.cc (MixfixModule::newFancySymbol): handle TimeManagerSymbol * specialSymbolTypes.cc: added TimeManagerSymbol ===================================Maude134=========================================== 2021-02-19 Steven Eker * unify.cc (Interpreter::unify): pass destructiveUpdates = true to UnificationProblem() (Interpreter::unify): unmade previoius change now that we're doing away with destructive updates because they don't normalize bindings 2021-02-10 Steven Eker * top.yy: replaced %pure-parser with %define api.pure 2021-02-09 Steven Eker * Makefile.am (surface.h): now depends on surface.cc rather than surface.yy in order that parallel builds don't run bison twice 2021-02-03 Steven Eker * unify.cc (Interpreter::unify): fix bug where we were not echoing irredundant prefix 2021-01-04 Rubén Rubio * instantiateViewWithFreeParameters.cc (View::handleStratMappings): fixed some bugs, getOpTo was used instead of getStratTo, etc. * parameterization.cc (addStratMappingsFromView): use range-based for loop ===================================Maude133=========================================== 2020-12-10 Steven Eker * top.yy: optOptions, optionsList, option now have type yyInt64 * commands.yy (optOptions, optionsList, option): pass flag(s) back via $$ rather than variantOptions variable * search.cc (Interpreter::checkSearchRestrictions): deleted VU_NARROW_WITH_FILTERED_VU, FVU_NARROW_WITH_FILTERED_VU cases (Interpreter::search): deleted VU_NARROW_WITH_FILTERED_VU, FVU_NARROW_WITH_FILTERED_VU cases * interpreter.hh (class Interpreter): deleted VU_NARROW_WITH_FILTERED_VU and FVU_NARROW_WITH_FILTERED_VU from enum SearchKind * commands.yy (search): delete filtered vu-narrow and filtered fvu-narrow commands * top.yy: added KW_FOLD * commands.yy (command): use optOptions for vu-narrow * lexer.ll: added KW_FOLD * commands.yy (optOptions, optionsList, option): added * lexer.ll: return { } in INTIAL mode 2020-12-09 Steven Eker * search.cc (Interpreter::search): take variantFlags argument; handle printing of variantFlags * interpreter.hh (class Interpreter): updated decl for search() * commands.yy (command): pass variantOptions to search() * top.yy: added type decl for cTokenBarDotOptionToken * commands.yy (cTokenBarDotOptionToken): added (optionsNumbersModuleTerm1): use cTokenBarDotOptionToken * top.yy: added variable variantOptions * commands.yy (optionsNumbersModuleTerm2): handle , (optionsNumbersModuleTerm1): hande cOptionsToken * top.yy: added type for cOptionToken * commands.yy (cOptionToken): added; use whereever IDENTIFIER is used * top.yy: added KW_FILTER and KW_DELAY * lexer.ll: added filter and delay to CMD_MODE * commands.yy (search): remove VU_NARROW (command): addd VU_NARROW as a separate command (command): use optionsNumbersModuleTerm for VU_NARROW * top.yy: added types for cTokenBarOpenLeftIn, cTokenBarDotCommaClose * commands.yy: added '{' | '}' to all existing cToken nonterminals (cTokenBarOpenLeftIn): added (cTokenBarDotCommaClose): added * lexer.ll: return { and } as characters rather than identifiers in CMD_MODE 2020-12-08 Steven Eker * userLevelRewritingContext.hh (class UserLevelRewritingContext): added SOCKET_CLOSED to enum ExitCodes 2020-12-04 Steven Eker * deserializer.ll: allow null Qid 2020-12-03 Steven Eker * commands.yy (search): support support VU_NARROW_WITH_FILTERED_VU and FVU_NARROW_WITH_FILTERED_VU * search.cc (Interpreter::checkSearchRestrictions) (Interpreter::search): support VU_NARROW_WITH_FILTERED_VU and FVU_NARROW_WITH_FILTERED_VU * interpreter.hh (class Interpreter): added VU_NARROW_WITH_FILTERED_VU and FVU_NARROW_WITH_FILTERED_VU to enum SearchKind * search.cc (Interpreter::search): put variantFlags in an explicit variable 2020-12-02 Steven Eker * userLevelRewritingContext.hh (class UserLevelRewritingContext): added decl for ignoreCtrlC() * interact.cc (UserLevelRewritingContext::internalErrorHandler): exit with INTERNAL_ERROR (UserLevelRewritingContext::stackOverflowHandler): exit with STACK_OVERFLOW (UserLevelRewritingContext::commandLoop): exit with NORMAL_EXIT (UserLevelRewritingContext::ignoreCtrlC): added * userLevelRewritingContext.hh (class UserLevelRewritingContext): added enum ExitCodes 2020-11-13 Steven Eker * deserializer.ll: absorb trailing \n from previous line in INITIAL 2020-11-10 Steven Eker * mixfixModule.hh (class MixfixModule): made vists() private * serialize.cc (MixfixModule::visit): use get_str() for getting string representation of GMP integers and rationals to avoid explicit calls to free() * deserializer.ll: added decl for makeSMT_NumberDagNode() * deserializerAux.cc (makeSMT_NumberDagNode): added * deserializer.ll: recognize SMT numbers * serialize.cc (MixfixModule::visit): handle polymorph instances (MixfixModule::visit): handle SymbolType::SMT_NUMBER_SYMBOL * mixfixModule.cc (MixfixModule::createInternalTupleSymbol): set si.polymorphIndex to NONE (MixfixModule::instantiateVariable): set si.polymorphIndex to NONE (MixfixModule::instantiateSortTest): set si.polymorphIndex to NONE * entry.cc (MixfixModule::addOpDeclaration): set si.polymorphIndex to NONE (MixfixModule::addPolymorph): set polymorphIndex to our own index * mixfixModule.hh (class MixfixModule): made SymbolInfo::prec and short and added SymbolInfo::polymorphInstance 2020-11-09 Steven Eker * mixfixModule.hh (deserialize): added * deserializerAux.cc (makeDagNode): don't handle string case here anymore * deserializer.ll: added decl for makeStringDagNode(); use makeStringDagNode(); deleted static data member savedRope * deserializerAux.cc (makeDagNode): handle polymorphs (makeStringDagNode): added * deserializer.ll: added syntax for polymorphs; added static data member savedKindIndex 2020-11-06 Steven Eker * makeGrammar.cc (MixfixModule::makePolymorphProductions): use MAKE_POLYMORPH_ITER (MixfixModule::makeSymbolProductions): use gatherPrefixPrefix for the iter case * mixfixParser.cc (MixfixParser::makeTerm): added semantics for MAKE_POLYMORPH_ITER * mixfixParser.hh (class MixfixParser): added MAKE_POLYMORPH_ITER to enum SemanticActions * makeGrammar.cc (MixfixModule::makePolymorphProductions): added syntax for iter polymorphs (MixfixModule::makeGrammar): switch order of makePolymorphProductions() and makeSpecialProductions(); 2020-11-05 Steven Eker * fixUp.cc (SyntacticPreModule::fixUpSymbol): don't deal with empty identity case since this doesn't even parse at the surface syntax level. (SyntacticPreModule::fixUpSymbol): pull symbolType from flatModule because validateAttributes may have cleared some attribute flags (SyntacticPreModule::fixUpSymbol): need to check for empty identity after all, because of ditto attributes (SyntacticPreModule::fixUpPolymorph): similar check for empty identity needed * syntacticPreModule.hh (class SyntacticPreModule): added decl for fixUpSymbol() * fixUp.cc (SyntacticPreModule::fixUpSymbol): added (SyntacticPreModule::fixUpSymbols): use fixUpSymbol() * syntacticPreModule.hh (class SyntacticPreModule): added decl for fixUpPolymorph() * fixUp.cc (SyntacticPreModule::fixUpSymbols): replace check that identity exists with check of SymbolType::LEFT_ID | SymbolType::RIGHT_ID; change check for illegal polymorphic arg to an Assert() since we should have removed the offending attribute in validateAttributes() and we don't want to generatl a second warning (SyntacticPreModule::fixUpSymbols): use safeCast() as we still have an id flag, we assume we made a BinarySymbol() (SyntacticPreModule::fixUpPolymorph): added (SyntacticPreModule::fixUpSymbols): use fixUpPolymorph() to handle polymorphs * validateAttributes.cc (MixfixModule::validateAttributes): don't allow left id with left arg polymorphic or right id with right arg polymorphic because we don't have polymorphic terms and we're not going to delay the parsing of identity terms until polymorphic operator instantiation; updated comments 2020-11-03 Steven Eker * mixfixModule.hh (class MixfixModule): updated decls for newAssociativeSymbol(), newAxiomSymbol() * fancySymbols.cc (MixfixModule::newFancySymbol): use newAxiomSymbol() (MixfixModule::newAssociativeSymbol): take int rather than Token for name (MixfixModule::newAxiomSymbol): take int rather than Token for name (MixfixModule::newFancySymbol): new newAssociativeSymbol(), newAxiomSymbol() calling conventions; reorganize if statements * mixfixModule.hh (class MixfixModule): added decl for newAxiomSymbol() * fancySymbols.cc (MixfixModule::newAxiomSymbol): added * validateAttributes.cc (MixfixModule::validateAttributes): validate left and right identity axioms * mixfixModule.hh (class MixfixModule): deleted decl for newIterSymbol() * fancySymbols.cc (MixfixModule::newFancySymbol): moved here (MixfixModule::newAssociativeSymbol): rewrite to Assert() requirements rather than warn about them not beeing satisfied (MixfixModule::newFancySymbol): don't use newIterSymbol() (MixfixModule::newIterSymbol): deleted 2020-11-02 Steven Eker * entry.cc (MixfixModule::addOpDeclaration): call validateAttributes() (MixfixModule::addPolymorph): call validateAttributes() * mixfixModule.hh (class MixfixModule): added decl for validateAttributes() * validateAttributes.cc: created 2020-10-29 Steven Eker * entry.cc (MixfixModule::newFancySymbol): use newIterSymbol() * mixfixModule.hh (class MixfixModule): added decl for newIterSymbol() * fancySymbols.cc (MixfixModule::newIterSymbol): added * mixfixModule.hh (class MixfixModule): added decl for newAssociativeSymbol() * entry.cc (MixfixModule::newFancySymbol): use newAssociativeSymbol() * fancySymbols.cc (MixfixModule::newAssociativeSymbol): code for assoc symbols from newFancySymbol() moved here; handle the case where iter flag is given as well * mixfixModule.cc (MixfixModule::instantiatePolymorph): clear SymbolType::ITER flag if newFancySymbol() fails (MixfixModule::instantiatePolymorph): use reference so actual stored flags are cleared * entry.cc (MixfixModule::addOpDeclaration): clear SymbolType::ITER flag if newFancySymbol() fails 2020-10-27 Steven Eker * mixfixParser.cc (MixfixParser::makeTerm): use makeAssocList() both for regular MAKE_TERM and MAKE_POLYMORPH * mixfixParser.hh (class MixfixParser): added decl for makeAssocList() * mixfixParser.cc (MixfixParser::makeAssocList): added * makeGrammar.cc (MixfixModule::makePolymorphProductions): support polymorphs with associative flattening for prefix syntax 2020-10-26 Steven Eker * deserializerAux.cc (makeDagNode): handle sort tests * deserializer.ll: support sort tests * serialize.cc (MixfixModule::visit): support floats; updated encoding of sort tests * deserializer.ll: support floats * deserializerAux.cc (makeFloatDagNode): added 2020-10-23 Steven Eker * deserializer.ll: handle qids * deserializerAux.cc (makeQuotedIdentifierDagNode): added * serialize.cc (MixfixModule::visit): new encoding for variables because we can't assume that the base symbol nor the name token exist in the other process * deserializerAux.cc (makeDagNode): support strings (makeVariableDagNode): added * token.hh (Token::codeToRope): moved here and implemented by call to stringToRope() (class Token): added decl for stringToRope() * token.cc (Token::stringToRope): added * deserializerAux.cc: created * deserializer.ll: support iterated function symbols 2020-10-22 Steven Eker * deserializer.ll: created 2020-10-21 Steven Eker * serialize.cc (MixfixModule::visit): added support for sort test operators 2020-10-20 Steven Eker * mixfixModule.hh (class MixfixModule): added decls for serialize(), visit() * serialize.cc: created ===================================Maude132=========================================== 2020-10-12 Steven Eker * entity.hh (class Entity): made UserLt::operator() const to fix clang warning 2020-10-09 Steven Eker * interact.cc (UserLevelRewritingContext::handleInterrupt): more detail messages ===================================Maude130a=========================================== 2020-10-05 Steven Eker * variantMatch.cc (Interpreter::variantMatch): check problemOK() before proceeding * getVariants.cc (Interpreter::getVariants): check problemOK() before proceeding * variantUnify.cc (Interpreter::variantUnify): check problemOK() before proceeding * userLevelRewritingContext.hh (class UserLevelRewritingContext): added static data member rewriteCountAtLastInterrupt * interact.cc (UserLevelRewritingContext::beginCommand): initialize rewriteCountAtLastInterrupt to -1 (UserLevelRewritingContext::handleInterrupt): two ctrl-C events without intervening rewrite to abort 2020-09-17 Steven Eker * variantMatch.cc (Interpreter::variantMatchCont): ignore debug flag and added comment to explain why we do so 2020-09-15 Steven Eker * search.cc (Interpreter::search): new calling convention for NarrowingSequenceSearch3() 2020-09-11 Steven Eker * getVariants.cc (Interpreter::doGetVariants): rewritten to use findNextVariant() and getCurrentVariant() 2020-09-10 Steven Eker * variantUnify.cc (Interpreter::variantUnify): fix memory leak and bug where we were not checking variables names by passing DELETE_FRESH_VARIABLE_GENERATOR and CHECK_VARIABLE_NAMES to FilteredVariantUnifierSearch 2020-09-09 Rubén Rubio * bufferPrint.cc (prettyPrint): fixed erratum, leftBrace was used when leftParen was required ===================================Maude130=========================================== 2020-09-08 Steven Eker * variantUnify.cc (Interpreter::variantUnify): print timing here in filtered case because all the reducing and variant narrowing is done upfront (Interpreter::doVariantUnification): computed filteredState; only print stats if !filteredState (2 places) 2020-09-04 Steven Eker * variantMatch.cc (Interpreter::doVariantMatching): added Advisory if fresh variable(s) introduced (Interpreter::variantMatch): printStats() here (Interpreter::doVariantMatching): deleted 2 calls to printStats() (Interpreter::variantMatch): addInCount() from subjectContext (Interpreter::variantMatch): subjectContext to makeVariantMatchingProblem() 2020-09-01 Steven Eker * variantUnify.cc (Interpreter::variantUnify): pass IRREDUNDANT flag to FilteredVariantUnifierSearch() in preparation for a change in semantics 2020-08-28 Steven Eker * variantUnify.cc (Interpreter::doVariantUnification): warn user about incomplete filtering and advise user of complete filtering * freshVariableSource.cc (FreshVariableSource::isFreshVariableName): added 2020-08-25 Steven Eker * variantMatch.cc (Interpreter::variantMatch): reduce subject dag before using it 2020-08-21 Steven Eker * interpreter.hh (class Interpreter): added decls for doVariantMatching(), variantMatchCont() * variantMatch.cc (Interpreter::doVariantMatching) (Interpreter::variantMatchCont): added * variantUnify.cc (Interpreter::variantUnify): fix stray space in echoing variant unify commands * variantMatch.cc (Interpreter::variantMatch): use parseVariantMatchCommand() * mixfixModule.hh (class MixfixModule): added decl for parseVariantMatchCommand() * doParse.cc (MixfixModule::parseVariantMatchCommand): added * mixfixParser.cc (MixfixParser::makeUnifyCommand): UNIFY_LIST -> PAIR_LIST * makeGrammar.cc (MixfixModule::makeComplexProductions): UNIFY_LIST -> PAIR_LIST * mixfixParser.cc (MixfixParser::makeVariantUnifyOrMatchCommand): UNIFY_LIST -> PAIR_LIST * mixfixParser.hh (class MixfixParser): UNIFY_LIST -> PAIR_LIST * doParse.cc (MixfixModule::parseVariantUnifyCommand): use makeVariantUnifyOrMatchCommand() * mixfixParser.hh (class MixfixParser): makeVariantUnifyCommand() becomes makeVariantUnifyOrMatchCommand() * mixfixParser.cc (MixfixParser::makeVariantUnifyCommand): becomes makeVariantUnifyOrMatchCommand() * makeGrammar.cc (MixfixModule::makeComplexProductions): use MAKE_TERM_LIST for irreducible case of get variants/variant unify/variant match * mixfixParser.cc (MixfixParser::makeGetVariantsCommand) (MixfixParser::makeVariantUnifyCommand): use MAKE_TERM_LIST for irreducible case * makeGrammar.cc (MixfixModule::makeComplexProductions): added two rules VARIANT_MATCH_COMMAND * mixfixModule.hh (class MixfixModule): added MULTI_MATCH_COMMAND to enum NonTerminal * makeGrammar.cc (MixfixModule::makeComplexProductions): added two ruls for MULT_MATCH_COMMAND * mixfixModule.hh (class MixfixModule): added VARIANT_MATCH_COMMAND to enum NonTerminal 2020-08-20 Steven Eker * variantMatch.cc: created * top.yy: deleted optFiltered * commands.yy (command): split variant unify into two rules and removed optFiltered to avoid a shift/reduce conflict * interpreter.hh (class Interpreter): added decl for variantMatch() * mixfixModule.hh (class MixfixModule): added decl for makeMatchProblemDags() * mixfixModule.cc (MixfixModule::makeMatchProblemDags): added * commands.yy (command): added variant match 2020-08-06 Steven Eker * variantUnify.cc (Interpreter::variantUnify): create timer before creating FilteredVariantUnifierSearch object because the latter does almost all of its work at creation * commands.yy (command): use filtered rather than irredundant for variant unify because we may not generate irredundant unifiers (command): removed the duplicated coded need to fix the shift/reduce conflict now that we are using filtered rather than irredundant * top.yy: added optFiltered * commands.yy (optFiltered): added * top.yy: added KW_FILTERED * lexer.ll: added KW_FILTERED 2020-08-05 Steven Eker * variantUnify.cc (Interpreter::variantUnify): use FilteredVariantUnifierSearch() 2020-08-04 Steven Eker * variantUnify.cc (Interpreter::doVariantUnification): rewritten to use findNextUnifier(), getCurrentUnifier() rather than getNextUnifier() 2020-07-24 Steven Eker * mixfixModule.cc (MixfixModule::createInternalTupleSymbol): use range-based for loop 2020-07-22 Steven Eker * variantUnify.cc (Interpreter::variantUnify): use new VariantSearch calling conventions * getVariants.cc (Interpreter::getVariants): use new VariantSearch calling conventions 2020-07-17 Steven Eker * commands.yy (command): separate dubug variant unify rule to resolve a shift reduce conflict - when parser sees irredundant it doesn't know whether it is about to see regular unification or whether is should do an empty reduce for optDebug in preparation for variant unification 2020-07-16 Steven Eker * lexer.ll: add irred as an abbreviation for irredundant * interpreter.hh (class Interpreter): updated decl for variantUnify() * variantUnify.cc (Interpreter::variantUnify): take irredundant flag (Interpreter::variantUnify): pass irredundant flag to VariantSearch() to see why this isn't good enough * commands.yy (command): added optIrredundant to variant unify 2020-07-15 Steven Eker * variantUnify.cc (Interpreter::doVariantUnification): Unifier #n -> Unifier n * getVariants.cc (Interpreter::doGetVariants): Variant #n -> Variant n * unify.cc (Interpreter::doUnification): Solution n -> Unifier n * match.cc (Interpreter::doMatching): Solution n -> Matcher n 2020-07-10 Steven Eker * interpreter.hh (class Interpreter): updated decl for unify() * commands.yy (command): allow irredundant prefix; pass flag to Intepreter::Unify() * unify.cc (Interpreter::unify): take irredundant and use IrredundantUnificationProblem ===================================Maude129=========================================== 2020-06-09 Steven Eker * renameModule.cc (ImportModule::donateOps2): DebugNew() -> DebugOld() (2 places) 2020-05-28 Steven Eker * mixfixModule.cc (MixfixModule::nonTerminal): comment out DebugInfo() because it producing voluminous output 2020-05-05 Steven Eker * interact.cc (UserLevelRewritingContext::setHandlers): ignore SIGPIPE 2020-04-14 Steven Eker * userLevelRewritingContext.hh (class UserLevelRewritingContext): added decl for blockAndHandleInterrupts() 2020-04-08 Steven Eker * makeGrammar.cc (MixfixModule::makeParameterizedSortProductions): use MixfixParser::newNonTerminal() (MixfixModule::makeSymbolProductions): use MixfixParser::newNonTerminal() * mixfixModule.hh (class MixfixModule): deleted decl for newNonTerminal() * mixfixModule.cc (MixfixModule::newNonTerminal): deleted * mixfixParser.hh (MixfixParser::newNonTerminal): added * doParse.cc (MixfixModule::getParserStats): use getNrTerminals(), getNrNonTerminals() * mixfixParser.hh (MixfixParser::getComponentNonTerminalBase): added (MixfixParser::getNrNonTerminals) added (MixfixParser::getNrTerminals) added * mixfixModule.cc (MixfixModule::nonTerminal): use getComponentNonTerminalBase() * mixfixModule.hh (class MixfixModule): deleted data members complexParser, componentNonTerminalBase, nextNonTerminal * makeGrammar.cc (MixfixModule::makeComponentProductions): use isComplex() (MixfixModule::makeGrammar): use isComplex() * mixfixParser.hh (class MixfixParser): updated decl for MixfixParser() (MixfixParser::isComplex): added (MixfixParser::getNrProductions): made const * mixfixParser.cc (MixfixParser::MixfixParser): take complexFlag, componentNonTerminalBase, nextNonTerminalCode * mixfixParser.hh (class MixfixParser): added data members complexParser, componentNonTerminalBase, nextNonTerminal * makeGrammar.cc (MixfixModule::makeGrammar): pass complexFlag, componentNonTerminalBase and nextNonTerminal to MixfixParser() rather than storing them locally. * mixfixModule.hh (class MixfixModule): added comment about transitory nature of iterSymbols, leadTokens * mixfixParser.cc (MixfixParser): added for debugging purposes * mixfixParser.hh (class MixfixParser): added decl for ~MixfixParser() 2020-04-07 Steven Eker * mixfixModule.cc (MixfixModule::economize): change to DebugInfo() * makeGrammar.cc (MixfixModule::makeGrammar): added DebugInfo()s * mixfixModule.cc (MixfixModule::economize): added DebugAdvisory() (MixfixModule::nonTerminal): added DebugAdvisory() * doParse.cc (MixfixModule::parseStatement): changed local variable from complexParser to complexFlag to avoid confusion with object member 2020-03-31 Steven Eker * symbolType.hh (class SymbolType): added PROCESS_MANAGER_SYMBOL * entry.cc (MixfixModule::newFancySymbol): add ProcessMangagerSymbol * specialSymbolTypes.cc: added ProcessMangagerSymbol 2020-03-10 Rubén Rubio * mixfixModule.cc (donateStatements2): copy nonexec attribute * mixfixParser.cc (makeStatementPart): handle nonexec attribute ===================================Maude128a=========================================== 2020-02-19 Steven Eker * variantUnify.cc (doVariantUnification): test for interrupted before checking for no result * unify.cc (doUnification): test for interrupted before checking for no result * interact.cc (infoHandler): added comments; deleted commented out code (interruptHandler): added comments * userLevelRewritingContext.hh (ObjectSystemRewritingContext): commented out declaration for clearInterrupt() * interact.cc (clearInterrupt): commented out * userLevelRewritingContext.cc (tracePreEqRewrite): added comments to explain what situations are handled * interact.cc (handleInterrupt): move comment to head of function and deleted commented out code * match.cc (doMatching): rearrange statements so that we abort before trying to print a matcher * unify.cc (doUnification): added comment to explain rearranged statement order 2020-02-18 Steven Eker * unify.cc (doUnification): check for ^C interrupt before printing solution number to avoid garbage solutions being printed 2020-02-13 Steven Eker * syntacticPreModule.cc (getFlatModule): rewritten; we no longer expect importStatements() to be able to set the bad flag * importModule.cc (resetImportPhase): use range-based for loop; deleted commented out call to resetImports() (dumpImports): use range-based for loops (deepSelfDestruct): range-based for loops * syntacticPreModule.cc (getFlatModule): added comment to explain checkFreshVariableNames(); deleted commented out IssueWarning()s 2020-02-12 Steven Eker * interpreter.cc (setCurrentModule): updated comment (makeModule): deleted commented out IssueAdvisory() for renaming of modules with bound parameters since it will never be a cause for concern as prelude makes heavy use of this feature; updated comment 2020-02-11 Steven Eker * interpreter.cc (~Interpreter): updated comment * viewDatabase.cc (~ViewDatabase): updated comment * moduleCache.cc (~ModuleCache): moved here * viewCache.hh (User): added decl for ~ViewCache() * viewCache.cc (ViewCache): added * moduleCache.hh (~ModuleCache): added 2020-02-07 Steven Eker * commands.yy (command): allow module name in do clear memo and make use of setCurrentModule() to check validity of the module * interpreter.cc (setCurrentModule): code cleaning; added comments (parse): fixed comment 2020-02-05 Steven Eker * syntacticPreModule.cc (getFlatModule): partially fix bug where we importStatements() into a bad module (moves breakage elsewhere) 2020-02-04 Steven Eker * importModule.cc (importStatements, donateStatements): added DebugEnter() * process.cc (process): do closeSortSet() early in the hope of unifying common code (checkOpTypes): added comment to explain what it does (checkType): added comment to explain what it does (getSort): added comment to explain what it does * preModule.cc (processExplicitImports): added comments to explain why we don't bail on first error * process.cc (processImports): added comment to explain why we don't bail on first error ===================================Maude128=========================================== 2019-12-16 Steven Eker * auxProperty.cc: added missing copyright notice ===================================Maude127a=========================================== 2019-12-05 Steven Eker * compiler.cc (runExecutable): use returnValueDump to avoid unused result warning in GCC * interact.cc (internalErrorHandler): use returnValueDump to avoid unused result warning in GCC (3 places) (stackOverflowHandler): ditto * top.yy (directive): use returnValueDump rather than (void) to avoid GCC's unused result warning (2 places) * lexer.ll: added KW_LL * top.yy: added KW_LL; semantics for KW_LL 2019-12-04 Steven Eker * yices2_Bindings.cc (pop): use DebugSave() to avoid unused variable warnings (makeVariable): add default: to case SMT_Info::REAL: to avoid spurious uninitialized variable warning * mixfixParser.cc (makeTerms, makeStrategyExprs): use DebugSave() to avoid unused variable warnings * interact.cc (sigsegvHandler): commented out fault_address to indicate we don't use it 2019-12-03 Steven Eker * mixfixParser.cc (insertProduction): fix comparison between signed and unsigned integer expressions warning ===================================Maude127=========================================== 2019-12-02 Rubén Rubio * interpreter.cc: included (fair/depthFirst)FirstStrategicSearch.hh * srewrite.cc (sRewrite): constructs FairStrategicSearch or DepthFirstStrategicSearch depending on the depthFirst parameter (doStategicSearch): removed call to findNextSolutionInDepth 2019-11-22 Steven Eker * lexerAux.cc (eatComment): treat NUL as EOF to patch around what appears to be a flex bug * dagNodePrint.cc (handleDivision): respect PRINT_DISAMBIG_CONST (handleFloat): ditto (handleString): ditto (handleIter): ditto (handleSMT_Number): ditto (handleQuotedIdentifier): ditto (handleMinus): ditto * top.yy: added KW_CONST * lexer.ll: added KW_CONST * commands.yy (printOption): added syntax for disambig const * dagNodePrint.cc (prettyPrint): respect PRINT_DISAMBIG_CONST for regular constants * termPrint.cc (prettyPrint): respect PRINT_DISAMBIG_CONST for regular constants * interpreter.hh (ParameterDatabase): added PRINT_DISAMBIG_CONST to enum PrintFlags 2019-11-21 Steven Eker * interpreter.hh (ParameterDatabase): updated decl for doLoop() * loopMode.cc (loop): create context here rather than in doLoop(); set object mode if EREWRITE_LOOP_MODE flag set (contLoop2): reuse savedState in order to keep external objects; delete savedState on failure (contLoop): create context and possibly with object mode set if we reinitialize loop (doLoop): take context; don't make context (doLoop): use chosen rewrite algorithm; set appropriate continuation function * loopSymbol.hh (FreeSymbol): updated decl for injectInput() * loopSymbol.cc (injectInput): do in-place replacement of original node rather than returning a pointer to a new one * mixfixModule.hh (SharedTokens): deleted decl for 1 arg version of swapVariableAliasMap() * mixfixModule.cc (swapVariableAliasMap): deleted less general 1 arg version * interpreter.hh (ParameterDatabase): deleted decl for doExternalRewriting() * erewrite.cc (doExternalRewriting): deleted * interpreter.hh (ParameterDatabase): added EREWRITE_LOOP_MODE to enum Flags ===================================Maude126=========================================== 2019-11-14 Rubén Rubio * bufferPrint.cc (prettyPrint): solved bug when printing the top combinator, reported by Paco 2019-11-05 Rubén Rubio * syntacticPreModule.cc (addStatement): allow mb/eq/rl in smod/sth * syntacticPreModule.hh (addSortDecl, addSubsortDecl): allow sorts/subsorts in smod/sth * ops.cc (addOpDecl): allow op in smod/sth (addStratDecl): warning message rewritten * mixfixModule.hh (insertPotentialRuleLabels): bugfix: insert() rather than assignment * makeGrammar.cc (makeGrammar): bugfix: call to makeLabelProductions unconditionally since now makeStrategyLanguageProductions only generate RULE_LABEL 2019-11-05 Steven Eker * mixfixModule.hh (SharedTokens): made buffer version of handleVariable() non-static * bufferPrint.cc (handleVariable): handle variable aliases 2019-11-01 Steven Eker * syntacticView.cc (handleTermAndExprMappings): save and restore original parsers; delete any newly created parsers when we're done (showView): save and restore original parsers; check for unexpected parser creation * mixfixModule.cc (swapVariableAliasMap): added two arg version * mixfixModule.hh (SharedTokens): added decl for two arg version of swapVariableAliasMap() 2019-10-29 Steven Eker * mixfixParser.hh (CacheableState): undid derivation from CacheableState 2019-10-28 Steven Eker * mixfixParser.hh (CacheableState): derive from CacheableState ===================================Maude125=========================================== 2019-10-10 Rubén Rubio * bufferPrint.cc (prettyPrint): use ruleLabels instead of potentialLabels to decide whether there is a homonym rule in the module. The loop did not work when the arity was zero. * doParse.cc (parseStrategyExpr): now receives the beginning and end of the tokens to be parsed * importModule.cc (closeSortSet): set nrUserComponents (importRuleLabels): renamed from importLabels and range-based loops * importModule.hh: added attribute nrUserComponents (getNrUserComponents): added (importRuleLabels): renamed from importLabels * lexer.ll: "to-expr" changed to "to expr" * makeGrammar.cc (makeStrategyLanguageProductions): use RULE_LABEL instead of LABEL for rule application labels. * maudemlBuffer.cc (branchAction): removed (generate): calculate the type of the strategy according to its actions * mixfixModule.cc (MixfixModule): set strategyRangeSort to null * mixfixModule.hh (parseStrategyExpr): now receives the beginning and end of the tokens to be parsed (insertPotentialRuleLabels): added (NonTerminal): added RULE_LABEL * modules.yy (viewStratMap): "to-expr" changed to "to expr" (inert): removed "to-expr" * parameterization.cc (makeSummation): importLabels renamed to importRuleLabels * prettyPrint.cc (printStrategyTerm): become method of MixfixModule, parentheses are printed in calls to strategies with homonym rule. (operator<<): call printStrategyTerm as a method * process.cc (process): importLabels renamed to importRuleLabels, call to insertPotentialRuleLabels * profileModule.cc (profileSdRewrite): added * profileModule.hh (profileSdRewrite): added * renameModule.cc (finishCopy): importLabels renamed to importRuleLabels * srewrite.cc (sRewrite): removed argument to TermSet, free subject term when the strategy expression is wrong, print "No solutions" instead of "No more solutions" if there are no solutions at all. * syntacticView.cc (handleTermAndExprMappings): call parseStrategyExpr withe begin=1 to skip the expr keyword * strategyPrint.cc (prettyPrint): call printStrategyTerm as a method * syntacticPreModule.cc (addStatement): insert to potentialRuleLabels * syntacticPreModule.hh (potentialRuleLabels): added * top.yy: removed "to-expr" token declaration * userLevelRewritingContext.cc (traceStrategyCall): call profileSdRewrite * view.cc (insertStratToExprMapping): removed argument to TermSet * viewCache.cc (viewCompare): become method of ViewCache * visibleModule.cc (showKinds): call getNrUserKinds 2019-10-08 Steven Eker * trial.cc (traceEndFragment): reverted change from Alpha95b that broke fragment profiling (traceEndFragment): added comment to explain why we can't rely on trialRef to decide if this fragment is profileable (traceEndFragment): do a getModule() on the preEquation to decide if a fragment is profileable ===================================Maude124=========================================== 2019-09-19 Rubén Rubio * bufferPrint.cc (prettyPrint): solved a bug in the matchrew case 2019-07-15 Rubén Rubio * modules.yy: renamed makeOpDeclsConsistent to makeDeclsConsistent * ops.cc (makeDeclsConsistent): renamed from makeOpDeclsConsistent and handle strategy declarations * strategyTranslation.cc (getStratToExprMapping, getStratToExprMapping): label renamings were not applied to rule application strategies * syntacticPreModule.hh (makeDeclsConsistent): renamed from makeOpDeclsConsistent 2019-07-12 Steven Eker * importTranslation.cc (translateRegularSymbol): use AlwaysAssert() 2019-07-11 Steven Eker * parameterization.cc (addOpMappingsFromView): pass parameterCopyUser to addFromPartOfRenaming() * instantiateModuleWithFreeParameters.cc (handleInstantiationByModuleView): pass extra arument to addOpMappingsFromView() (handleInstantiationByTheoryView): pass extra argument to addOpMappingsFromView() * instantiateViewWithFreeParameters.cc (handleInstantiationByTheoryView): pass extra arument to addOpMappingsFromView() (handleInstantiationByModuleView): pass extra argument to addOpMappingsFromView() * importModule.hh (EnclosingObject): updated decls for translateComponent() and addFromPartOfRenaming() * parameterization.cc (addFromPartOfRenaming) (translateComponent): take parameterCopyUser argument * importModule.hh (EnclosingObject): updated decl for addOpMappingsFromView() * parameterization.cc (addOpMappingsFromView): take parameterCopyUser argument; use it to ensure op mapping get added with the potentially larger components belonging to the user of the parameterCopy 2019-06-03 Rubén Rubio * importModule.cc (importLabels): use importedRuleLabels set (donateStrategies): adapted to changes in alpha121. * instantiateModuleWithBoundParameters.cc (instatiateRenaming): handle strategy mappings * instantiateModuleWithFreeParameteres.cc (handleInstantiationByModuleView): call to addStratMappings * instantiateViewWithFreeParameters.cc (makeInstantiation): call to handleStratMappings and handleStratToExprMappings (handleInstantiationByTheoryView): call to addStratMappingsFromView (handleInstantiationByModuleView): call to addStratMappingsFromView (handleStratMappings, handleStratAkwardCase): added (handleStratToExprMappings): added * parameterization.cc (addStratMappingsFromView): used getStratToExprMappings * renaming.cc (addStratMappingPartialCopy): added (addStratTargetExpr): now receives and stores the left-hand side expression * renaming.hh (addStratMappingPartialCopy): added (addStratTargetExpr): now receives the left-hand side expression (getStratFromCall): added (StratMapping): added fromCall attribute * syntacticView.cc (handleTermAndExprMappings): adapted insertStratToExprMapping to the changes of alpha121 (getTargetExprModule): removed * view.cc (insertStratToExprMapping): adapted to the changes of alpha121 (getStratMapExpr, getStratMapVarIndices): removed (getStratToExprMapping): added (checkStrats): call to getStratToExprMapping * view.hh (insertStratToExprMapping): adapted to the changes of alpha121 (handleStratMappings, handleStratAkwardCase): added (handleStratToExprMappings, getStratToExprMapping): added (getTargetExprModule): removed 2019-05-28 Steven Eker * instantiateViewWithFreeParameters.cc (makeInstantiation): use new makeToModule() semantics * view.hh (EnclosingObject): updated decl for makeToModule() * instantiateViewWithFreeParameters.cc (makeToModule): return targetInstance rather than insert it * instantiateModuleWithBoundParameters.cc (handleFinalInstantiation): added defensive code in case v->instantiateBoundParameters() returns null 2019-05-25 Rubén Rubio * command.cc (printStratDecl): call to printAttributes (printAttributes): added for strategy declarations * commands.yy: added show sds and show strats commands * entry.cc (addStrategy): added metadata parameter. Call findStrategy and insertMetadata * importModule.cc (donateStrategies2): donate metadata (donateStatements2): donate attributes of strategy definitions * interpreter.cc (showStrats, showSds): added * interpreter.hh (showStrats, showSds): added * lexer.ll: added lexemes for show sds/strats commands * metadataStore.hh (ItemType): added STRAT_DECL and STRAT_DEF * mixfixModule.hh (addStrategy): added metadata parameter * mixfixParser.cc (makeStatementPart): handle metadata and print attribute in strategy definitions * modules.yy: added strategy declaration attributes syntax * prettyPrint.cc (operator<<): print metadata in strategy declarations * process.cc (processStrategies): handle metadata * syntacticPreModule.hh (printAttributes): added for strategy decls * top.yy: added KW_STRATS * userLevelRewritingContext.cc (traceStrategyCall): handle print attribute and corrected an erratum in traces (too many line breaks) * view.cc (evaluate): moved a check about strategy mappings in views (insertStratToExprMapping): solved some memory leaks * visibleModule.cc (showSummary): added strategy declarations and definitions to the summary (showModule): call to showSds (showStrats): moved code showing strategy definitions to showSds (showSds): added from showStrats * visibleModule.hh (showSds): added 2019-05-24 Steven Eker * view.hh (EnclosingObject): added decl for makeToModule() * instantiateViewWithFreeParameters.cc (makeToModule): added (makeInstantiation): use makeToModule() but make sure this happens after parameters instantiated by theory-views have been checked for conflicts * syntacticView.hh (_syntacticView_hh_): fix header guard * interpreter.cc (makeModule): commented out advisory about renaming module with bound parameters 2019-05-23 Steven Eker * quotedIdentifierOpSymbol.cc (eqRewrite): use new tokenizeRope() convention * tokenizer.ll (Rope): pass back pointer than reference from tokenizeRope() to avoid an issue with yyterminate()/YY_NULL * mixfixParser.cc (insertProduction): made check for bad gather size #ifndef NO_ASSERT * view.cc (insertOpToTermMapping): deleted unused variable i 2019-05-22 Steven Eker * view.hh (operator<<): needed in the NO_ASSERT case also * token.cc (splitParameterInstanceName): commented out * renaming.hh (SyntaxContainer): commented out decl for addOpMappingSimpleCopy() * renaming.cc (addOpMappingSimpleCopy): commented out * token.hh (T): commented out decl for splitParameterInstanceName() * syntacticView.cc (addParameter2): comment out experimental advisory for parameterized views * interpreter.cc (handleArgument): comment out experimental advisory for view instantiation * modules.yy (view): don't hand responsibility for deleted fromTheory/toModule expressions until the production has succeed and their no longer on the bision stack (instantExpr): delete vector after passing its contents to ModuleExpression() 2019-05-21 Steven Eker * instantiateModuleWithFreeParameters.cc (makeInstantiation): DebugAdvisory() -> DebugInfo() * instantiateViewWithFreeParameters.cc (makeInstantiation): set copy status to BAD rather than using markAsBad() * view.hh (isBad): added (EnclosingObject): don't derive from BadFlag * view.cc (evaluate): check for recursive use; set status to PROCESSING * process.cc (process): added closeSortSet() hack to that SyntacticPreModule::getFlatSignature() won't get confused * syntacticPreModule.cc (getFlatSignature): added DebugNew() 2019-05-20 Steven Eker * importModule.hh (EnclosingObject): added decl for checkForPolymorphOperatorClash() * importModule.cc (checkForPolymorphOperatorClash): added * moduleCache.cc (makeSummation): deleted commented out code 2019-05-16 Steven Eker * view.hh (EnclosingObject): deleted decl for recoverVariableNames() * instantiateViewWithFreeParameters.cc (handleOpMappings): pass fromTerm to handleAwkwardCase() (handleAwkwardCase): simplified using fromTerm argument (recoverVariableNames): deleted * view.cc (checkOps): getOpMapTerm() -> getOpToTermMapping() (2 places) * instantiateViewWithFreeParameters.cc (handleOpMappings): getOpMapTerm() -> getOpToTermMapping() * parameterization.cc (addOpMappingsFromView): getOpMapTerm() -> getOpToTermMapping() * view.hh (EnclosingObject): getOpMapTerm() -> getOpToTermMapping() * view.cc (getOpMapTerm): becomes getOpToTermMapping() * view.hh (EnclosingObject): updated decl for getOpMapTerm() * view.cc (getOpMapTerm): new semantics * parameterization.cc (addOpMappingsFromView): propagate fromTerm for op->term mappings * renaming.cc (addOpTargetTerm): store fromTerm (addOpTarget): zero fromTerm (both versions) * renaming.hh (SyntaxContainer): updated decl for addOpTargetTerm() (SyntaxContainer): added fromTerm field to struct OpMapping (getFromTerm): added 2019-05-15 Steven Eker * instantiateViewWithFreeParameters.cc (makeInstantiation): use handlePolymorphMappings() * view.hh (EnclosingObject): deleted decl for old handleOpMappings(); added decl for handlePolymorphMappings() * instantiateViewWithFreeParameters.cc (handleOpMappings): deleted old version (handlePolymorphMappings): added * view.hh (EnclosingObject): added decls for handleAwkwardCase(), recoverVariableNames() * instantiateViewWithFreeParameters.cc (recoverVariableNames) (handleAwkwardCase): added (handleOpMappings): use handleAwkwardCase() * renaming.cc (printRenaming): replaced Assert() that op->term mappings aren't printable with debug code that prints a syntactically illegal representation 2019-05-14 Steven Eker * instantiateViewWithFreeParameters.cc (makeInstantiation): use new version of handleOpMappings() (handleOpMappings): check for the existence of an op->term mapping and don't general mapping for such operators * view.hh (EnclosingObject): delete decl for old handleSortMappings(); add decl for new handleOpMappings() * instantiateViewWithFreeParameters.cc (handleOpMappings): added canonicalRenaming base version 2019-05-13 Steven Eker * view.cc (checkSorts): check for case where module declared sort is implicitly mapped to a sort derived from a parameter theory (checkSorts): added check for sort mapping from nonexistent sort * instantiateViewWithFreeParameters.cc (makeInstantiation): delete canonicaRenaming once we are done with it; use new handleSortMappings() (handleSortMappings): handle pathological case (handleSortMappings): deleted old version * view.hh (EnclosingObject): added decl for new version of handleSortMappings() * renaming.hh (SyntaxContainer): added comment to explain that terms are never owned nor deleted and the semantics of using Renaming means that dangling Term* pointers are never dereferenced * parameterization.cc (addOpMappingsFromView): added comment to the effect that the renaming borrows toTerm * instantiateViewWithFreeParameters.cc (handleOpToTermMappings): fixed comments (handleSortMappings): added simpler version base on canonicalRenaming 2019-05-10 Steven Eker * view.hh (EnclosingObject): deleted decl for old version of handleOpToTermMappings() * instantiateViewWithFreeParameters.cc (handleInstantiationByParameter): use addSortRenamingsForParameterChange() to update canonical if the parameter name changes (handleInstantiationByModuleView): use addSortMappingsFromModuleView(), addOpMappingsFromView() (makeInstantiation): use handleParameterizedSorts() (makeInstantiation): use new handleOpToTermMappings() (handleOpMappings): adde new version (handleOpMappings): deleted old version * instantiateModuleWithFreeParameters.cc (handleInstantiationByModuleView): use addSortMappingsFromModuleView() * importModule.hh (EnclosingObject): added decl for addSortMappingsFromModuleView() * parameterization.cc (addSortMappingsFromModuleView): added * instantiateModuleWithFreeParameters.cc (handleInstantiationByParameter): use addSortRenamingsForParameterChange() * importModule.hh (EnclosingObject): added decl for addSortRenamingsForParameterChange() * parameterization.cc (addSortRenamingsForParameterChange): added * instantiateViewWithFreeParameters.cc (handleInstantiationByTheoryView): use new addOpMappingsFromView() * instantiateModuleWithFreeParameters.cc (handleInstantiationByTheoryView): use new addOpMappingsFromView() (handleInstantiationByModuleView): use new addOpMappingsFromView() (addOpMappingsFromView, translateComponent): deleted * importModule.hh (EnclosingObject): added decls for new versions of addOpMappingsFromView(), translateComponent(); deleted decls for old verions of addOpMappingsFromView(), translateComponent(); adde decl for addFromPartOfRenaming() * parameterization.cc (translateComponent): added (translateComponent, addFromPartOfRenaming) (addOpMappingsFromView): added * importModule.hh (EnclosingObject): deleted decl for old version of addSortMappingsFromTheoryView() * instantiateModuleWithFreeParameters.cc (addSortMappingsFromTheoryView): deleted * instantiateViewWithFreeParameters.cc (handleInstantiationByTheoryView): use new version of addSortMappingsFromTheoryView() * instantiateModuleWithFreeParameters.cc (handleInstantiationByTheoryView): use new version of addSortMappingsFromTheoryView() * importModule.hh (EnclosingObject): added decl for new addSortMappingsFromTheoryView() * parameterization.cc (addSortMappingsFromTheoryView): added version that takes parameterCopyOfTheory as object 2019-05-09 Steven Eker * instantiateViewWithFreeParameters.cc (handleInstantiationByTheoryView): use ImportModule::addSortMappingsFromTheoryView() * instantiateModuleWithFreeParameters.cc (handleInstantiationByTheoryView): use addSortMappingsFromTheoryView() * importModule.hh (EnclosingObject): added decl for addSortMappingsFromTheoryView() * instantiateModuleWithFreeParameters.cc (addSortMappingsFromTheoryView): added 2019-05-08 Steven Eker * view.hh (EnclosingObject): updated decls for handleInstantiationByTheoryView(), handleInstantiationByParameter(), handleInstantiationByModuleView() * instantiateViewWithFreeParameters.cc (handleInstantiationByTheoryView): made const (handleInstantiationByParameter): made const (handleInstantiationByModuleView): made const * importModule.hh (EnclosingObject): make addOpMappingsFromView() public * instantiateViewWithFreeParameters.cc (makeInstantiation): no longer deal with the case that our toModule has no parameters since each of our free parameters is required to be bound in toModule (makeInstantiation): make toModule instantiation before worrying about the rest of the view (handleInstantiationByTheoryView): call addOpMappingsFromView() * view.cc (evaluate): make having parameters that are not bound in the toModule illegal - this greatly simplifies handling parameters since now we can rely on the toModule machinery for much of the heavy lifting (regretToInform): don't do the pretend self-destruct now that we rely on our toModule to trigger the invalidation cascade 2019-05-07 Steven Eker * instantiateViewWithFreeParameters.cc (handleInstantiationByTheoryView): added some of the code to make a canonical renaming * importModule.hh (getCanonicalRenaming): added * view.hh (EnclosingObject): updated decls for handleInstantiationByTheoryView() handleInstantiationByParameter(), handleInstantiationByModuleView() 2019-05-06 Steven Eker * importModule.hh (EnclosingObject): added decls for handleSummation(), handleRenaming(), handleFinalInstantiation() (EnclosingObject): updated comment on parameter theories and imports now that this are kept in separate data structures * instantiateModuleWithBoundParameters.cc (instantiateRenaming): use DebugEnter()/DebugExit() (handleSummation, handleRenaming, handleFinalInstantiation): addes (instantiateBoundParameters): rewritten using handleSummation(), handleRenaming(), handleFinalInstantiation() 2019-05-03 Steven Eker * instantiateModuleWithBoundParameters.cc (instantiateBoundParameters): handle summation * importModule.hh (EnclosingObject): deleted VIEW_LOCAL from enum Origin * interpreter.cc (makeModule): check for free parameters in sum rather than any parameters * parameterization.cc (makeSummation): handle bound parameters * instantiateModuleWithFreeParameters.cc (handleBoundParameters): updated comment about the existence of parameter theory copies * moduleCache.cc (makeSummation): use ImportModule::makeSummation() * importModule.hh (EnclosingObject): added decl for makeSummation() * parameterization.cc (makeParameterCopy): use DebugEnter()/DebugExit() (makeSummation): added * instantiateModuleWithFreeParameters.cc (handleRegularImports): use DebugInfo() (makeInstantiation): use DebugEnter() (makeInstantiation): use DebugExit() * view.hh (EnclosingObject): added comments for enum Status * interpreter.cc (showView): don't call SyntacticView::showView() unless the view is in a GOOD state * importModule.hh (EnclosingObject): updated decls for handleInstantiationByModuleView(), handleBoundParameters() * instantiateModuleWithFreeParameters.cc (handleInstantiationByParameter): code cleaning (handleBoundParameters): check for null from makeParameterCopy() (handleInstantiationByModuleView): check for failure from handleBoundParameters() (makeInstantiation): check for failure from handleInstantiationByModuleView() * process.cc (processImports): check bad flag after processing parameters and quit if bad so we don't get spurious warnings about missing parameters * renameModule.cc (donateSorts2): complain about the renamed sort rather than the original name since that's where the clash occurs; this should only affect parameter theory copies since in other cases we form the renamed theory or module first * process.cc (process): check for badness after doing parameters/imports * preModule.cc (processExplicitImports): mark import as bad if import couldn't be constructed or had free parameters (processParameters): mark flat module as bad if parameter couldn't be constructed or parameter was illegal * process.cc (processImports): mark importer as bad if import failed 2019-05-02 Steven Eker * importModule.hh (EnclosingObject): updated decl for handleInstantiationByModuleView(); added decl for handleBoundParameters() * instantiateModuleWithFreeParameters.cc (handleBoundParameters): added (handleInstantiationByModuleView): use handleBoundParameters() (handleInstantiationByModuleView): don't keep track of bound parameters or return a bool * view.hh (EnclosingObject): added decl for handleOpToTermMappings() * instantiateViewWithFreeParameters.cc (handleOpToTermMappings): added (makeInstantiation): use handleOpToTermMappings() * view.hh (EnclosingObject): added decl for handleOpMappings() * instantiateViewWithFreeParameters.cc (handleSortMappings): rewritten to check for sorts from parameter theory that actually came from a module originally (handleOpMappings): added (makeInstantiation): use handleOpMappings() * preModule.cc (processParameters): handle makeParameterCopy() returning null * parameterization.cc (makeParameterCopy): check for makeParameterCopy() returning null * importModule.hh (EnclosingObject): updated decl for handleInstantiationByParameter() * instantiateModuleWithFreeParameters.cc (handleInstantiationByTheoryView): check for makeParameterCopy() returning null (handleInstantiationByParameter): check for makeParameterCopy() returning null (makeInstantiation): handle return value from handleInstantiationByParameter() * moduleCache.cc (makeParameterCopy): handle the possibility of a bad parameter copy under weird circumstances * renameModule.cc (donateSorts2): set sortDeclaredInModule even for module->module importations * instantiateViewWithFreeParameters.cc (handleInstantiationByModuleView): added comment to explain why copying conflicts from argument is currently needed (handleInstantiationByParameter): added comment to explain why propagating conflicts on bare parameters is unnecessary (makeInstantiation): use handleSortMappings() 2019-05-01 Steven Eker * instantiateViewWithFreeParameters.cc (handleInstantiationByModuleView): add conflicts between bare parameters and bound parameters in module-view (handleInstantiationByModuleView): copy in conflicts from argument - but need to check if this is really needed * instantiateModuleWithFreeParameters.cc (handleInstantiationByModuleView): fix bug where we were doing conflict generation and propagation even for theory-view because we had if-nesting wrong * instantiateViewWithFreeParameters.cc (handleInstantiationByParameter): record positionsInstantiatedParameter * view.cc (evaluate): use setToModule() * instantiateViewWithFreeParameters.cc (makeInstantiation): use setToModule() * view.hh (setToModule): added * instantiateViewWithFreeParameters.cc (makeInstantiation): add in conflicts from targetInstance * viewCache.cc (makeViewInstantiation): check for bad view returned from makeInstantiation() * view.hh (EnclosingObject): updated decl for handleInstantiationByTheoryView() (BadFlag): add BadFlag as a public base * instantiateViewWithFreeParameters.cc (makeInstantiation): use handleInstantiationByTheoryView(), handleInstantiationByParameter(), handleInstantiationByModuleView() (handleInstantiationByTheoryView): check for conflict (makeInstantiation): check for failure from handleInstantiationByTheoryView() * view.hh (EnclosingObject): added decls for handleInstantiationByTheoryView(), handleInstantiationByParameter(), handleInstantiationByModuleView() * instantiateViewWithFreeParameters.cc (handleInstantiationByTheoryView) (handleInstantiationByParameter) (handleInstantiationByModuleView): added 2019-04-30 Steven Eker * instantiateViewWithFreeParameters.cc (makeInstantiation): handle the case where a sort is mapped to a sort from a parameter theory (makeInstantiation): fix bug where we were using the wrong iterator variable for bound parameters in a module-view arugment * token.hh (T): decl for parameterRename() becomes makeParameterInstanceName() * instantiateModuleWithFreeParameters.cc (handleInstantiationByTheoryView): parameterRename() -> makeParameterInstanceName() (handleInstantiationByParameter): parameterRename() -> makeParameterInstanceName() * parameterization.cc (makeParameterCopy): parameterRename() -> makeParameterInstanceName() (2 places) * token.cc (splitParameterInstanceName): added (parameterRename): becomes makeParameterInstanceName() * token.hh (T): added decl for splitParameterInstanceName() * auxProperty.cc (splitParameterizedSort): added comment to explain what it does (splitParameterList): added comment to explain what it does (joinParameterList): added comment to explain what it does 2019-04-29 Steven Eker * instantiateViewWithFreeParameters.cc (makeInstantiation): moved here * instantiateViewWithBoundParameters.cc (instantiateBoundParameters): moved here 2019-04-26 Steven Eker * interpreter.cc (makeModule): check for theory-view and view with bound parameters in the same instantiation (handleArgument): check for theory-view and view with bound parameters in the same instantiation * importModule.cc (addImport): propagate conflicts here * instantiateModuleWithFreeParameters.cc (handleRegularImports): don't propagate conflicts here * enclosingObject.cc (addConflict, addInAllConflicts) (hasConflict, findFirstClash): added * instantiateModuleWithFreeParameters.cc (handleRegularImports): add in conflicts from imports * importModule.hh (EnclosingObject): update decl for handleInstantiationByModuleView() * instantiateModuleWithFreeParameters.cc (makeInstantiation): pass positionsInstantiatedParameter to handleInstantiationByModuleView() * enclosingObject.hh (E): added decl for hasConflict() * instantiateModuleWithFreeParameters.cc (makeInstantiation): handle new handleInstantiationByParameter() semantics * importModule.hh (EnclosingObject): updated decl for handleInstantiationByParameter() * instantiateModuleWithFreeParameters.cc (makeInstantiation): handle failure from handleInstantiationByTheoryView() (handleInstantiationByParameter): propagate conflicts from us to our instantiation at positions instantiated by parameter (handleInstantiationByParameter): take positionsInstantiatedParameter as an argmuent * enclosingObject.hh (E): added decls for addInAllConflicts() and makeConflictsWithBoundParameters() * importModule.hh (EnclosingObject): updated decl for handleInstantiationByTheoryView() * instantiateModuleWithFreeParameters.cc (handleInstantiationByTheoryView): check for conflicts between parameters and return bool * enclosingObject.hh (E): added decls for addConflict() and firstClash() 2019-04-23 Steven Eker * importModule.cc (donateSorts): don't make recursive call on parameterTheories - the importer will alrady have these (donateOps): symmetric change (fixUpDonatedOps): symmetric change (donateStatements): symmetric change (resetImportPhase): call self rather than resetImports() because there is no need to reset parameterTheories because we won't have imported from them. 2019-04-22 Steven Eker * renameModule.cc (makeRenamedCopy): rewritten for parameterTheories/importedModules split * instantiateModuleWithFreeParameters.cc (handleInstantiationByParameter): use parameterTheories (handleInstantiationByTheoryView): use parameterTheories (handleInstantiationByModuleView): use parameterTheories (handleRegularImports): don't skip first entries as they are no longer parameter theories * importModule.cc (deepSelfDestruct): remove ourself as user of parameter theories (importSorts): rewritten for parameterTheories/importedModules split (donateSorts): rewritten for parameterTheories/importedModules split (importOps): rewritten for parameterTheories/importedModules split (donateOps): rewritten for parameterTheories/importedModules split (fixUpImportedOps): rewritten for parameterTheories/importedModules split (importStatements): rewritten for parameterTheories/importedModules split (fixUpDonatedOps): rewritten for parameterTheories/importedModules split (addParameter): use parameterTheories (resetImports): rewritten for parameterTheories/importedModules split (dumpImports): rewritten for parameterTheories/importedModules split (donateStatements): rewritten for parameterTheories/importedModules split * importModule.hh (EnclosingObject): added data member parameterTheories * importModule.cc (addParameter): more detailed warning message (addImport): more detailed warning message * instantiateModuleWithFreeParameters.cc (makeInstantiation): do parameters from enclosing objects last (handleInstantiationByTheoryView): code cleaning (handleInstantiationByParameter): code cleaning * instantiateView.cc (makeInstantiation): toModule -> viewToModule in view arugment code to avoid confusing overloading 2019-04-19 Steven Eker * instantiateView.cc (makeInstantiation): make parameterizedSortRenaming * importModule.hh (EnclosingObject): make handleParameterizedSorts() public so we can call it from View * instantiateModuleWithFreeParameters.cc (handleParameterizedSorts): don't sorts from parameter theories 2019-04-18 Steven Eker * importTranslation.cc (translateTerm): added comment to explain why skipping translation of toTerm during instantiation is a fail 2019-04-17 Steven Eker * importTranslation.cc (translateTerm): added comments to explain how it works * syntacticView.cc (handleOpTermMappings): take responsibility for deepSelfDestruct()ing fromTerm and toTerm if insertOpToTermMapping() fails * view.cc (insertOpToTermMapping): make caller responsible for deepSelfDestruct()ing term on error * syntacticView.cc (handleOpTermMappings): don't pass line numbers to insertOpToTermMapping() (handleOpTermMappings): propagate errors from insertOpToTermMapping() * view.hh (EnclosingObject): updated decl for insertOpToTermMapping() * view.cc (insertOpToTermMapping): use line number from term for warning about too many arguments in lhs; improve warning message (insertOpToTermMapping): use line number from term for warning about non-variable arugments in lhs; improve the warning message (insertOpToTermMapping): use line number from term for warning about repeated use of variable in lhs; improve warning message (insertOpToTermMapping): don't take line number arguments * view.hh (EnclosingObject): updated decl for indexRhsVariables() * view.cc (indexRhsVariables): don't take lineNr; use *term instead; better warning message (insertOpToTermMapping): don't pass lineNumber to indexRhsVariables() * view.hh (EnclosingObject): updated decl for insertOpToTermMapping() * view.cc (insertOpToTermMapping): don't take targetModule; don't pass module to mapSort() * syntacticView.cc (handleOpTermMappings): don't pass toModule to insertOpToTermMapping() * view.hh (EnclosingObject): updated decl for mapSort() * view.cc (mapComponent): don't take module argument (checkOps): don't pass module argument to mapComponent() (mapSort): don't take or pass module argument * view.hh (EnclosingObject): updated decl for mapComponent() * syntacticView.cc (handleOpTermMappings): don't pass toModule to mapComponent() * view.hh (EnclosingObject): LocalParameter->ParameterDecl * view.cc: LocalParameter->ParameterDecl * view.hh (EnclosingObject): updated comments 2019-04-16 Steven Eker * syntacticView.cc (handleOpTermMappings): code cleaning * mixfixModule.hh (SharedTokens): deleted decls for pushVariableAliases(), popVariableAliases() (SharedTokens): deleted data member savedVariableAliases * mixfixModule.cc (pushVariableAliases, popVariableAliases): deleted * syntacticView.cc (handleVarDecls): put alias info in fromTheoryVariableAliases and toModuleVariableAliases (handleOpTermMappings): rewritten to use fromTheoryVariableAliases and toModuleVariableAliases (showView): swap variable aliases before and after printing out op->term mappings (handleVarDecls): clear fromTheoryVariableAliases and toModuleVariableAliases in case we are reexamining this view * syntacticView.hh (View): added data members toModuleVariableAliases, fromModuleVariableAliases * mixfixModule.hh (SharedTokens): added decl for swapVariableAliasMap() * mixfixModule.cc (swapVariableAliasMap): added * syntacticView.hh (View): deleted data members newFromTheory, newToModule; deleted decls for ~SyntacticView(), regretToInform(), finishModule() * syntacticView.cc (handleOpTermMappings): simplified using pushVariableAliases()/popVariableAliases() (SyntacticView): don't init newFromTheory, newToModule (~SyntacticView): deleted (regretToInform): deleted (finishModule): deleted (handleVarDecls): use original fromTheory/toModule rather than newFromTheory/newToModule * mixfixModule.hh (SharedTokens): added data member savedVariableAliases; added decls for pushVariableAliases(), popVariableAliases() * mixfixModule.cc (pushVariableAliases): added (popVariableAliases): added 2019-04-15 Steven Eker * moduleExpression.cc (deepSelfDestruct): get rid of RENAMING fall thru now that INSTANTIATION has to deepSelfDestruct() ViewExpressions * viewExpression.cc (deepSelfDestruct): delete self * interpreter.cc (handleArgument): fixed warning so they don't refer to enclosing expressions (which is unavailable) 2019-04-12 Steven Eker * view.cc: struct Parameter -> struct LocalParameter throughout file * view.hh (EnclosingObject): updated decl for 2nd ctor (EnclosingObject): struct Parameter -> struct LocalParameter * viewCache.hh (User): updated decl for makeViewInstantiation() * viewCache.cc (makeViewInstantiation): use Argument* * view.hh (EnclosingObject): updated decls for makeInstantiation() and instantiateBoundParameters() * instantiateView.cc (makeInstantiation): use Argument* (instantiateBoundParameters): rewritten to use Argumetn* * view.cc (View): use Argument* (~View): use savedArguments * view.hh (EnclosingObject): deleted data members savedViewArgs, savedParameterArgs; added data member savedArguments * importModule.cc (deepSelfDestruct): need to check savedArguments for views that we're no longer a user of * importModule.hh (EnclosingObject): updated decl for instantiateBoundParameters() * instantiateModuleWithBoundParameters.cc (instantiateBoundParameters): rewritten to handle Argument* * importModule.hh (EnclosingObject): updated decls for makeInstantiation(), handleInstantiationByParameter(), handleInstantiationByTheoryView(), handleInstantiationByModuleView(), handleRegularImports() (EnclosingObject): deleted data members savedViewArgs, savedParameterArgs; added data member savedArguments * instantiateModuleWithFreeParameters.cc (makeInstantiation): don't pass parameterArgs to handleInstantiationByParameter() (handleInstantiationByParameter): handle Argument* (handleInstantiationByTheoryView): handle Argument* (handleInstantiationByModuleView): handle Argument* (makeInstantiation): don't pass parameterArgs to handleRegularImports() (handleRegularImports): handle Argument* * moduleCache.hh (User): added decl for makeModuleInstatiation() * moduleCache.cc (makeModuleInstatiation): added * interpreter.hh (ParameterDatabase): updated decl for handleArgument * interpreter.cc (handleArgument): rewritten to use Argument* (makeModule): use makeModuleInstantiation * parameterDatabase.cc (getParameter): added * interpreter.cc (makeModule): use Argument* for passing arguments rather that View* and parameter names * interpreter.hh: inherit from ParameterDatabase * mixfix.hh: added class ParameterDatabase * parameterDatabase.cc: created * parameterDatabase.hh: created * interpreter.cc (makeModule): arguments -> argumentExpressions (handleArgument): arguments -> argumentExpressions * enclosingObject.hh (E): make hasBoundParameters() public * importModule.hh (hasBoundParameters): deleted * renameModule.cc (makeRenamedCopy): use copyBoundParameters() * enclosingObject.hh (copyBoundParameters): added * importModule.hh (hasBoundParameters): use EnclosingObject::hasBoundParameters() * view.hh (hasBoundParameters): deleted * enclosingObject.hh (hasBoundParameters): added * instantiateView.cc (makeInstantiation): call addBoundParameter() (2 places) * instantiateModuleWithFreeParameters.cc (handleInstantiationByParameter): call addBoundParameter() (handleInstantiationByModuleView): call addBoundParameter() * enclosingObject.hh (E): added data member boundParameters (addBoundParameter): added * view.cc (View): pass name to Argument ctor rather than NamedEntity ctor * view.hh (EnclosingObject): derive from Argument rather than NamedEntity * mixfix.hh: added class Argument and class Parameter * argument.hh: created * parameter.hh: created 2019-04-10 Steven Eker * instantiateView.cc (makeInstantiation): use DebugEnter() and DebugExit() (instantiateBoundParameters): use DebugEnter() and DebugExit() (makeInstantiation): use DebugInfo() 2019-04-09 Steven Eker * instantiateView.cc (makeInstantiation): handle general and specific op->op mappings (instantiateBoundParameters): remove FIXME because we are handling the case where the are bound parameters in a savedViewArgument * renaming.hh (SyntaxContainer): added decl for addOpMappingSimpleCopy() * renaming.cc (addOpMappingSimpleCopy): added * instantiateView.cc (makeInstantiation): handle the dubious case where the toModule has no parameters * view.hh (setCleanName): deleted (EnclosingObject): updated decls for ctor and makeInstantiation() * view.cc (View): take and set cleanName * instantiateView.cc (makeInstantiation): take cleanName argument and pass it to View ctor * viewCache.cc (makeViewInstantiation): pass cleanName to makeInstantiation rather than using setCleanName() * view.hh (EnclosingObject): updated decl for instantiation version of ctor * instantiateView.cc (makeInstantiation): pass viewArgs to ctor (makeInstantiation): don't add copy as a user since this is already done in the ctor for view instantiations * view.cc (View): (instantiation version) take and save view arguments; add ourselves as a user of each such argument (~View): remove ourselves as a user of each view argument * view.hh (EnclosingObject): updated comments 2019-04-08 Steven Eker * instantiateView.cc (makeInstantiation): get nrBoundParameters from argumentView rather than toModule to handle the case where not all of the parameters appear in toModule * view.hh (EnclosingObject): make baseView const so it can only be set in the ctor * instantiateView.cc (makeInstantiation): updated comment (makeInstantiation): clean up instantiation by parameter from an enclosing object case (makeInstantiation): don't set pointer to baseView in bound argument case since this is already done in the View() ctor that is used for instantiations 2019-04-05 Steven Eker * view.cc (regretToInform): call informUsers() if we become stale to catch an edge case (evaluate): issue an advisory for view parameters that are not bound in the target module * interpreter.cc (handleArgument): check for free parameters in view argument * view.hh (hasBoundParameters, hasFreeParameters): added * interpreter.cc (makeModule): check for free parameters in view argument 2019-04-03 Steven Eker * interpreter.cc (handleArgument): warning should refer to view instantiation rather than module instantiation (2 places) (handleArgument): more detailed warning (makeModule): allow renaming of modules with bound parameters but issue an advisory 2019-04-02 Steven Eker * view.cc (View): add self as user of baseView (~View): remove self as user of baseView (View): add our interpreters viewCache as a user * view.hh (EnclosingObject): added decl for new ctor * view.cc (View): added version of instantiations 2019-03-29 Steven Eker * instantiateView.cc (makeInstantiation): use hasFreeParameters() * instantiateModuleWithFreeParameters.cc (handleRegularImports): use hasFreeParameters() * view.cc (evaluate): use hasFreeParameters() * preModule.cc (processExplicitImports): use hasFreeParameters() * importModule.hh (parametersBound): deleted (hasFreeParameters): added * interpreter.cc (makeModule): use hadBoundParameters(); remove NEED TO FIX comment * preModule.cc (processExplicitImports): use hasBoundParameters() * instantiateView.cc (makeInstantiation): use hasBoundParameters() * view.cc (evaluate): use hasBoundParameters() * instantiateModuleWithBoundParameters.cc (instantiateBoundParameters): use hasBoundParameters() * instantiateModuleWithFreeParameters.cc (makeInstantiation): use hasBoundParameters() (handleRegularImports): use hasBoundParameters() (2 places) * importModule.hh (hasBoundParameters): added (EnclosingObject): deleted commented out ParameterMap, ParameterSet * view.cc (addParameter): call addUser() to add self to theories users (View): init fromExpr, toExpr (~View): check for non-null before deepSelfDestruct()ing module expressions * importModule.cc (deepSelfDestruct): viewArgs -> savedViewArgs * instantiateModuleWithFreeParameters.cc (makeInstantiation): paramArgs -> savedParameterArgs (makeInstantiation): viewArgs -> savedViewArgs * instantiateModuleWithBoundParameters.cc (instantiateBoundParameters): viewArgs -> savedViewArgs (instantiateBoundParameters): paramArgs -> savedParameterArgs * importModule.hh (EnclosingObject): viewArgs -> savedViewArgs; paramArgs -> savedParameterArgs (parametersBound): paramArgs -> savedParameterArgs (parametersBound): viewArgs -> savedViewArgs 2019-03-28 Steven Eker * importModule.hh (parametersBound): moved here; make OK to call on all modules, even ones without parameters * interpreter.cc (makeModule): don't allow renaming of modules with bound parameters 2019-03-27 Steven Eker * instantiateView.cc (makeInstantiation): use boundParameter flag to insure we keep baseView, savedViewArgs, savedParameterArgs, even if bound parameters come from our arguments * view.hh (EnclosingObject): added comments 2019-03-26 Steven Eker * instantiateView.cc (makeInstantiation): use cleanName() for view arguments; first attempt at handling arguments that are view instantiations with bound parameters * syntacticView.cc (addParameter2): changed advisory message * instantiateView.cc (instantiateBoundParameters): moved here (makeInstantiation): moved here 2019-03-25 Steven Eker * importModule.cc (importSorts): fix longstanding bug where we didn't set nrSortsFromParameters unless we had at least one regular importation of a module (importOps): fix symmetric bugs with nrSymbolsFromParameters and nrPolymorphsFromParameters * renameModule.cc (makeRenamedCopy): added comment; deleted commented out Assert() because we do allow the renaming of modules with bound parameters * renaming.cc (makeCanonicalVersion): added DebugAdvisory()s * renameModule.cc (localSort2): turn Assert() into a DebugAdvisoryCheck() (localSort2): reverted 2019-03-22 Steven Eker * instantiateModuleWithFreeParameters.cc (makeInstantiation): pass moduleCache to handleInstantiationByModuleView() * importModule.hh (EnclosingObject): updated decl for handleInstantiationByModuleView() * instantiateModuleWithFreeParameters.cc (handleInstantiationByModuleView): take moduleCache argument * importModule.cc (getParameterTheory): moved here because it is virtual in base class EnclosingObject * importModule.hh (EnclosingObject): added more explanation of how parameter theories are stored * instantiateModuleWithFreeParameters.cc (handleInstantiationByParameter): toModule -> baseParameterTheory * importModule.hh (getParameterTheory): added comment to explain why it works the way it does * instantiateModuleWithFreeParameters.cc (handleInstantiationByParameter): added DebugAdvisory() to check change in parameter theory name * moduleCache.cc (showCreatedModules): call dumpImports() * importModule.cc (dumpImports): added * importModule.hh (EnclosingObject): added decl for dumpImports() * moduleCache.cc (showCreatedModules): dump sorts if we are in debug mode 2019-03-21 Steven Eker * instantiateModuleWithBoundParameters.cc (instantiateBoundParameters): views -> viewArgumentsForView, names -> parameterArgumentsForView (instantiateBoundParameters): added and rewrote many comments * importModule.hh (EnclosingObject): update decl for instantiateBoundParameters() * instantiateModuleWithBoundParameters.cc (instantiateBoundParameters): arguments -> viewArguments (instantiateBoundParameters): parameterArgs -> parameterArguments 2019-03-20 Steven Eker * parameterization.cc (makeParameterCopy): added DebugAdvisory()s * instantiateModuleWithFreeParameters.cc (makeInstantiation): added DebugAdvisory() * instantiateModuleWithBoundParameters.cc (instantiateBoundParameters): added DebugAdvisory()s 2019-03-14 Steven Eker * view.cc (View): initialize cleanName rather than cacheName * viewCache.cc (makeViewInstantiation): cacheName -> name, name -> cleanName * importModule.hh (EnclosingObject): deleted commented out decl for instantiateSortName() * view.hh (setCacheName): becomes setCleanName() (getCacheName): becomes getCleanName() * instantiateModuleWithBoundParameters.cc (instantiateBoundParameters): use getCleanName() for the view name * moduleCache.cc (makeInstatiation): use id() rather than getCacheName() * instantiateModuleWithFreeParameters.cc (handleInstantiationByTheoryView): use getCleanName() for the view name (handleInstantiationByModuleView): use getCleanName() for the view name * viewCache.cc (makeViewInstantiation): don't put spaces in trueNames 2019-03-13 Steven Eker * moduleCache.cc (makeInstatiation): use cacheName for views as arguments in new module name 2019-03-12 Steven Eker * view.cc (makeInstantiation): save arguments for views with bound parameters (instantiateBoundParameters): handle the case where the baseView had a parameter that was bound to a view that had a bound parameter * view.hh (EnclosingObject): added decl for instantiateBoundParameters() (EnclosingObject): added data members savedViewArgs, savedParameterArgs * instantiateModuleWithBoundParameters.cc (instantiateBoundParameters): handle views with bound parameters found in instantiation of baseModule * view.cc (View): initialize baseView and cacheName (makeInstantiation): set baseView if we create a bound parameter * viewCache.cc (makeViewInstatiation): handle cacheNames (showCreatedViews): display cacheNames * view.hh (EnclosingObject): added data member cacheName (setCacheName): added (getCacheName): added 2019-03-11 Steven Eker * importModule.hh (EnclosingObject): updated decl for handleInstantiationByModuleView() * instantiateModuleWithFreeParameters.cc (handleInstantiationByModuleView): check module view to see if it has bound parameters that need be become bound parameters in the module instantiation (makeInstantiation): handle case where parameters are bound by module-view (handleInstantiationByModuleView): return bound parameters flag * view.cc (makeInstantiation): handle binding of a free parameter by a PEM (makeInstantiation): add bound parameter to copy * importModule.hh (EnclosingObject): deleted decl for mapSortFromBaseModule() * importModule.cc (mapSortFromBaseModule): deleted * view.hh (EnclosingObject): deleted decl for instantiateSortName() * view.cc (makeInstantiation): use instantiateSortName() rather than mapSortFromBaseModule() (instantiateSortName): deleted 2019-03-08 Steven Eker * viewDatabase.hh (V): updated decl for showNamedViews() * viewDatabase.cc (showNamedViews): take ostream& argument * commands.yy (command): call showViews() * interpreter.hh (ViewCache): added decl for showViews() * interpreter.cc (showViews): added 2019-03-06 Steven Eker * instantiateModuleWithFreeParameters.cc (handleParameterizedSorts): moved here * instantiateModuleWithBoundParameters.cc (instantiateBoundParameters) (instantiateRenaming): moved here * instantiateModuleWithFreeParameters.cc (makeInstantiation) (handleInstantiationByParameter) (handleInstantiationByTheoryView) (handleInstantiationByModuleView, translateComponent) (addOpMappingsFromView, handleRegularImports): moved here * parameterization.cc (handleParameterizedSorts): rewritten using instantiateSortName() * enclosingObject.cc (instantiateSortName): reimplemented and moved here * enclosingObject.hh (E): added decl for instantiateSortName() (E): moved typedefs for ParameterMap and ParameterSet here 2019-03-05 Steven Eker * view.cc (makeInstantiation): handle parameters caused by instantiation by theory-views * view.hh (EnclosingObject): added decl for ImportModule* version of addParameter() * view.cc (makeInstantiation): use mapSortFromBaseModule() (addParameter): added ImportModule* version * importModule.cc (mapSortFromBaseModule): added * importModule.hh (EnclosingObject): added decl for mapSortFromBaseModule() 2019-03-04 Steven Eker * parameterization.cc (handleInstantiationByParameter): added comments to explain sort mapping (handleInstantiationByTheoryView): added comments to explain sort mapping (handleParameterizedSorts): added comments to explain how sort mapping works 2019-03-01 Steven Eker * view.cc (handleOpTermMappings): added (instantiateSortName): added * view.hh (EnclosingObject): added decl for makeInstantiation() * viewCache.cc (makeViewInstantiation): implemented * view.cc (makeInstantiation): added * importModule.hh (EnclosingObject): made instantiateBoundParameters() public * interpreter.hh (ViewCache): added decl for handleArgument() * interpreter.cc (handleArgument): added (makeModule): use handleArgument() 2019-02-28 Steven Eker * view.cc (findParameterIndex, getParameterTheory) (getObjectType, getObjectName): added (evaluate): check for bound parameters in toModule (regretToInform): handle calls from parameter theories and clean out parameter theories * view.hh: derive from EnclosingObject (EnclosingObject): added decls for findParameterIndex(), getParameterTheory(), getObjectType(), getObjectName() * view.cc (evaluate): pass ourself as an EnclosingObject to makeModule() for fromTheory and toModule * importModule.hh (EnclosingObject): added decls for getObjectType(), getObjectName() * importModule.cc (getObjectType, getObjectName): added * interpreter.hh (ViewCache): updated decl for makeModule() * interpreter.cc (makeModule): use EnclosingObject throughout * mixfix.hh: added class EnclosingObject * importModule.hh (EnclosingObject): derive from EnclosingObject * enclosingObject.hh: created * view.cc (~View): remove self from users of our parameters; deepSelfDestruct() parameter module expressions (evaluate): evalutate parameter theories 2019-02-26 Steven Eker * syntacticView.cc (showView): handle parameters * view.hh (getNrParameters, getParameterName) (getParameterTheoryExpression): added * syntacticView.cc (addParameter2): call addParameter() 2019-02-25 Steven Eker * interpreter.hh (ViewCache): derive from ViewCache * mixfix.hh: added class ViewCache * viewCache.cc: created 2019-02-22 Steven Eker * viewCache.hh: created 2019-02-21 Steven Eker * view.hh (Renaming): added decl for addParameter() * view.cc (addParameter): added * view.hh (Renaming): added data member parameters (Renaming): added struct Parameter 2019-02-13 Steven Eker * bottom.yy: added deepSelfDestructViewExpressionVector() * top.yy: added destructor decls for , adde decl for deepSelfDestructViewExpressionVector() * interpreter.cc (makeModule): added check for view instantiation * moduleExpression.cc (deepSelfDestruct): deepSelfDestruct() view expressions * interpreter.cc (makeModule): deal with ViewExpression* * moduleExpression.cc (<<): handle instantiation arguments of type Vector * moduleExpression.hh (getArguments): now return const Vector& 2019-02-13 Steven Eker * moduleExpression.hh (M): data member arguments becomes Vector * moduleExpression.cc (ModuleExpression): now take Vector& * moduleExpression.hh (M): updated decl for instantiation ctor * modules.yy (viewExpr, instantArgs): added (argList): deleted (instantExpr): use instantArgs * top.yy: added yyViewExpression to union added types for viewExpr, instantArgs 2019-02-12 Steven Eker * top.yy: deleted stack moduleExpressions * bottom.yy: (cleanUpModuleExpression): don't handle moduleExpressions here - just currentRenaming * modules.yy (view): use new moduleExpr return value (parameter): use new moduleExpr return value (declaration): use moduleExprDot return value * top.yy: define return type for changed nonterminals * modules.yy (moduleExprDot): use parser stack for passsing ModuleExpression* (parenExpr, instantExpr, renameExpr, moduleExpr): symmetric changes * top.yy: added comment to explain the existence of stack moduleExpressions deleted a number of commented out declarations added yyModuleExpression to %union * mixfix.hh: added class ViewExpression 2019-02-11 Steven Eker * viewExpression.cc: created * viewExpression.hh: created 2019-02-05 Steven Eker * cvc4_Bindings.cc (dagToCVC4): Kind::IFF -> Kind::EQUAL to compile with latest version of CVC4 (dagToCVC4): remove special casing for BOOLEAN EQUAL ===================================Maude121=========================================== 2018-12-20 Rubén Rubio * commands.yy: added dsrewrite production * doParse.cc (parseStrategyExpr2): added * interpreter.hh (sRewrite, doStrategicSearch): added parameter (dsRewriteCont): added * lexer.ll: added dsrew/dsrewrite lexemes * maudemlBuffer.cc (generateSRewrite): added parameter srew/dsrew * maudemlBuffer.cc (generateSRewrite): added parameter srew/dsrew * mixfixModule.hh (parseStrategyExpr2): added (bufferPrint, prettyPrint): added overloads for strategy expressions, condition fragments, and vector of these * prettyPrint.cc (printStrategyTerm): replaced RawArgumentIterator by ArgumentIterator * srewrite.cc (sRewrite, doStrategicSearch): added parameter srew/dsrew (dsRewriteCont): added * syntacticView.cc (handleTermAndExprMappings): solved memory leak * top.yy: added KW_DSREWRITE token * view.cc (~View): call to clearStratExprMap (clearStratExprMap): added * view.hh (clearStratExprMap): added 2018-11-21 Steven Eker * modules.yy (parameter): use currentSyntaxContainer->addParameter2() (view): added syntax for parameterized views * renaming.hh (SyntaxContainer): added decl for addParameter2() * renaming.cc (addParameter2): added * syntacticView.hh (View): added decl for addParameter2() * syntacticView.cc (addParameter2): added * syntacticPreModule.hh (SharedTokens): added decl for addParameter2() * syntacticPreModule.cc (addParameter2): added * syntaxContainer.hh (S): added decl for addParameter2() ===================================Maude120=========================================== 2018-10-09 Steven Eker * userLevelRewritingContext.cc (tracePreRuleRewrite): add handling for dummy rewrites 2018-09-28 Steven Eker * getVariants.cc (doGetVariants): pass variableFamily argument to getNextVariant() (doGetVariants): change unused arguments to getNextVariant() into dummies to indicate we don't use these values 2018-09-25 Steven Eker * importModule.hh (User): added comment to explain why protectCount exists * importModule.cc (unprotect): add Assert() for decrementing non-positive protectCount 2018-09-19 Steven Eker * freshVariableSource.hh (FreshVariableGenerator): updated decl for variableNameConflict() * freshVariableSource.cc (variableNameConflict): take okFamily argument and don't report conflicts for variables from this family 2018-09-18 Steven Eker * freshVariableSource.cc (getFamily): don't need to call Token::unflaggedCode() since single characters will not be variable names and therefore cannot be flagged 2018-09-17 Rubén Rubio * metaSrewrite.cc (metaSRewrite): calling check properly * importModule.hh: replaced GlobalSubstitution by a vector of terms * importTranslation.cc (translateExpr): changed getStratVar by getStratVarIndices * parameterization.cc (addStratMappingFromView): changed addStratMappingVars by addStratMappingVarIndices * renaming.cc (addStratMappingVarIndices): renamed from addStratMappingVars * renaming.hh: attribute vars replaced by varsMap, a vector of indices (getStratVarIndices): renamed from getStratVars (addStratMappingVarIndices): renamed from addStratMappingVars * srewrite.cc (sRewrite): abort if check fails on the strategy * strategyTranslation.cc (instantiateExpression, instantiateCall): use variable indices instead of variable terms (instantiateCondition): use variable indices instead of terms (instantiateTerm): removed (TermCompare): removed * syntacticView.cc (handleTermAndExprMappings): solved a bug caused by a wrong literal index in an array access * view.cc (getStratMapVarIndices): renamed from getStratMapVars (insertStratToExprMapping): added a call to check on the strategy and creation of the context shape * view.hh (StratExprInfo): changed vars by contextShape (getStratMapVarIndices): renamed from getStratMapVars 2018-09-14 Rubén Rubio * maudemlBuffer.cc (generateSRewrite): added (branchAction): added (generate): added for StrategyExpression * maudemlBuffer.hh (generateSRewrite, generate): added for StrategyExpression * srewrite.cc (doStrategicSearch, sRewriteCont): add XML output generation 2018-09-13 Steven Eker * top.yy (directive): added KW_SLOAD; implmented sload * lexer.ll: added sload * lexerAux.cc (includeFile): pass const string& rhat than char* to DirectoryMangager::pushd() (includeFile): call visitFile() * global.cc (findFile): use directoryManager.getCwd() rather than "." so we always have an absolute directory path 2018-09-12 Steven Eker * lexerAux.cc (MAX_IN_DEPTH): changed to 100 ===================================Maude119=========================================== 2018-08-18 Rubén Rubio * userLevelRewritingContext.cc (traceStrategyCall): show strategy name and subject term only if trace whole is on 2018-07-27 Steven Eker * interact.cc (where): save, clear and restore ctrlC_Flag so to hande siginfo/ctrl-C interactions safely 2018-07-24 Steven Eker * userLevelRewritingContext.hh (ObjectSystemRewritingContext): added decl for printStatusReportCommon() * interact.cc (printStatusReportCommon): added (printStatusReport): use printStatusReportCommon() (handleInterrupt): check for infoFlag and produce a status report if set ===================================Maude118=========================================== 2018-07-18 Rubén Rubio * renaming.cc (addOpMappingPartialCopy): fixed a bug, lastSeenWasStrategy was not set 2018-07-17 Rubén Rubio * syntacticView.cc: when merging alpha117, changes for strategy mappings were copied from view.cc * syntacticView.hh: when merging alpha117, changes for strategy mappings were copied from view.hh 2018-07-10 Steven Eker * interpreter.hh (ViewDatabase): made beginRewriting non-static * execute.cc (beginRewriting): call setTraceStatus() if we don't call setDebug() so that we don't start with spurious traceFlag caused by SIGINFO * userLevelRewritingContext.hh (clearInfo): added * execute.cc (beginRewriting): call clearInfo() to dispose of any pending info requests * interact.cc (handleDebug): make sure we switch trace flag off if we are only here because of SIGINFO * userLevelRewritingContext.hh (ObjectSystemRewritingContext): updated decl for handleDebug() * interact.cc (handleDebug): removed constness from subject * userLevelRewritingContext.hh (ObjectSystemRewritingContext): updated decl for where(); added decl for printStatusReport() * interact.cc (printStatusReport): take ostream& (printStatusReport): added (handleDebug): call printStatusReport(); pass cout to where() * userLevelRewritingContext.hh (ObjectSystemRewritingContext): added decl for handleInterrupt() * interact.cc (handleInterrupt): added 2018-07-09 Steven Eker * interact.cc: add data member UserLevelRewritingContext::infoFlag (handleDebug): check and reset infoFlag * userLevelRewritingContext.hh (ObjectSystemRewritingContext): add static data member infoFlag; add decl for infoHandler() * interact.cc (infoHandler): added (setHandlers): install infoHandler 2018-07-03 Steven Eker * unify.cc (unify): fix a suble memory leak where we were failing to unprotect() module if the unification problem was bad 2018-06-29 Steven Eker * syntacticPreModule.hh (SharedTokens): updated decl for getAutoImports() (getAutoImports): use new convention * preModule.hh (User): updated decl for getAutoImports() 2018-06-25 Steven Eker * visibleModule.cc (VisibleModule): use new ImportModule() * importModule.hh (User): added decl for 2nd ctor * importModule.cc (ImportModule): added new version for use by VisibleModule * preModule.cc (processExplicitImports): deleted commented out code * syntacticPreModule.hh (SharedTokens): derive from SharedTokens * preModule.hh (User): don't derive from SharedTokens * mixfixModule.hh (SharedTokens): made data member moduleType const 2018-06-22 Rubén Rubio * commands.yy: added KW_SDS to traceOption * entry.cc (addStrategy): receives a Token instead of a label name and warns about redefinitions * importModule.cc (ImportModule): initialize nrStrategyFromParameters (fixUpDonatedOps): assert on the new import phase STRATS_IMPORTED (importStrategies): set nrStrategiesFromParameters (donateRuleLabels): do nothing if in STRATS_IMPORTED (donateStrategies2): consider if module is donating to theory, and addStrategy is always used instead of insertStrategy (donateStatements2): fixed an erratum * importModule.hh: new phase STRATS_IMPORTED, new data members nrStrategiesFromParameters and stratDeclaredInModule (moduleDeclared, parameterDeclared): added for RewriteStrategy (instantiateCall): added * importTranslation.cc (translateStrategy): removed const from variable type * interact.cc (handleDebug): added strategy call trace support * interpreter.hh: added TRACE_SD (for StrategyDefinition) * lexer.ll: removed sview/endsv keywords, added synonyms for enabling or disabling strategy call traces * mixfixModule.cc (closeSortSet): using isStrategic to be more succinct (findStrategy): removed const from the parameter type * mixfixModule.hh (addStrategy): receives a Token instead of a label name (findStrategy): removed const from the parameter type (isStrategic): added (canHaveAsParameter): taking strategy modules into account * modules.yy: added strategy mappings in module expressions * moduleCache.cc (makeSummation): add strategy importation * ops.cc (addOpDecl): warning about op declarations in strategy mods (addStratDecl): warning about strategy declarations in fmod/mod * parameterization.cc (addStratMappingsFromView): used moduleDeclared (makeInstantiation): changed when to promote a module to strategy module * process.cc (processStrategies): do nothing when fmod or mod, and always use addStrategy * profileModule.cc (clearProfile): clear sdInfo (profileSdConditionStart): added (profileFragment): added strategy definition case (showProfile): added strategy definition case * profileModule.hh: added data member sdInfo (profileSdConditionStart): added * renameModule.cc (finishCopy): removed unneeded curly brackets * renaming.cc (makeCanonicalName): taking strategy renamings into account (makeCanonicalVersion): taking strategy renamings into account * renaming.hh (getStratTypeSorts, discardStratMappings): added * strategyTranslation.cc (deepCopyStrategyExpression): fixed two bugs, top and the one strategy were not copied (instantiateCall): added (instantiateExpression): using instantiateCall and fixed two bugs, top and the one strategy were not instantiated * syntacticPreModule.cc (addStatement): warnings about strategy definitions in fmod/mod, and statements other than sd is smod * syntacticPreModule.hh (addSortDecl, addSubsortDecl): warning in smod * top.yy: added KW_SDS * trial.cc (traceBeginSdTrial): added * userLevelRewritingContext.cc (traceStrategyCall): added * userLevelRewritingContext.hh (traceStrategyCall, traceBeginSdTrial): added * view.cc (view, finishView): removed code for distinguishing sview (finishModule2): added label importation (checkSorts): omit strategy auxiliary symbols range sort (checkStrats): use moduleDeclared (evaluate): removed warnings about sview/endsv and added warnings and discarded strategy mappings in functional views (showView): removed sview/endsv distinction * view.hh: removed isSView data member (view, finishView): removed initial/closing keyword parameter (getStratExprMap, getNewToModule): added 2018-06-22 Steven Eker * syntacticPreModule.hh (SyntaxContainer): deleted data member owner * process.cc (processImports): use getOwner() * syntacticPreModule.cc (regretToInform): use getOwner() (finishModule): use getOwner() (3 places) (SyntacticPreModule): don't initialize owner 2018-06-20 Steven Eker * syntacticPreModule.cc (addImport): pass lineNumber to PreModule::addImport() * preModule.cc (addImport): handle lineNumber argument * preModule.hh (SharedTokens): added lineNumber field to struct Import (SharedTokens): updated decl for addImport() * command.cc (showModule): use modeStrings * syntacticPreModule.hh (SyntaxContainer): added decl for addImport * syntacticPreModule.cc (addImport): added to do Token to import mode conversion * preModule.hh (getImportMode): return ImportModule::ImportMode * preModule.cc (addImport): take mode as an ImportModule::ImportMode (processExplicitImports): don't do Token to mode conversion here * preModule.hh (SharedTokens): store import mode as a ImportModule::ImportMode rather than a token. * command.cc (showModule): use PreModule parameter and import functionality * syntacticPreModule.cc (SyntacticPreModule): don't deepSelfDestruct() module expressions * syntacticPreModule.hh (getNrImports, getImportMode, getImport) (getNrParameters, getParameterName, getParameter): deleted (SharedTokens): deleted structs Parameter, Import (SharedTokens): deleted data members parameters, imports (SharedTokens): deleted decls for addParameter(), addImport() * syntacticPreModule.cc (addParameter, addImport): deleted * process.cc (processImports): use processParameters(), processExplicitImports(); * preModule.hh (User): added decls for processParameters(), processExplicitImports() * preModule.cc (~PreModule): call deepSelfDestruct() on ModuleExpressions (addParameter, addImport): added (processParameters): added (processExplicitImports): added * preModule.hh (User): added struct members Parameter, Import (User): add data members parameters parameters, imports (getNrImports, getImportMode, getImport, getNrParameters) (getParameterName, getParameter): added (User): added decls for addParameter(), addImport() 2018-06-18 Steven Eker * mixfixModule.hh (getSymbolType): more detailed message in Assert() 2018-06-14 Steven Eker * process.cc (process): pass owner to VisibleModule() * visibleModule.cc (VisibleModule): handle owner argument * visibleModule.hh (ImportModule): take owner rather than parent argument to ctor (ImportModule): added data member owner (getOwner): added 2018-06-12 Steven Eker * process.cc (process): pass parent as null to VisibleModule() * process.cc (process): call addUser() here 2018-05-29 Steven Eker * erewrite.cc (eRewrite, eRewriteCont): use externalRewrite() 2018-05-25 Steven Eker * interpreter.hh (ViewDatabase): updated decl for doExternalRewriting() * erewrite.cc (doExternalRewriting): only call nonblocking eventLoop() if fairTraversal() makes progress (doExternalRewriting): use new fairTranversal() convention; use getProgress() (eRewriteCont): use fairRestart() (eRewriteCont): don't pass limit to doExternalRewriting() (eRewrite): don't pass limit to doExternalRewriting(); pass limit to fairStart() (doExternalRewriting): don't take or pass limit argument 2018-05-24 Steven Eker * erewrite.cc (doExternalRewriting): interleave nonblocking calls to eventLoop() with fairTraversal() 2018-05-09 Steven Eker * view.hh (Renaming): deleted struct VarDecl, struct BubblePair * view.cc (insertOpToTermMapping): added missing return true * view.hh (Renaming): added NO_COPYING macro 2018-05-08 Steven Eker * syntacticView.cc (regretToInform): deepSelfDestruct() other local module to avoid bug where the old local module eventually sends us a unexpected regretToInform() 2018-05-07 Steven Eker * syntacticView.hh (View): deleted typedef VarMap (View): deleted decls for mapSort(), indexRhsVariables() * syntacticView.cc (indexRhsVariables): deleted (handleOpTermMappings): reimplemented (mapSort): deleted * view.hh (insertOpToTermPair): deleted * syntacticView.hh (View): deleted decl for mapComponent() * syntacticView.cc (mapComponent): deleted * view.hh (Renaming): added decls for mapSort(), indexRhsVariables(), insertOpToTermMapping(); added back typedef VarMap * view.cc (mapSort, indexRhsVariables): moved back to class View 2018-05-03 Steven Eker * view.hh (Renaming): delete typedefs for VarDeclList, TypeList, OpTermList, VarMap * syntacticView.cc (regretToInform): dont deepSelfDestruct() anything * view.cc (View): don't clear newFromTheory, newFromModule (regretToInform): don't delete newFromTheory, newFromModule (View): don't delete newFromTheory, newFromModule (evaluate): set status to GOOD before calling handleOpTermMappings() * view.hh (Renaming): make mapComponent() protected (Renaming): deleted decls for handleVarDecls(), indexRhsVariables(), mapSort() (Renaming): deleted data members varDecls, varDefs, opTermList, newFromTheory, newFromModule * interpreter.cc (setCurrentView): downcast to SyntacticView* * mixfix.hh: added class SyntacticView * interpreter.hh (ViewDatabase): use SyntacticView * modules.yy (view): use SyntacticView * view.cc (addVarDecl): deleted (addType): deleted (addOpTermMapping): deleted (mapSort): deleted (finishModule): deleted (handleVarDecls): deleted (indexRhsVariables): deleted (handleOpTermMappings): deleted (showView): deleted * view.hh (Renaming): made regretToInform() protected rather than private (Renaming): make handleOpTermMappings virtual and protected (Renaming): deleted decls for addOpTermMapping(), addVarDecl(), addType() * syntacticView.cc (handleOpTermMappings): use insertOpToTermPair() * view.hh (insertOpToTermPair): added 2018-05-02 Steven Eker * syntacticView.hh: created * syntacticView.cc: created * renaming.cc (renameOp): added comments to distinguish the two versions of this member function 2018-05-01 Steven Eker * view.hh (Renaming): added comment about the metalevel 2018-04-30 Steven Eker * interpreter.cc (showView): call View::evaluate() * view.hh (Renaming): delete decls for finishModule1(), finishModule2(); add decl for finishModule() (finishView): moved here * view.cc (finishModule1, finishModule2): merged into finishModule() (handleOpTermMappings): use finishModule() 2018-04-27 Steven Eker * view.cc (handleOpTermMappings): finish processing newFromTheory before we start processing newToModule to avoid messing up the import phase counter on common imports (handleVarDecls): added comment * renameModule.cc (localStatementsComplete): added comments to explain obscure code * entity.cc (informUsers): added comments to explain obscure code 2018-04-25 Steven Eker * process.cc (processImports): use owner rather than global interpreter * modules.yy (module): pass interpreter to SyntacticModule ctor * syntacticPreModule.hh (SharedTokens): updated decl for ctor (SharedTokens): added owner data member * syntacticPreModule.cc (SyntacticPreModule): take owner argument and remove hack (regretToInform, finishModule): use owner rather than global interpreter * modules.yy (view): pass interpreter to View ctor * view.cc (View): take owner argument (evaluate): use owner rather than global interpreter * view.hh (Renaming): updated decl for ctor; added data member owner 2018-04-24 Steven Eker * renameModule.cc (donateOps2): added Asserts() to see if bug mentioned in comment actually happens 2018-04-20 Steven Eker * modules.yy (viewDecList, skipStrayArrow, parameters, decList) (skipStrayColon, typeList, attributes, identity, sortNameList): provide empty action for empty rhs syntax to avoid default action generating an uninitialized memory read (hookList): provide empty actions 2018-04-18 Steven Eker * banner.cc (printBanner): update copyright year 2018-04-04 Steven Eker * mixfixParser.cc (insertProduction): use productionRhs in place of static rhs2 * mixfixParser.hh (M): added data member productionRhs 2018-03-27 Steven Eker * mixfixParser.cc (ROOT_NODE): removed MSCP10 #define (parseSentence): removed MSCP10 specific code (makeTerms): removed MSCP10 specific code * mixfixParser.hh: removed include for MSCP10 ===================================Maude117=========================================== 2018-04-10 Rubén Rubio * makeGrammar.cc (makeStrategyProduction): added production for one * mixfixParser.cc (makeStrategy): added MAKE_ONE case * mixfixParser.hh: added MAKE_ONE to SemanticActions * specialTokens.cc: added one token * strategyPrint.cc: added 'one' strategy printing 2018-04-06 Rubén Rubio * doParser.cc (parseStrategyExpr): added * importModule.cc (importStrategies, donateStrategies) (donateStrategies2): use Renaming instead of ImportTranslation * importModule.hh: new types GlobalSubstitution (and TermCompare as its comparator) (deepCopyStrategyExpression): now is public (addStratMappingsFromView, instantiateCondition, instantiateExpression) (instantiateTerm, donateRuleLabels): added (donateStrategies2): use Renaming instead of ImportTranslation * importTranslation.cc (translate): for RewriteStrategy, use translateStrategy (translateStrategy): added, taking renamings into account (translateExpr, donateRuleLabels): added * importTranslation.hh (translateExpr, translateStrategy): added * lexer.ll: added KW_EXPR for strat->expr mapping in views. * mixfixModule.hh (parseStrategyExpr): added * mixfixParser.cc (makeStrategyExprs): added * mixfixParser.hh (makeStrategyExprs): added * modules.yy: added syntax for strategy views, using identifier instead of IDENTIFIER for strategy identifiers. * parameterization.cc (addStratMappingsFromView): added (handleInstantiationByModuleView) (handleInstantiationByTheoryView): call addStratMappingsFromView * renameModule.cc (finishCopy): call donateStrategies2 with the Renaming * renaming.cc (typeMatch): added for RewriteStrategy (renameStrat, addStratMapping, addStratTarget, addStratMappingVArs) (addOpMapping): update lastSeenWasStrategy (addStratTargetExpr): added (addType): use lastSeenWasStrategy to know where to add the type (printRenamingType): print strategy renamings types also (printRenaming): print strategy renamings also * renaming.hh: added data members to store strategy renamings and lastSeenWasStrategy (addStratMapping, addStratMappingVars, addStratTarget) (addStratTargetExpr, getNrStratMappings, getStratFrom, getNrStratTypes) (getStratTo, getStratTargetExpr, getStratVars, renameStrat) (typeMatch): added (printRenamingType): receives the sort set directly * strategyTranslation.cc (deepCopyStrategyExpression): support for strat->expr mappings (instantiateExpression, instantiateTerm, instantiateCondition): added (TermCompare::operator()): added * top.yy: added vector strategyCall for strategy call parsing in views and KW_EXPR as token * view.cc: (addStratExprMapping, checkStrats, getStratMapExpr) (getStratMapVars, typeMatch): added (checkSort): skip strategy range sort check (evaluate): in case of a strategy view, check if from is of strategy (finishView): added end token as parameter (handleOpTermMappings): renamed to handleTermAndExprMappings (handleTermAndExprMappings): completion of handleOpTermMappings with support for strat->expr mappings (showView): print strategy views (View): added start token as parameter to decide if it is a sview * view.hh: added support for strategy views. New types StratExprInfo, StratExprMap, StratExprList and data members stratExprList, stratExprMap and isSView. (addStratExprMapping, checkStrats, getStratMapExpr, getStratMapVars) (typeMatch): added (finishView): added end token as parameter (handleOpTermMappings): renamed to handleTermAndExprMappings (handleTermAndExprMappings): added (View): added start token as parameter to decide if it is a sview 2018-03-23 Rubén Rubio * command.cc (printStratDecl): added (showModule): added strategy declaration printing * cvc4_Bindings.cc (dagToCVC4): deleted the distinction in the SMT_Symbol::EQUALS case as not needed * doParse.cc (parseStatement): include strategy productions when parsing strategy definitions (parseStrategyExpr): added * entry.cc (addStrategy): added * importModule.cc: included strategy language headers (importStrategies, importLabels, donateStrategies, donateStrategies2): added (donateStatements2): import strategy definitions * importModule.hh: added new data members nrImportedStrategies and nrOriginalStrategyDefinitions (importStrategies, importLabels, getNrImportedStrategies) (getNrOriginalStrategyDefinitions, deepCopyStrategyExpression) (donateStrategies, donateStrategies2): added * importTranslation.cc (translate): added for RewriteStrategy (splitTranslation, translateExpr, translateStrategy): added (translateTerm): common code with translateExpr moved to splitTranslation * importTranslation.hh (translate): added for RewriteStrategy (splitTranslation, translateExpr, translateStrategy): added * interpreter.cc (~Interpreter): clear continue info no avoid memory leak * lexerAux.cc: added BAR_ASSIGN to TERMINATION_TOKENS (for strategy definitions) * lexer.ll: added sth/sview/endsth/endsv and sd/csd keywords. KW_STRAT is split in 3 variants: KW_STRAT is "strat" and can be either an attribute name or a strategy declaration keyword. KW_DSTRAT is "strats" only for declaration and KW_ASTRAT is "strategy" only for the attribute. Added := as KW_ASSIGN. * makeGrammar.cc (makeStrategyLanguageProductions): changes in how rule productions are generated (see TODO), a grammar production is added for each strategy declaration. New grammar rules for calls and matchrew (makeStatementProductions): new grammar rules for strategy definitions * metadataStore.hh: added STRAT_DEFINITION to ItemType enumeration * mixfixModule.cc (moduleTypeString, moduleEndString): added strategy module types (closeSortSet): added. Creates a universal type for strategies' auxiliary symbol range when in a strategy module (findStrategy): added * mixfixModule.hh: added strategy ModuleTypes and STRATEGY in Bits (closeSortSet, addStrategy, findStrategy, parseStrategyExpr): added (ruleLabels): new data member for early rule label importation (insertPotentialLabels): ruleLabels are added (addImport): comment on strategy modules importation * mixfixParser.cc (makeStrategy): added MAKE_CALL and MAKE_REW cases (makeStrategyCall): added (makeStatementPart): added MAKE_CS and MAKE_CSD cases * mixfixParser.hh: added MAKE_ enumerators for new strategy syntax (makeStrategyCall): added * modules.yy: added syntax for strategy definitions * ops.cc (addStratDecl): added (addVarDecl, addOpDecl): set isStrategy to false (addType, setMetadata): changes so that they also work for strategies * prettyPrint.cc: operator<< for RewriteStrategy and StrategyDefinition (printStrategyTerm): added * process.cc (process): strategy importation and processing (checkOpTypes): check strategy types also (computeStrategyTypes, processStrategies): added * renameModule.cc (finishCopy): copy strategies and rule labels (localStatementsComplete): set nrOriginalStrategyDefinitions * specialTokens.cc: added sd, csd, sth and endsth * srewrite.cc (sRewrite): the strategy expression is checked and processed * strategyPrint.cc (prettyPrint): call strategy printing * strategyTranslation.cc: added * syntacticPreModule.cc (SyntacticPreModule, compatible): consider strategy module and theory types (addParameter): an erratum was corrected (addStatement): do not allow neither rules in strategy modules nor strategy definition in other modules * syntacticPreModule.hh: added data members isStrategy, stratDecls and StratDecl type (addStratDecl, printStratDecl, computeStrategyTypes) (processStrategies): added * top.yy: added keyword KW_ASTRAT, KW_DSTRAT (see lexer.ll). Added KW_ASSIGN for strategy definitions. * visibleModule.cc (showStrats): added (showModule): added showStrats call * visibleModule.hh (showStrats): added 2018-03-09 Steven Eker * mixfixParser.cc (makeTerms): Assert() that we actually found a second parse 2018-03-02 Steven Eker * mixfixParser.cc (makeTerm): fix pathological case where pos ends up outside of the sentence 2018-02-16 Steven Eker * makeGrammar.cc (makeComponentProductions): don't make COLON2_PAIR productions for bubble components 2017-12-21 Steven Eker * mixfixParser.cc (parseSentence): use getErrorPosition() 2017-10-05 Steven Eker * makeGrammar.cc (makeStrategyLanguageProductions): give ?: the gather (e & E) * mixfixModule.hh (SharedTokens): STRAT_BRANCH_PREC from 101 to 55 2017-10-03 Steven Eker * strategyPrint.cc (prettyPrint): pass STRAT_USING_PREC - 1 for substrategies (prettyPrint): add () around test and subterm cases if needed * makeGrammar.cc (makeStrategyLanguageProductions): require strategy argument of using in matchrew be tightly bound * mixfixModule.hh (SharedTokens): STRAT_USING_PREC from 105 to 21, STRAT_USING_LIST_PREC from 105 to 61, STRAT_REW_PREC from 93 to 21 * makeGrammar.cc (makeStrategyLanguageProductions): use gatherAny4 for subterm strategy syntax * mixfixModule.cc: added gatherAny4 (MixfixModule): initialize gatherAny4 * mixfixModule.hh (SharedTokens): added static date member gatherAny4 2017-10-02 Steven Eker * makeGrammar.cc (makeStrategyLanguageProductions): make all test strategy nonterminals have gather ANY * mixfixModule.hh (SharedTokens): STRAT_SEQ_PREC from 95 to 39, STRAT_UNION_PREC form 97 to 41, STRAT_ORELSE_PREC from 99 to 43 (SharedTokens): STRAT_TEST_PREC from 93 to 21 * makeGrammar.cc (makeStrategyLanguageProductions): use INFIX_PREC, gatherAnyAny for strategy lists * mixfixModule.hh (SharedTokens): added STRAT_BASIC_PREC * makeGrammar.cc (makeStrategyLanguageProductions): use STRAT_BASIC_PREC for basic strategies 2017-09-28 Steven Eker * strategyPrint.cc (prettyPrint): hanlde SubtermStrategy case * mixfixParser.cc (makeStrategy): use SubtermStrategy() 2017-09-26 Steven Eker * makeGrammar.cc (makeStrategyLanguageProductions): use MAKE_USING_PAIR and MAKE_USING_LIST actions (makeStrategyLanguageProductions): use PASS_THRU for USING_LIST * mixfixParser.hh (M): added MAKE_USING_PAIR, MAKE_USING_LIST to enum SemanticActions (M): added decls for appendUsingPair(), makeUsingList() * mixfixParser.cc (appendUsingPair, makeUsingList): added (makeStrategy): added dummy MAKE_REW case * mixfixParser.hh (M): added MAKE_REW to enum SemanticActions 2017-09-18 Steven Eker * mixfixModule.hh (SharedTokens): added nonterminal USING_PAIR (SharedTokens): added STRAT_REW_PREC * makeGrammar.cc (makeStrategyLanguageProductions): added syntax for using pairs and lists * specialTokens.cc: added by * makeGrammar.cc (makeStrategyLanguageProductions): added syntax for matchrew/xmatchrew/amatchrew strategies * mixfixModule.hh (SharedTokens): added STRAT_USING_LIST_PREC, STRAT_USING_PREC (SharedTokens): added USING_LIST nonterminal 2017-09-15 Steven Eker * specialTokens.cc: added matchrew, xmatchrew, amatchrew * makeGrammar.cc (makeStrategyLanguageProductions): remove the #if 1 / #endif around the match/xmatch/amatch productions ===================================Maude116=========================================== 2017-08-11 Steven Eker * tokenizer.ll (Rope): use fixUp() (Rope): don't allow \t in strings * token.hh (T): added decl for static version of fixUp() * token.cc (fixUp): added static version * tokenizer.ll (Rope): use endOfRope flag (Rope): use EOT character to indicate endOfRope and avoid flex EOF handling * quotedIdentifierOpSymbol.cc (eqRewrite): use builtInReplace() in the empty and singleton tokenize() cases 2017-08-10 Steven Eker * tokenizer.ll: created * quotedIdentifierOpSymbol.hh (FreeSymbol): added decl for makeQid() * quotedIdentifierOpSymbol.cc (eqRewrite): implement tokenize() (makeQid): added 2017-08-08 Steven Eker * quotedIdentifierOpSymbol.cc (printQid): new needSpace rule (printQid): handle '\c Qids specially 2017-08-07 Steven Eker * quotedIdentifierOpSymbol.cc (eqRewrite): implemented print() case * quotedIdentifierOpSymbol.hh (FreeSymbol): added decl for printQidList(), printQid() * quotedIdentifierOpSymbol.cc (printQid): added (printQidList): added 2017-08-04 Steven Eker * quotedIdentifierOpSymbol.hh (FreeSymbol): use quotedIdentifierOpSignature.cc * quotedIdentifierOpSymbol.cc (QuotedIdentifierOpSymbol) (copyAttachments, getSymbolAttachments, attachSymbol): use quotedIdentifierOpSignature.cc (getDataAttachments): added cases for print and tokenize * quotedIdentifierOpSignature.cc: created 2017-07-31 Steven Eker * lexerAux.cc (getInput): added comments 2017-07-28 Steven Eker * entry.cc (newFancySymbol): added SymbolType::STREAM_MANAGER_SYMBOL case * symbolType.hh (S): added STREAM_MANAGER_SYMBOL * specialSymbolTypes.cc: added streamManagerSymbol 2017-07-24 Steven Eker * variableGenerator.cc (push, pop, clearAssertions): added stub versions to allow linking without SMT support 2017-07-19 Steven Eker * symbolType.hh (S): added FILE_MANAGER_SYMBOL * entry.cc (newFancySymbol): add SymbolType::FILE_MANAGER_SYMBOL case * specialSymbolTypes.cc: added fileManagerSymbol * command.cc (printAttributes): only print hook details if nonempty ===================================Maude115=========================================== 2017-07-11 Steven Eker * search.cc (checkSearchRestrictions): check for SMT operators in pattern * mixfixModule.hh (SharedTokens): added decl for new findNonlinearVariable() (SharedTokens): made findSMT_Symbol() public * search.cc (search): don't make Pattern for smt-search (checkSearchRestrictions): moved nonlinear variable check here * mixfixModule.cc (findNonlinearVariable): added variableInfo version * search.cc (search): check for nonlinear variables in pattern in smt-search case * mixfixModule.cc (validForSMT_Rewriting): added line number info to warnings 2017-07-10 Steven Eker * mixfixModule.cc (MixfixModule): initialize smtStatus (validForSMT_Rewriting): check and set smtStatus * mixfixModule.hh (SharedTokens): added enum SMT_Status and data member smtStatus 2017-07-07 Steven Eker * search.cc (checkSearchRestrictions): issue warning if validForSMT_Rewriting() returns false * mixfixModule.cc (validForSMT_Rewriting): add line number to error messages * mixfixModule.hh (SharedTokens): added decl for findNonlinearVariable() * mixfixModule.cc (findNonlinearVariable): added (validForSMT_Rewriting): check for nonlinear variables in lhs * mixfixModule.hh (SharedTokens): containsSMT_Symbol() -> findSMT_Symbol() * mixfixModule.cc (containsSMT_Symbol): becomes findSMT_Symbol() (validForSMT_Rewriting): use findSMT_Symbol() * mixfixModule.hh (SharedTokens): added decl for containsSMT_Symbol() * mixfixModule.cc (containsSMT_Symbol): added (validForSMT_Rewriting): check for SMT symbols occurring in the lhs of a rule 2017-07-06 Steven Eker * mixfixModule.cc (validForSMT_Rewriting): added check for non-SMT operators have SMT sorts as their range 2017-06-30 Steven Eker * mixfixModule.cc (validForSMT_Rewriting): check for regular symbols and polymorphic operators that have a collapse axiom * symbolType.hh (S): added COLLAPSE 2017-06-28 Steven Eker * yices2_Bindings.cc (checkDag): check for error from yices_assert_formula() (checkDag): treat all return values other than STATUS_SAT and STATUS_UNSAT as SAT_UNKNOWN (assertDag): symmetric changes (dagToYices2): enforce 2nd argument of divisible to be positive constant 2017-06-27 Steven Eker * cvc4_Bindings.cc (dagToCVC4): check for non-positive 2nd arguments to divisible (checkDag): catch CVC4::LogicException (assertDag): catch CVC4::LogicException (assertDag): don't both passing an argument to checkSat() 2017-06-26 Steven Eker * cvc4_Bindings.cc (dagToCVC4): fix bug where DIVISIBLE case could fall through * yices2_Bindings.cc (dagToYices2): flipped argument order to yices_divides_atom() 2017-06-23 Steven Eker * yices2_Bindings.hh (SMT_EngineWrapper): delet decl for makeRationalConstant() * yices2_Bindings.cc (makeRationalConstant): fold into dagToYices2() 2017-06-20 Steven Eker * yices2_Bindings.cc (dagToYices2): implemented 2017-06-16 Steven Eker * yices2_Bindings.cc (makeVariable): implemented (makeBooleanExpr): implemented 2017-06-15 Steven Eker * yices2_Bindings.cc: created * yices2_Bindings.hh: created 2017-06-14 Steven Eker * cvc4_Bindings.hh: created to hold CVC4 specific code * variableGenerator.hh (SMT_EngineWrapper): stripped out all CVC4 specific code * cvc4_Bindings.cc: created to hold CVC4 specific code * variableGenerator.cc: stripped out all CVC4 specific code 2017-06-13 Steven Eker * prettyPrint.cc (printAttributes): fix bug where we weren't printing the narrowing attribute if it was the only attribute 2017-06-12 Steven Eker * mixfixModule.cc (checkFreshVariableNames): implemented * mixfixModule.hh (SharedTokens): added decl for checkFreshVariableNames() * syntacticPreModule.cc (getFlatModule): call checkFreshVariableNames() * mixfixModule.cc (checkFreshVariableNames): added stub * freshVariableSource.cc (variableNameConflict): need to consider @ variables 2017-06-09 Steven Eker * bufferPrint.cc (handleIter): use decideIteratedAmbiguity() to decide needToDisambiguate and argumentRangeKnown * dagNodePrint.cc (handleIter): use decideIteratedAmbiguity() to decide needToDisambiguate and argumentRangeKnown * entry.cc (checkPseudoIterated): rewritten using iteratedMap * termPrint.cc (handleIter): don't pass iflags argument to decideIteratedAmbiguity() * mixfixModule.hh (SharedTokens): updated decl for decideIteratedAmbiguity() * sharedPrint.cc (decideIteratedAmbiguity): use iteratedMap (decideIteratedAmbiguity): delete iflags argument * entry.cc (checkIterated): fill out iteratedMap * mixfixModule.hh (SharedTokens): added typedef IteratedMap and data member iteratedMap 2017-06-08 Steven Eker * termPrint.cc (handleIter): use decideIteratedAmbiguity() to do disambiguation properly * mixfixModule.hh (SharedTokens): added decl for decideIteratedAmbiguity() * sharedPrint.cc (decideIteratedAmbiguity): added * entry.cc (checkPseudoIterated, checkIterated): more detailed warnings 2017-06-07 Steven Eker * entry.cc (checkIterated): implemented (addOpDeclaration): call checkIterated() * mixfixModule.hh (SharedTokens): added decl for checkIterated() * entry.cc (checkPseudoIterated): fill out pseudoIteratedMap (checkIterated): added stub * mixfixModule.hh (SharedTokens): checkPseudoIterator() -> checkPseudoIterated() (SharedTokens): added typedefs NumberToSymbolMap, PseudoIteratedMap and data member pseudoIteratedMap * entry.cc (addOpDeclaration): updated calling convention for checkPseudoIterator() again (checkPseudoIterator): becomes checkPseudoIterated() (addOpDeclaration): use checkPseudoIterated() * mixfixModule.hh (SharedTokens): updated decl for checkPseudoIterator() * entry.cc (addOpDeclaration): updated calling convention for checkPseudoIterator() (checkPseudoIterator): replace with Symbol* base version * token.hh (T): updated decl for checkPseudoIterator() * entry.cc (checkPseudoIterator): implemented 2017-06-06 Steven Eker * mixfixModule.hh (SharedTokens): added decl for checkPseudoIterator() * entry.cc (addOpDeclaration): added call to checkPseudoIterator() (checkPseudoIterator): added stub 2017-06-05 Steven Eker * symbolType.hh (hasAtLeastOneFlag): added 2017-05-31 Steven Eker * ops.cc (setPoly): check for duplicate arg numbers in poly attribute ===================================Maude114=========================================== 2017-05-26 Steven Eker * execute.cc (clearContinueInfo): deleted commented out code 2017-05-19 Steven Eker * narrowing.cc (doVuNarrowing): reorganize printing (doVuNarrowing): fix double delete bug * search.cc (search): combine vu-narrow and fvu-narrow code * interpreter.hh (ViewDatabase): deleted decl for doFvuNarrowing(); updated decl for doVuNarrowing() * narrowing.cc (doFvuNarrowing): support continuation (doVuNarrowing): deleted (doFvuNarrowing): becomes doVuNarrow() (vuNarrowingCont): use NarrowingSequenceSearch3 2017-05-12 Steven Eker * narrowing.cc (doFvuNarrowing): print accumulated substitution * userLevelRewritingContext.hh (ObjectSystemRewritingContext): added decl for new printSubstitution() * userLevelRewritingContext.cc (printSubstitution): added Substitution&/VariableInfo& version * lexer.ll: added fvu-narrow * top.yy: added KW_FVU_NARROW * commands.yy (search): added fvu-narrow support * interpreter.hh (ViewDatabase): added decl for doFvuNarrowing() * narrowing.cc (doFvuNarrowing): added * search.cc (checkSearchRestrictions): support fvu-narrow (search): fvu-narrow * interpreter.hh (ViewDatabase): added FVU_NARROW to SearchKind 2017-04-26 Steven Eker * specialTokens.cc: added narrowing * makeGrammar.cc (makeAttributeProductions): added narrowing attribute * mixfixParser.hh (M): added MAKE_NARROWING_ATTRIBUTE to enum SemanticActions * mixfixParser.cc (makeAttributePart): added case for MAKE_NARROWING_ATTRIBUTE * mixfixParser.hh (M): added NARROWING to enum Flags * prettyPrint.cc (printAttributes): support narrowing attribute * mixfixParser.cc (makeStatementPart): handle narrowing flag * importModule.cc (donateStatements2): copy narrowing flag ===================================Maude113=========================================== 2017-04-13 Steven Eker * interpreter.cc (Interpreter): don't initialize savedContext * loopMode.cc (doLoop): use CacheableRewritingContext and savedState (contLoop2): use CacheableRewritingContext and savedState * interpreter.hh (ViewDatabase): deleted data member savedContext (ViewDatabase): updated decl for endRewriting() * erewrite.cc (eRewrite): use CacheableRewritingContext (eRewriteCont): use CacheableRewritingContext and savedState * execute.cc (endRewriting): make context argument CacheableRewritingContext; use savedState (reduce): use CacheableRewritingContext (rewrite, fRewrite): use CacheableRewritingContext (fRewriteCont, rewriteCont): use CacheableRewritingContext, savedState (clearContinueInfo): don't delete or clear savedContext * mixfix.hh: added class CacheableRewritingContext 2017-04-11 Steven Eker * search.cc (search): deleted #if 0'd out code 2017-04-06 Steven Eker * narrowing.cc (vuNarrowingCont, narrowingCont): support debug 2017-04-04 Steven Eker * smtSearch.cc (doSmtSearch): print state and timing info; print no more solutions message 2017-04-03 Steven Eker * search.cc (search): use doSmtSearch() * interpreter.hh (ViewDatabase): added decls for doSmtSearch(), smtSearchCont() * smtSearch.cc: created * interpreter.hh (ViewDatabase): deleted data member savedRewriteSequenceSearch * execute.cc (clearContinueInfo): don't delete or clear savedRewriteSequenceSearch * interpreter.cc (Interpreter): don't clear savedRewriteSequenceSearch * search.cc (showSearchGraph): use dynmaic_cast on savedState (showSearchPath, showSearchPathLabels): use dynmaic_cast on savedState (doSearching): use savedState (searchCont): use savedState 2017-03-31 Steven Eker * search.cc (searchCont): support debug * interpreter.hh (ViewDatabase): updated decl for doSearching() * search.cc (search): use QUANTIFY_START() (doSearching): make solutionCount and limit 64-bit; use QUANTIFY_STOP() (doSearching): restructured (doSearching): don't call interrupted() (searchCont): use QUANTIFY_START() * interpreter.hh (ViewDatabase): added decl for checkSearchRestrictions() * search.cc (search): destruct initial term and condition if we are asked to narrow with a non-empty condition (checkSearchRestrictions): added (search): use checkSearchRestrictions() (search): deepSelfDestruct() target if we fail checks * interpreter.hh (ViewDatabase): updatede decl for search() * search.cc (search): take debug argument * commands.yy (command): added optDebug to search * execute.cc (clearContinueInfo): don't delete and clear savedStrategicSearch * interpreter.cc (Interpreter): don't clear savedStrategicSearch * interpreter.hh (ViewDatabase): updated decl for doStrategicSearch(); deleted data member savedStrategicSearch * srewrite.cc (sRewrite): support debug flag (doStrategicSearch): make solutionCount and limit 64-bit; restructured; use savedState (sRewriteCont): use savedState; support debug flag * getVariants.cc (doGetVariants): check interrupted() in the irredundant case (getVariants): QUANTIFY_START() (getVariantsCont): QUANTIFY_START() (doGetVariants): use QUANTIFY_STOP(); * narrowing.cc (doNarrowing): use QUANTIFY_STOP() (narrowingCont): use QUANTIFY_START() (doVuNarrowing): use QUANTIFY_STOP() (vuNarrowingCont): use QUANTIFY_START() * match.cc (match): use QUANTIFY_START() (doMatching): use QUANTIFY_STOP() (matchCont): use use QUANTIFY_START() (doMatching): updated comments * mixfix.hh: added QUANTIFY_START(), QUANTIFY_STOP() 2017-03-30 Steven Eker * interpreter.hh (ViewDatabase): make savedSolutionCount an Int64 * getVariants.cc (doGetVariants): make solutionCount and limit 64-bit * interpreter.hh (ViewDatabase): update decls for doNarrowing(), doVuNarrowing(), doGetVariants(), doVariantUnification() * narrowing.cc (doNarrowing, doVuNarrowing): make solutionCount and limit 64-bit * variantUnify.cc (variantUnify): echo debug flag (doVariantUnification): make solutionCount and limit 64-bit * getVariants.cc (getVariants): echo debug flag * interpreter.hh (ViewDatabase): added decls for getVariantsCont() and doGetVariants() * getVariants.cc (doGetVariants): added (getVariantsCont): added (getVariants): use doGetVariants() * variantUnify.cc (doVariantUnification): restructured; use aborted() (variantUnifyCont): handle debug flag 2017-03-29 Steven Eker * narrowing.cc (doNarrowing): don't call interrupted(); tidy up after abort or solution exhaustion (doVuNarrowing): don't call interrupted(); tidy up after abort or solution exhaustion * getVariants.cc: renamed from variants.cc * variantUnify.cc (variantUnify, doVariantUnification) (variantUnifyCont): moved here * interpreter.hh (ViewDatabase): added decls for doVariantUnification() and variantUnifyCont() (ViewDatabase): deleted decl for newNarrow() * variants.cc (doVariantUnification): added (variantUnifyCont): added * search.cc (newNarrow): deleted * variants.cc (getVariants, variantUnify): moved here * narrowing.cc (doNarrowing): check for incompleteness (doNarrowing): call printStats() 2017-03-28 Steven Eker * userLevelRewritingContext.cc (traceVariantNarrowingStep): use narrowing version of printSubstitution() * interpreter.hh (ViewDatabase): added decl for narrowingCont() * userLevelRewritingContext.hh (ObjectSystemRewritingContext): added decl for narrowing version of printSubstitution() * narrowing.cc (doVuNarrowing): use narrowing version of printSubstitution() * userLevelRewritingContext.cc (printSubstitution): added narrowing version * unify.cc: fixed comment since we not longer support xunify * narrowing.cc (narrowingCont): added (doNarrowing): added continue support * cacheableRewritingContext.hh: created * userLevelRewritingContext.hh (ObjectSystemRewritingContext): made complex ctor private 2017-03-24 Steven Eker * execute.cc (clearContinueInfo): don't delete and clear savedUnificationProblem * interpreter.cc (Interpreter): don't clear savedUnificationProblem * interpreter.hh (ViewDatabase): delete data member savedUnificationProblem * unify.cc (unifyCont): use savedState (doUnification): use savedState * execute.cc (clearContinueInfo): don't delete and clear savedMatchSearchState * interpreter.cc (Interpreter): don't clear savedMatchSearchState * interpreter.hh (ViewDatabase): delete data member savedMatchSearchState * match.cc (matchCont): use savedState (doMatching): use savedState * execute.cc (clearContinueInfo): delete and clear savedState * interpreter.cc (Interpreter): clear savedState * interpreter.hh (ViewDatabase): added data member savedState * narrowing.cc (vuNarrowingCont): use savedState (doVuNarrowing): use savedState 2017-03-23 Steven Eker * narrowing.cc (vuNarrowingCont): added (doVuNarrowing): support continuation * interpreter.hh (ViewDatabase): added decl for vuNarrowingCont() * search.cc (search): doNarrowing2() -> doVuNarrowing() * interpreter.hh (ViewDatabase): doNarrowing2() -> doVuNarrowing() * narrowing.cc: created (doNarrowing2): moved here (doNarrowing): moved here (doNarrowing2): becomes doVuNarrowing() ===================================Maude112a=========================================== 2017-03-13 Steven Eker * process.cc (processImports): don't add illegal parameters, since even the creation of the illegal parameter copies can cause issues 2017-03-10 Steven Eker * search.cc (doNarrowing2): added incompleteness warning; took out extra newline print 2017-02-28 Steven Eker * search.cc (doNarrowing2): added (search): use doNarrowing2() to implement vu-narrow * interpreter.hh (ViewDatabase): added decl for doNarrowing2() 2017-02-27 Steven Eker * search.cc (search): added stub code for vu-narrow 2017-02-24 Steven Eker * interpreter.hh (ViewDatabase): added VU_NARROW to enum SearchKind * commands.yy (search): added KW_VU_NARROW to search * lexer.ll: added keyword vu-narrow * top.yy: added token KW_VU_NARROW ===================================Maude111b=========================================== 2017-01-06 Steven Eker * banner.cc (printBanner): fix copyright year ===================================Maude111a=========================================== 2016-12-15 Steven Eker * freshVariableSource.hh (FreshVariableGenerator): added decl for belongsToFamily() * freshVariableSource.cc (belongsToFamily): added 2016-12-08 Steven Eker * freshVariableSource.hh (FreshVariableGenerator): added decl for getFamily() * freshVariableSource.cc (getFamily): added 2016-12-07 Steven Eker * freshVariableSource.cc (getBaseName): added * freshVariableSource.hh (FreshVariableGenerator): added decl for getBaseName() 2016-11-01 Steven Eker * search.cc (variantUnify): pass dummy argument to getNextUnifier() 2016-10-28 Steven Eker * doParse.cc (parseTerm): fix bug where we were calling fillInSortInfo() before the module was semi-compiled and sort diagrams had been generated 2016-10-26 Steven Eker * freshVariableSource.cc (getFreshVariableName): rewritten to handle multiple families of fresh variables * freshVariableSource.hh (FreshVariableGenerator): updated decl for getFreshVariableName() (FreshVariableGenerator): deleted data members cache, oddCache; added data member caches ===================================Maude111=========================================== 2016-06-27 Steven Eker * banner.cc (printBanner): update copyright year ===================================Maude110b=========================================== 2016-05-17 Steven Eker * execute.cc (check): use normalize() and markEager() on term before dagifying it. (check): don't bother with markEager() 2016-04-27 Steven Eker * userLevelRewritingContext.cc (checkForPrintAttribute): use printAttrStream added definition for printAttrStream * userLevelRewritingContext.hh (ObjectSystemRewritingContext): added decl for data member printAttrStream (setPrintAttributeStream): added ===================================Maude110=========================================== 2016-02-04 Steven Eker * search.cc (getVariants): use new getNextVariant() interface ===================================Maude109=========================================== 2015-12-23 Steven Eker * token.cc (codeToRope): += rather than append() * auxProperty.cc: crope -> Rope throughout * moduleCache.cc (makeRenamedCopy, makeParameterCopy) (makeInstatiation, makeSummation): use Token::ropeToCode() * token.hh (T): added decl for ropeToCode() * token.cc (ropeToCode): added * renaming.hh: include "rope.hh" rather than "ropeStuff.hh" * moduleCache.cc: crope -> Rope throughout * renaming.hh: crope -> Rope throughout * renaming.cc: crope -> Rope throughout * token.cc: crope -> Rope throughout * token.hh: crope -> Rope throughout ===================================Maude108a=========================================== 2015-09-11 Steven Eker * prettyPrint.cc (<<): handle null DagNode* gracefully 2015-08-21 Steven Eker * bottom.yy: yyerror() now takes 2 args * top.yy: #define YYPARSE_PARAM removed; %parse-param added; PARSE_RESULT no longer needs a cast; yyerror() decl now takes 2 args * interact.cc: yyparse() now takes UserLevelRewritingContext::ParseResult* in decl * top.yy: %pure_parser becomes %pure-parser 2015-08-20 Steven Eker * variableGenerator.cc: respect USE_CVC4 flag * variableGenerator.hh: respect USE_CVC4 flag 2015-08-13 Steven Eker * search.cc (variantUnify): check for incompleteness (getVariants): check for incompleteness 2015-07-23 Steven Eker * unify.cc (doUnification): check for incompleteness ===================================Maude108=========================================== 2014-11-20 Steven Eker * parameterization.cc (handleRegularImports): added DebugAdvisory() for handling import of parameterized module during instantiation * renaming.cc (makeCanonicalVersion): added DebugAdvisory() for empty canonical renaming case ===================================Maude107=========================================== 2014-11-19 Steven Eker * importTranslation.cc (translateRegularSymbol): more detailed Assert() ===================================Maude106=========================================== 2014-10-29 Steven Eker * search.cc (smtSearch): deleted (search): allocate VariableGenerator object on the heap now that SMT_RewriteSequenceSearch destructs it (search): call clearDebug() in SMT case (search): call validForSMT_Rewriting() 2014-10-23 Steven Eker * search.cc (search): new solution format for smt-search results * userLevelRewritingContext.hh (ObjectSystemRewritingContext): updated decl for printSubstitution * userLevelRewritingContext.cc (printSubstitution): rewritten to take ignoredIndices * search.cc (search): use new SMT_RewriteSequenceSearch semantics (search): use getFinalConstraint() rather than getMatchConstraint 2014-10-22 Steven Eker * search.cc (search): rewritten to hande search modulo SMT directly 2014-10-21 Steven Eker * variableGenerator.cc (VariableGenerator): initialize pushCount * variableGenerator.hh (push): added (pop): added (clearAssertions): handle pushCount; (SMT_EngineWrapper): added data member pushCount 2014-10-17 Steven Eker * search.cc (smtSearch): rewritten to use new SMT_RewriteSequenceSearch design 2014-10-15 Steven Eker * search.cc (smtSearch): rewritten to use SMT_RewriteSequenceSearch 2014-10-14 Steven Eker * variableGenerator.hh (clearAssertions): made inline 2014-10-03 Steven Eker * variableGenerator.cc (VariableGenerator): call push() * variableGenerator.hh (clearAssertions): added 2014-09-29 Steven Eker * search.cc (smtSearch): pass VariableGenerator object to SMT_RewriteSearchState via pointer rather than reference * variableGenerator.hh: SMT_VariableManager -> SMT_EngineWrapper ===================================Maude105=========================================== 2014-09-26 Steven Eker * execute.cc (test): turned in to stub 2014-09-25 Steven Eker * variableGenerator.cc (makeFreshVariable): rewritten to use mpz_class * variableGenerator.hh (SMT_VariableManager): updated decl for makeFreshVariable() 2014-09-19 Steven Eker * search.cc (smtSearch): no # in solution message to avoid confusion with fresh varaible numbering 2014-09-18 Steven Eker * execute.cc (printModifiers): fixed longstanding bug where we weren't printing the [] notation if number2 was NONE and number was something else * interpreter.hh (ViewDatabase): added decl for smtSearch() * search.cc (search): call smtSearch() (smtSearch): added * interpreter.hh (ViewDatabase): added SMT_SEARCH to enum SearchKind * commands.yy (search): added KW_SMT_SEARCH * top.yy: added KW_SMT_SEARCH * lexer.ll: added smt-search 2014-09-16 Steven Eker * variableGenerator.cc (VariableGenerator): use setOption() call * variableGenerator.hh (SMT_VariableManager): deleted data member options 2014-09-15 Steven Eker * variableGenerator.cc (VariableGenerator): set options; create exprManager and smtEngine (~VariableGenerator): added to destruct exprManger and smtEngine (dagToCVC4, makeVariable, assertDag, makeRationalConstant): deref exprManager (assertDag, checkDag): deref smtEngine * variableGenerator.hh (SMT_VariableManager): added data member options; made exprManager and smtEngine into pointers; added decl for ~VariableGenerator() * userLevelRewritingContext.cc (printSubstitution): fix bug where we trying to dereference a null pointer in a DebugAdvisory() when a variable was unbound 2014-09-12 Steven Eker * variableGenerator.hh (SMT_VariableManager): makeVariable() become private now it is no longer overriding an abstract function in the base class * variableGenerator.cc (VariableGenerator, makeVariable): use exprManager (makeBooleanExpr): use our local version of dagToCVC4() (assertDag): use exprManager 2014-09-11 Steven Eker * variableGenerator.hh (SMT_VariableManager): added decls for makeRationalConstant() and dagToCVC4() * variableGenerator.cc (dagToCVC4): added (makeRationalConstant): added * execute.cc (sreduce): use new VariableGenerator semantics 2014-09-08 Steven Eker * variableGenerator.hh (SMT_VariableManager): added decl for makeBooleanExpr() * variableGenerator.cc (VariableGenerator): init smtEngine (assertDag, checkDag): added (makeBooleanExpr): added (assertDag, checkDag): simplified using makeBooleanExpr() * variableGenerator.hh (SMT_VariableManager): added declarations for assertDag() and checkDag() (SMT_VariableManager): added data member smtEngine 2014-09-05 Steven Eker * execute.cc (test): use validForSMT_Rewriting() * mixfixModule.hh (SharedTokens): added decl for validForSMT_Rewriting() * mixfixModule.cc (validForSMT_Rewriting): added 2014-08-13 Steven Eker * execute.cc (test): added * interpreter.hh (ViewDatabase): added decl for test * commands.yy (command): added actions for KW_TEST * top.yy: added KW_TEST * lexer.ll: added KW_TEST 2014-08-12 Steven Eker * variableGenerator.cc (makeVariable): use SMT_Info (makeFreshVariable): fleshed out stub 2014-08-11 Steven Eker * mixfixModule.cc (getSMT_NumberToken): use getSMT_Info() (findSMT_NumberSymbol): use getSMT_Info() * makeGrammar.cc (makeSymbolProductions): use getSMT_Info() * graphPrint.cc (graphPrint): use getSMT_Info() * bufferPrint.cc (handleSMT_NumberSymbol): use getSMT_Info() * dagNodePrint.cc (handleSMT_Number): use getSMT_Info() * termPrint.cc (handleSMT_Number): use getSMT_Info() * mixfixModule.hh (SharedTokens): updated decl for findSMT_NumberSymbol() * variableGenerator.cc (VariableGenerator): use smtInfo rather than sortMap * variableGenerator.hh (SMT_VariableManager): sortMap becomes smtInfo; updated decl for ctor * execute.cc (check): use smtInfo rather than sortMap * mixfixModule.hh (SharedTokens): decl for getSMT_Info() replaces decl for getSortMap(); (SharedTokens): sortMap becomes smtInfo * mixfixModule.cc (getSortMap): becomes getSMT_Info() 2014-08-06 Steven Eker * variableGenerator.hh (SMT_VariableManager): added decl for makeFreshVariable() * variableGenerator.cc (makeFreshVariable): added 2014-07-30 Steven Eker * execute.cc (check): don't bother indexing variables 2014-07-29 Steven Eker * execute.cc (check): use VariableGenerator * SMT_VariableGenerator.cc: becomes variableGenerator.cc * SMT_VariableGenerator.hh: becomes variableGenerator.hh 2014-07-28 Steven Eker * SMT_VariableGenerator.cc: created * SMT_VariableGenerator.hh: created ===================================Maude104=========================================== 2014-06-04 Steven Eker * execute.cc (check): clean up; extra sanity checks (check): use QUOTE() in warnings * dagNodePrint.cc (prettyPrint): deleted commented out code * termPrint.cc (prettyPrint): deleted commented out code * bufferPrint.cc (prettyPrint): deleted commented out code 2014-06-03 Steven Eker * termPrint.cc (handleSMT_Number): use getRangeSort() * mixfixModule.cc (findSMT_NumberSymbol): use getRangeSort() * makeGrammar.cc (makeSymbolProductions): use getRangeSort() * graphPrint.cc (graphPrint): use getRangeSort() * dagNodePrint.cc (handleSMT_Number): use getRangeSort() * bufferPrint.cc (prettyPrint): pass argRangeKnown to recursive call to fix bug we introduced when we rewrote the function (handleSMT_NumberSymbol): use getRangeSort() 2014-06-02 Steven Eker * bufferPrint.cc (prettyPrint): use rangeOfArgumentsKnown() * dagNodePrint.cc (prettyPrint): use rangeOfArgumentsKnown() * termPrint.cc (prettyPrint): use rangeOfArgumentsKnown() * sharedPrint.cc (ambiguous): added comments * mixfixModule.hh (SharedTokens): added decl for rangeOfArgumentsKnown() * sharedPrint.cc (rangeOfArgumentsKnown): added * bufferPrint.cc (handleFloat, handleString) (handleQuotedIdentifier): added (prettyPrint): call handleFloat(), handleString(), handleQuotedIdentifer() * mixfixModule.hh (SharedTokens): added decls for handleFloat(), handleString(), handleQuotedIdentifier() 2014-05-30 Steven Eker * mixfixModule.hh (SharedTokens): updated decls for handleIter(), handleMinus(), handleDivision(), handleSMT_NumberSymbol() * bufferPrint.cc (handleIter): rewritten (handleMinus): rewritten (handleDivision): rewritten (handleSMT_NumberSymbol): rewritten * mixfixModule.hh (SharedTokens): added decls for buffer print versions of prefix() and suffix() * bufferPrint.cc (prefix, suffix): added * mixfixModule.cc (getSortMap): fill out kindsWithMinus * entry.cc (addOpDeclaration): use PSEUDO_ZERO * sharedPrint.cc (ambiguous): check PSEUDO_ZERO and kindsWithZero * mixfixModule.hh (SharedTokens): added PSEUDO_ZERO to enum InternalFlags (SharedTokens): added data member kindsWithZero 2014-05-29 Steven Eker * entry.cc (addOpDeclaration): treat ZERO case as PSEUDO_NAT so the SMT Integer disambiguation works for 0 * mixfixModule.hh (SharedTokens): added comments for InternalFlags * sharedPrint.cc (prefix): moved here from dagNodePrint.cc 2014-05-21 Steven Eker * execute.cc: deepSelfDestruct() term 2014-05-20 Steven Eker * token.cc (int64ToCode): fix bug where we weren't checking for ZERO property - in practice this bug can't be exercised since code it only called from the metalevel, and the prelude will generate a 0 token before we can 2014-05-19 Steven Eker * mixfixModule.hh (SharedTokens): added decl for getSMT_NumberToken() * mixfixModule.cc (getSMT_NumberToken): added * token.cc (looksLikeRational): allow 0/n 2014-05-16 Steven Eker * makeGrammar.cc (makeSymbolProductions): added production for ZERO as an SMT_NUMBER * prettyPrint.cc (<<): added ConnectedComponent version * entry.cc (addOpDeclaration): fill out SMT_NumberSymbols map * mixfixModule.cc (findSMT_NumberSymbol): implemented 2014-05-15 Steven Eker * mixfixModule.hh (SharedTokens): added SMT_NumberSymbols data member * mixfixModule.cc (findSMT_NumberSymbol): added stub * mixfixModule.hh (SharedTokens): updated comments now that we use kindsWith* sets slightly differently (SharedTokens): added decl for findSMT_NumberSymbol * mixfixModule.cc (getSortMap): record SMT integers as belonging to kindsWithMinus 2014-05-14 Steven Eker * mixfixModule.hh (SharedTokens): added decl for buffer version of handleSMT_NumberSymbol() * bufferPrint.cc (handleSMT_NumberSymbol): added (prettyPrint): call handleSMT_NumberSymbol() * graphPrint.cc (graphPrint): handle SMT numbers * mixfixParser.cc (makeTerm): call canonicalize() on newly created SMT number * mixfixModule.hh (SharedTokens): added decl for handleSMT_Number() * dagNodePrint.cc (prettyPrint): call handleSMT_Number() (handleSMT_Number): added 2014-05-13 Steven Eker * makeGrammar.cc (makeSymbolProductions): added SMT production for SMALL_NAT * mixfixParser.cc (makeTerm): added MAKE_SMT_NUMBER case * mixfixParser.hh (M): added MAKE_SMT_NUMBER to enum SemanticActions * makeGrammar.cc (makeSymbolProductions): addd productions for SMT numbers * mixfixModule.cc (getSortMap): track kinds containing things that look like integers or rational numbers for pretty printing disambiguation * mixfixModule.hh (SharedTokens): added decl for handleSMT_Number() * termPrint.cc (prettyPrint): added SMT_NUMBER_SYMBOL case (handleSMT_Number): added 2014-05-08 Steven Eker * symbolType.hh (S): added SMT_NUMBER_SYMBOL * entry.cc (newFancySymbol): added SMT_NumberSymbol * specialSymbolTypes.cc: added SMT_NumberSymbol 2014-05-07 Steven Eker * execute.cc (check): pass sort map to dagToCVC4() 2014-05-06 Steven Eker * execute.cc (check): handle integer and real variables (check): fix bug where we were making Boolean rather than Integer variable * mixfixModule.cc (getSortMap): added * mixfixModule.hh (SharedTokens): addded decl for getSortMap() (SharedTokens): added data member sortMap 2014-04-30 Steven Eker * execute.cc (check): rewritten to use new dagToCVC4 convention 2014-04-29 Steven Eker * interpreter.hh (ViewDatabase): added decl for check() * commands.yy (command): added syntax for check command * top.yy: added KW_CHECK * lexer.ll: added KW_CHECK 2014-04-25 Steven Eker * symbolType.hh (S): added SMT_SYMBOL * entry.cc (newFancySymbol): added SMT_Symbol * specialSymbolTypes.cc: added SMT_Symbol ===================================Maude103=========================================== 2014-02-28 Steven Eker * search.cc (getVariants): handle irredundant flag (getVariants): output timing information after each variant number in incremental mode (variantUnify): output timing information after each unifier number * lexer.ll: added KW_IRREDUNDANT * top.yy: added type for optIrredundant; added KW_IRREDUNDANT * commands.yy (optIrredundant): added (command): use optIrredundant 2014-02-27 Steven Eker * interact.cc (stackOverflowHandler, internalErrorHandler): added (void) casts 2014-02-26 Steven Eker * global.hh: added alwaysAdviseFlag * global.cc: added alwaysAdviseFlag * commands.yy (command): honor alwaysAdviseFlag ===================================Maude101=========================================== 2014-02-14 Steven Eker * execute.cc (sreduce): use term2InstructionSequence() to get initial sequence of stack machine instructions 2014-02-07 Steven Eker * banner.cc (printBanner): update copyright yearl 2014-02-06 Steven Eker * mixfixParser.cc (makePrintList): delete unused typedef IntPair * renaming.hh (SyntaxContainer): added virtual dtor to placate gcc 2014-02-03 Steven Eker * lexerAux.cc (eatComment): added IssueAdvisory() for null characters in comments 2014-01-31 Steven Eker * execute.cc (sreduce): call stackMachineCompile() * syntacticPreModule.cc (getFlatModule): use < rather than != for comparing against THEORY_CLOSED ===================================Maude100a=========================================== * execute.cc (sreduce): convert abstract slots in the dummyBuilder into the concrete slots that StackMachineRhsCompiler now expects (sreduce): removed old if'd out code 2013-10-29 Steven Eker * execute.cc (sreduce): rewritten ===================================Maude100=========================================== 2013-09-24 Steven Eker * modules.yy (viewEndOpMap): add missing ; after lexBubble call * commands.yy (command): add missing ; after lexBubble() calls ===================================Maude98=========================================== 2013-08-15 Steven Eker * execute.cc (sreduce): use new execute() mechanism 2013-03-06 Steven Eker * loopMode.cc (printBubble): fixed a bug where printing the empty token caused an out-of-bounds memory reference 2012-11-01 Steven Eker * userLevelRewritingContext.cc (tracePreEqRewrite): added call to flush() ===================================Maude96b=========================================== 2012-08-06 Steven Eker * commands.yy (command): call getVariants() * lexer.ll: KW_GENERATE becomes KW_GET * top.yy: KW_GENERATE becomes KW_GET * commands.yy (command): support debug in variant unify command (command): generate variants becomes get variants and takes debug prefix (genvars): deleted * interpreter.hh (ViewDatabase): updated decl for variantUnify(); decl for getVariants() replaces decl for generateVariants() * search.cc (variantUnify): added debug flag (generateVariants): added debug flag; becomes getVariants() * lexerAux.hh: don't declare getInput() here because yy_size_t is only available within the flex output file * lexerAux.cc (getInput): use yy_size_t rather than int because Mac version of flex is 64-bit clean * lexer.ll: moved decl for getInput() here; hack to deal with int vs yy_size_t for YY_INPUT 2nd argument 2012-07-31 Steven Eker * search.cc (variantUnify): call clearDebug() (generateVariants): call clearDebug() 2012-07-27 Steven Eker * search.cc (generateVariants): call unprotect() (variantUnify): use makeUnificationProblemDag(); call unprotect() (variantUnify): pass unificationMode flag to VariantSearch() * mixfixModule.hh (SharedTokens): added decl for makeUnificationProblemDag() * mixfixModule.cc (makeUnificationProblemDag): created * mixfixModule.hh (SharedTokens): added decl for createInternalTupleSymbol(); added types IntList and InternalTupleMap; added data member tupleSymbols * mixfixModule.cc (createInternalTupleSymbol): added * symbolType.hh (S): added INTERNALTUPLE 2012-07-26 Steven Eker * search.cc (variantUnify): is parseVariantUnifyCommand(); echo constraint * mixfixParser.hh (M): added decl for makeVariantUnifyCommand() * mixfixParser.cc (makeVariantUnifyCommand): added * makeGrammar.cc (makeComplexProductions): added productions for VARIANT_UNIFY_COMMAND * mixfixModule.hh (SharedTokens): added decl for parseVariantUnifyCommand() * doParse.cc (parseVariantUnifyCommand): added * mixfixModule.hh (SharedTokens): added VARIANT_UNIFY_COMMAND * search.cc (variantUnify): added * interpreter.hh (ViewDatabase): added decl for variantUnify * commands.yy (command): added syntax for variant unify command * top.yy: added KW_VARIANT * lexer.ll: added KW_VARIANT 2012-07-23 Steven Eker * search.cc (generateVariants): output no variants message in the case that there are no variants because a blocker dag is reducible (generateVariants): use term2Dag() and deepSelfDestruct() instead of makeDag() (generateVariants): call normalize() after all to make sure hash values are valid * syntacticPreModule.hh (SharedTokens): removed two declarations for makeDag() that don't seem to be used 2012-07-19 Steven Eker * search.cc (generateVariants): echo constraint list (generateVariants): turn constraint list in to blocker dags; # variables from variableInfo is no longer accurate because of variables in blocker dags * mixfixParser.hh (M): added decl for makeTermList() (M): added MAKE_TERM_LIST * mixfixParser.cc (makeGetVariantsCommand): use makeTermList() (makeTermList): added * makeGrammar.cc (makeComplexProductions): added syntax for get variants with irreducibility constraint; added syntax for hetrogeneous term lists (makeComplexProductions): use emptyGather for "such that" and "s.t." * mixfixModule.hh (SharedTokens): added TERM_LIST * search.cc (generateVariants): use parseGetVariantsCommand() * mixfixParser.hh (M): added decl for makeGetVariantsCommand() * mixfixParser.cc (makeGetVariantsCommand): added * makeGrammar.cc (makeComplexProductions): added a production for GET_VARIANTS_COMMAND * mixfixModule.hh (SharedTokens): added decl for parseGetVariantsCommand() * doParse.cc (parseGetVariantCommand): added * specialTokens.cc: added irreducible * mixfixModule.hh (SharedTokens): added GET_VARIANTS_COMMAND * search.cc: deleted commented out functions (generateVariants): respect limit 2012-07-18 Steven Eker * search.cc (generateVariants): pass blocker dags to VariantSearch 2012-07-09 Steven Eker * freshVariableSource.cc (getFreshVariableName): reenable % variables (variableNameConflict): reenable % variables 2012-07-06 Steven Eker * freshVariableSource.cc (getFreshVariableName) (variableNameConflict): updated comments ===================================Maude96a=========================================== 2012-05-23 Steven Eker * freshVariableSource.cc (variableNameConflict): disable % variables for the moment (getFreshVariableName): disable % variables for the moment 2012-05-22 Steven Eker * search.cc (generateVariants): ignore limit as this seems to be breaking things 2012-05-21 Steven Eker * search.cc (generateVariants): check for traceAbort() (generateVariants): check counter against limit (generateVariants): delete freshVariableGenerator when we are done (generateVariants): pass responsibility for deleting context and freshVariableGenerator to ~VariantSearch() - this cleans interface for metalevel * execute.cc (printStats): print number of narrowing and variant narrowing steps * userLevelRewritingContext.hh (ObjectSystemRewritingContext): updated decl for traceVariantNarrowingStep() * userLevelRewritingContext.cc (traceVariantNarrowingStep): take originalVariables argument and use it when printing out substitution part of old and new variants * search.cc (generateVariants): make output of variants consistent with previous conventions 2012-05-18 Steven Eker * userLevelRewritingContext.hh (ObjectSystemRewritingContext): added decl for traceVariantNarrowingStep() * userLevelRewritingContext.cc (traceVariantNarrowingStep): added 2012-05-17 Steven Eker * lexer.ll: allow get as a synonym for generate 2012-05-11 Steven Eker * freshVariableSource.cc (getFreshVariableName): support odd field (variableNameConflict): check for names beginning with % * freshVariableSource.hh (FreshVariableGenerator): added odd field to getFreshVariableName() decl (FreshVariableGenerator): added data member oddCache 2012-05-03 Steven Eker * prettyPrint.cc (printAttributes): print variant attribute * importModule.cc (donateStatements2): copy variant attribute * mixfixParser.cc (makeStatementPart): hande VARIANT attribute * specialTokens.cc: added variant * mixfixParser.hh (M): added MAKE_VARIANT_ATTRIBUTE to enum SemanticActions (M): added VARIANT to enum Flags * mixfixParser.cc (makeAttributePart): support VARIANT attribute * makeGrammar.cc (makeAttributeProductions): added production for variant attribute 2012-04-19 Steven Eker * search.cc (generateVariants): use new version of UnifierFilter (generateVariants): examine all non-variable positions in dag 2012-03-30 Steven Eker * quotedIdentifierSymbol.cc (termify): added 2012-03-29 Steven Eker * search.cc (generateVariants): added 2012-03-28 Steven Eker * commands.yy (command): added syntax for generate variants command * lexer.ll: added initial mode keywords generate and variant ===================================Maude96=========================================== 2010-12-09 Steven Eker * modules.yy (skipStrayArrow): added (viewDeclaration): use skipStrayArrow to overparse var X : -> Foo . (declaration): ditto (skipStrayArrow): get line number from stray token (skipStrayColon): added 2010-11-30 Steven Eker * profileModule.cc (ProfileModule::profileFragment): added Asserts() to check for bad ModuleInfo * trial.cc (UserLevelRewritingContext::traceEndFragment): check for undefined trialRef before calling the profiler since this generally means we are tracing a Pattern (which doesn't belong to a module and can't be profiled in the current implementation) ===================================Maude95b=========================================== 2010-10-19 Steven Eker * quotedIdentifierSymbol.cc (QuotedIdentifierSymbol::makeCanonicalCopyEagerUptoReduced): deleted * quotedIdentifierSymbol.hh (class QuotedIdentifierSymbol): deleted decl for makeCanonicalCopyEagerUptoReduced() ===================================Maude95a=========================================== 2010-10-06 Steven Eker * renameModule.cc (ImportModule::donateOps2): use new symbol name rather than old symbol name in Advisory() * moduleCache.cc (ModuleCache::makeRenamedCopy): don't cache bad renamed modules * interpreter.cc (Interpreter::makeModule): simplified now that ModuleCache::makeRenamedCopy() converts bad renamed copies to null * renameModule.cc (ImportModule::makeRenamedCopy): handle ModuleCache::makeRenamedCopy() returning null * interpreter.cc (Interpreter::makeModule): simplified now that ModuleCache::makeInstatiation() converts bad summations to null * moduleCache.cc (ModuleCache::makeInstatiation): update Advisory() for bad instantiations (ModuleCache::makeSummation): don't cache bad summations * parameterization.cc (ImportModule::makeInstantiation): don't call finishCopy() on bad modules (ImportModule::instantiateBoundParameters): added static_cast<>s (ImportModule::makeInstantiation): added static_cast<>s * moduleCache.cc (ModuleCache::makeParameterCopy): Assert() that we never have a bad parameter copy 2010-10-05 Steven Eker * moduleCache.cc (ModuleCache::makeInstatiation): don't cache bad modules; instead return null (ModuleCache::makeInstatiation): deep self destruct bad modules (ModuleCache::makeInstatiation): remove ourself as a user of the bad module before self destructing it * interpreter.cc (Interpreter::makeModule): new makeInstatiation() convention * parameterization.cc (ImportModule::handleRegularImports): check for instantiateBoundParameters() returning 0 (ImportModule::instantiateBoundParameters): handle makeInstatiation() returning 0 (ImportModule::instantiateBoundParameters): handle instantiateBoundParameters() returning 0 * importModule.cc (ImportModule::donateOps) (ImportModule::donateSorts): added Assert() to check bad flag * renameModule.cc (ImportModule::finishCopy): added Assert() to check bad flag (ImportModule::donateOps2, ImportModule::donateSorts2): added Assert() to check bad flag * parameterization.cc (ImportModule::makeInstantiation): added Assert() to check bad flag 2010-09-29 Steven Eker * quotedIdentifierSymbol.hh (class QuotedIdentifierSymbol): added decl for makeCanonicalCopyEagerUptoReduced() * quotedIdentifierSymbol.cc (QuotedIdentifierSymbol::makeCanonicalCopyEagerUptoReduced): added 2010-09-08 Steven Eker * lexer.ll (id): fix a bug in where identifiers such as .foo were being split by the first rule because there wasn't a match longer than one charater ===================================Maude95=========================================== 2010-06-29 Steven Eker * prettyPrint.cc (operator<<): handle null pointer NamedEntity* case 2010-06-11 Steven Eker * view.cc (View::handleOpTermMappings): updated warning message for two lhs variables with same base name 2010-06-10 Steven Eker * importTranslation.hh (class ImportTranslation): updated decl for translateRegularSymbol() * importTranslation.cc (ImportTranslation::translateTerm): fix bug where were weren't considering renamings before the first op->term mapping by making use of extra translateRegularSymbol() arg (ImportTranslation::translateRegularSymbol): use extra argument to pass back the opToTerm index (ImportTranslation::translate): use new translateRegularSymbol() convention 2010-06-02 Steven Eker * syntacticPreModule.hh (SyntacticPreModule::addSortDecl): don't add empty sort declarations; this fixes a bug where empty sort declarations crashed show module command 2010-05-19 Steven Eker * execute.cc (Interpreter::sreduce): added * interpreter.hh (endif): added decl for sreduce * commands.yy (command): added sreduce command * top.yy: added KW_SREDUCE * lexer.ll: added sreduce ===================================Maude94=========================================== 2010-05-07 Steven Eker * mixfixModule.cc (MixfixModule::instantiatePolymorph): avoid calling deepSelfDestruct() on copy of term hook since attachTerm() already does this when it fails ===================================Maude93d=========================================== 2010-04-01 Steven Eker * unify.cc (Interpreter::unify): don't pass withExtension flag to UnificationProblem() ctor ===================================Maude93a=========================================== 2010-03-18 Steven Eker * token.cc (Token::bubbleToPrefixNameCode): removed r1 branch since we only ever return r2 * parameterization.cc (ImportModule::translateComponent): removed cerr from Assert() * bottom.yy (cleanUpParser): delete commented out broken code * entry.cc (MixfixModule::addOpDeclaration): print number of underscore in warning (MixfixModule::addPolymorph): ditto * token.cc (operator<<): removed commented out code (Token::getInt): removed commented out version (Token::checkForSpecialProperty): removed commented out Int64 code (Token::extractMixfix): treat mixfixSyntax of size 1 to be not mixfix syntax after all * lexer.ll: allow \t in stringContent for overparsing * token.cc (Token::fixUp): handle tab characters ===================================Maude93=========================================== 2010-03-05 Steven Eker * bufferPrint.cc (MixfixModule::printTails): bug where we were appending leftParen rather that rightParen in needAssocParen case ===================================Maude92c=========================================== 2009-12-24 Steven Eker * trial.cc (traceBeginRuleTrial): added missing '\n' (traceBeginScTrial): symmetric fix ===================================Maude92b=========================================== 2009-11-06 Steven Eker * entry.cc (newFancySymbol): pass strategy to MetaLevelOpSymbol() 2009-09-23 Steven Eker * interact.cc (setHandlers): call BddUser::setErrorHandler() ===================================Maude92a=========================================== 2009-08-19 Steven Eker * parameterization.cc (handleInstantiationByTheoryView): reorg sort mapping code (handleInstantiationByTheoryView): added DebugAdvisory() (handleInstantiationByTheoryView): check if a sort is moduleDeclared() wrt the target theory before sticking a parameter prefix on it in the sort mapping * moduleCache.cc (makeRenamedCopy, makeParameterCopy) (makeInstatiation, makeSummation): updated and added DebugAdvisory()s 2009-08-12 Steven Eker * interact.cc (internalErrorHandler): updated internal error message 2009-08-11 Steven Eker * view.hh (User): make OpTermMap public 2009-08-07 Steven Eker * view.hh (getFrom): added (getTo): added 2009-07-22 Steven Eker * syntacticPreModule.cc (finishModule): call destructUnusedModules() here * process.cc (processImports): don't call destructUnusedModules() because we may be in a recursive call and there may be partially built modules with no users in the cache 2009-02-27 Steven Eker * makeGrammar.cc (makeComplexProductions): allow rewrite conditions in search command 2009-02-19 Steven Eker * preModule.cc (PreModule): init owner data member * preModule.hh (getOwner): added (User): added data member owner * banner.cc (printBanner): update copyright notice * entity.cc (operator<<): use PreModule* rather than SyntacticPreModule* * preModule.hh (operator<<): added * syntacticPreModule.hh (operator<<): deleted * preModule.hh: inherit from Entity::User * syntacticPreModule.hh: no longer inherit from Entity::User 2009-02-13 Steven Eker * interpreter.hh: decl for getModuleOrIssueWarning() * interpreter.cc (getModuleOrIssueWarning): was getModule() but we were occluding needed function from base class * syntacticPreModule.hh: removed decls for makeModule() and getModule() * interpreter.hh: added decls for makeModule() and new getModule() * interpreter.cc (getModule): moved here * import.cc: deleted * interpreter.cc (makeModule): moved here - becomes part of Interpreter class * process.cc (processImports): moved here 2009-02-12 Steven Eker * import.cc (getModule): use PreModule * moduleDatabase.cc: go back to using PreModule * syntacticPreModule.cc (SyntacticPreModule): call PreModule ctor * syntacticPreModule.hh: derive from PreModule * preModule.cc: gutted * preModule.hh (class PreModule): gutted * modules.yy: PreModule -> SyntacticPreModule * top.yy: PreModule -> SyntacticPreModule * import.cc: PreModule -> SyntacticPreModule * process.cc: PreModule -> SyntacticPreModule * fixUp.cc: PreModule -> SyntacticPreModule * ops.cc: PreModule -> SyntacticPreModule * command.cc: PreModule -> SyntacticPreModule * renaming.cc: PreModule -> SyntacticPreModule * entity.cc (operator<<): PreModule -> SyntacticPreModule * compiler.cc: PreModule -> SyntacticPreModule * mixfix.hh: added class SyntacticPreModule * moduleDatabase.hh: PreModule -> SyntacticPreModule * interpreter.hh: PreModule -> SyntacticPreModule * compiler.hh: PreModule -> SyntacticPreModule 2009-02-06 Steven Eker * preModule.hh: made process() private 2009-01-29 Steven Eker * renameModule.cc (donateOps2): fix DebugAdvisory() * entry.cc (newFancySymbol): added InterpreterManagerSymbol case * specialSymbolTypes.cc: added entry for InterpreterManagerSymbol 2009-01-09 Steven Eker * view.cc (handleOpTermMappings): call resetImports() after handleVarDecls() failure to avoid importPhase weirdness later on * importModule.cc (donateSorts, donateOps, fixUpDonatedOps) (donateStatements): added Assert() for bad importPhase * view.cc (finishModule1, finishModule2): added Asserts() that module under construction shouldn't become bad * renameModule.cc (finishCopy): check bad flag in module under construction and stop construction early if it becomes set to avoid memory corruption * moduleCache.cc (makeSummation): check bad flag in module under construction and stop construction early if it becomes set to avoid memory corruption 2009-01-08 Steven Eker * modules.yy (colon2): added 2008-12-12 Steven Eker * interpreter.hh: added Environment as a base class ===================================Maude92=========================================== 2008-09-16 Steven Eker * execute.cc: removed commented out eRewrite() and eRewriteCont() * search.cc (search): same issue as below * match.cc (match): same issue as below * srewrite.cc (sRewrite): same issue as below * erewrite.cc (eRewrite): same issue as below * execute.cc (reduce): same issue as below (rewrite): same issue as below (fRewrite): same issue as below * unify.cc (unify): make sure we output an endl after the command to flush the output buffer - otherwise we could get error messages getting ahead of the command that produced them * view.hh (operator<<): added missing return statement * symbolType.cc (operator<<): added missing return statement * interact.cc (handleDebug): added return statement to silence compiler warning * importModule.hh (operator<<): added missing return statement * entity.hh (class Entity): use a virtual dtor rather than dummyToAllowDynamicCasts() * entity.cc (operator<<): fixed missing return value (both versions) * interact.cc (sigsegvHandler): rewritten to avoid compiler warning 2008-09-12 Steven Eker * preModule.hh (operator<<): added missing return value * process.cc (processOps): added a check to see of we are subsort overloading an operator from one of our parameters 2008-09-11 Steven Eker * view.cc (checkSorts): clean up and comment code; use transKind * mixfixParser.cc (parseSentence): don't make second call to getErrorPosition() (makeStrategyCommand): aviod duplicated parser.getChild() calls * import.cc (makeModule): avoid sign/unsigned comparison warning (processImports): push using check into Assert() * mixfixModule.cc (copyFixUpBubbleSpec): use newSymbol rather than do another translation * doParse.cc (getParserStats): commented out unused variable nrKinds * makeGrammar.cc (makePolymorphProductions): commented out unused variable type * importModule.cc (deepCopyCondition): assign dummy value to n to avoid compiler warning * moduleExpression.cc (deepSelfDestruct): added case MODULE to avoid compiler warning 2008-09-04 Steven Eker * interact.cc (where): fix char constness * prettyPrint.cc (printAttributes): fix char constness * top.yy: fix duplicated KW_OPS by renaming the non token returning version to KW_OPS2 * commands.yy (command): KW_OPS -> KW_OPS2 * lexer.ll: KW_OPS -> KW_OPS2 for non token returning version 2008-08-27 Steven Eker * userLevelRewritingContext.cc (checkForPrintAttribute): fix bug where we were checking PRINT_ATTRIBUTE instead of PRINT_ATTRIBUTE_NEWLINE 2008-08-26 Steven Eker * mixfixParser.cc (makeStatementPart): test PRINT flag rather than number of items (makeAttributePart): set PRINT flag; handle empty print attribute case * mixfixParser.hh (class MixfixParser): added PRINT to enum Flags * makeGrammar.cc (makeAttributeProductions): added production for empty print attribute 2008-08-21 Steven Eker * prettyPrint.cc (printAttributes): rewritten * userLevelRewritingContext.cc (checkForPrintAttribute): rewritten * importModule.cc (copyMetadata): rewritten * mixfixParser.hh (class MixfixParser): updated decls * metadataStore.hh (class MetadataStore): updated decls * metadataStore.cc (getPrintAttribute, insertPrintAttribute): rewritten to use new convention * mixfixParser.cc (makePrintList): rewritten to use two vector convention (makeStatement): update convention (makeStatementPart): update convention * printAttribute.cc: created * printAttribute.hh: created * mixfix.hh: added class PrintAttribute 2008-08-20 Steven Eker * userLevelRewritingContext.hh (class UserLevelRewritingContext): added decl for checkForPrintAttribute() * userLevelRewritingContext.cc (tracePreScApplication) (tracePreRuleRewrite, tracePreEqRewrite): call checkForPrintAttribute() (checkForPrintAttribute): added * commands.yy (command): added syntax for set print attribute and set print attribute newline * lexer.ll: added attr as abbreviation for attribute * interpreter.hh (endif): added flags PRINT_ATTRIBUTE and PRINT_ATTRIBUTE_NEWLINE 2008-08-19 Steven Eker * top.yy: added KW_ATTRIBUTE, KW_NEWLINE * lexer.ll: added keywords attribute and newline * mixfixParser.hh (class MixfixParser): updated decls for makeAttributePart(), makePrintList(), makeStatementPart() * mixfixParser.cc (makePrintList): take and fill out printList argument (makeAttributePart): take and pass printList argument (makeStatement): pass printList argument 2008-08-14 Steven Eker * metadataStore.cc (insertMetadata, insertPrintAttribute) (getPrintAttribute): const-ness change * metadataStore.hh (class MetadataStore): changed const-ness for ModuleItem* item in 3 declarations * mixfixModule.hh (SharedTokens): update decl for printAttributes() * prettyPrint.cc (printAttributes): handle printAttribute (operator<<): pass extra argument to printAttributes() (SortConstraint*, Equation*, Rule* versions) (printAttributes): rewritten; no longer static (operator<<): use new printAttributes() convention * importModule.cc (copyMetadata): added (donateStatements2): use copyMetadata (3 places) * metadataStore.cc (insertPrintAttribute): added (getPrintAttribute): added * metadataStore.hh (class MetadataStore): added data member printAttributeMap and decls for insertPrintAttribute() and getPrintAttribute() 2008-08-13 Steven Eker * token.hh (tokenize): added Assert() * mixfixParser.cc (makePrintList): fix bug where we doing extra getChild() step 2008-08-12 Steven Eker * unify.cc (unify): support systems of equations * mixfixModule.hh (SharedTokens): update decl for parseUnifyCommand() * doParse.cc (parseUnifyCommand): handle systems of equations * mixfixParser.hh (class MixfixParser): updated decl for makeUnifyCommand() * mixfixParser.cc (makeUnifyCommand): parse systems of equations * mixfixParser.hh (class MixfixParser): added UNIFY_LIST to enum SemanticActions * makeGrammar.cc (makeComplexProductions): allow UNIFY_COMMAND to consist of multiple UNIFY_PAIRs 2008-05-16 Steven Eker * mixfixParser.hh (class MixfixParser): added decl for makePrintList * mixfixParser.cc (makePrintList): added * makeGrammar.cc (makeAttributeProductions): pass MAKE_STRING and MAKE_VARIABLE to appropriate items 2008-05-15 Steven Eker * makeGrammar.cc (makeComponentProductions): added VARIABLE version of 4 variable productions (makeVariableProductions): added VARIABLE version of variable production (makeSpecialProductions): added VARIABLE version of variable production * mixfixParser.hh (class MixfixParser): added MAKE_PRINT_LIST to enum SemanticActions * mixfixModule.hh (SharedTokens): added VARIABLE, PRINT_ITEM and PRINT_LIST to enum NonTerminal; made extra nonterminals use relative numbering * makeGrammar.cc (makeAttributeProductions): added syntax for print items and print lists 2008-05-14 Steven Eker * mixfixParser.hh (class MixfixParser): added MAKE_PRINT_ATTRIBUTE to enum SemanticActions * specialTokens.cc (MACRO): added print * makeGrammar.cc (makeAttributeProductions): added syntax for print attribute 2008-05-08 Steven Eker * unify.cc (doUnification): deleted extension handling code * top.yy: deleted decl for nonterminal unify * commands.yy (command): don't pass withExtension arg to unify (unify): deleted * interpreter.hh (endif): updated declf for unify() * unify.cc (unify): remove with extension argument ===================================Maude91a=========================================== 2008-04-20 Steven Eker * unify.cc (unify): fix bug where we were not deleting problem after problemOK failed, allowing a garbage collect to call the bad problems markReachableNodes() ===================================Maude91=========================================== 2008-03-23 Steven Eker * top.yy: deleted KW_XUNIFY * commands.yy (command): deleted xunify * lexer.ll: deleted xunify ===================================Maude90a=========================================== 2008-03-12 Steven Eker * interact.cc (internalErrorHandler): update message 2008-03-07 Steven Eker * userLevelRewritingContext.hh (class UserLevelRewritingContext): added declaration for void internalErrorHandler(); removed old decls * interact.cc (setHandlers): rewritten, dead code eliminated (segmentationFaultHandler): becomes internalErrorHandler(); dead code eliminated 2008-03-05 Steven Eker * userLevelRewritingContext.hh (class UserLevelRewritingContext): added decls for stackOverflowHandler() and sigsegvHandler() * interact.cc: try using stackoverflow_install_handler() (stackOverflowHandler, sigsegvHandler): added 2008-02-28 Steven Eker * lexer.ll (END_STATEMENT_MODE): treat whitespace after "." as something that is left to global rule 2008-02-27 Steven Eker * lexer.ll: flag a nasty bug - we need to deal with white space and comments after the end of statement . before we see a keyword that tells us it is in fact the end of statement 2008-02-26 Steven Eker * lexer.ll (END_COMMAND_MODE,END_STATEMENT_MODE): handle . combined common code (END_COMMAND_MODE,END_STATEMENT_MODE): if we see a regular token we need to push it back on the input and parse it in bubble mode since it might have some special properties in bubble mode 2008-02-25 Steven Eker * commands.yy (opSelect, endSelect, badSelect): added (command): use opSelect * modules.yy (endBubble): use missingSpace() (moduleExprDot, sortDot, dot, badType): use missingSpace() * commands.yy (miscEndBubble): use missingSpace() * top.yy: added decl for missingSpace(); * bottom.yy: added * modules.yy (endBubble): better error message for missing space * commands.yy: allow ENS_IN _DOT everywhere IDENTIFIER is used * lexer.ll: added SEEN_DOT mode * commands.yy (initialEndBubble): added (moduleAndTerm, numberModuleTerm, numbersModuleTerm): use initialEndBubble 2008-02-22 Steven Eker * modules.yy (badType): use singleton (typeName): use singleton (simpleOpName): use singleton * commands.yy (cSimpleOpName): use singleton * top.yy: added variable singleton * commands.yy (miscEndBubble): added; use throughout * top.yy: declare badType to return token * modules.yy (domainRangeAttr): dra3 -> dra2 (rangeAttr): added (dra2): use rangeAttr (dra2): fuse empty and nonempty typeList cases (domainRangeAttr): use rangeAttr (badType): return token 2008-02-21 Steven Eker * top.yy: deleted cToken cTokenBarDot * commands.yy (command): use lexBubble() for select/dump (command): use parenBubble to handle (...) commands (cSimpleOpName): use parenBubble (cToken, cTokenBarDot, cTokens, cTokensBarDot): deleted * lexerAux.hh: updated decl for lexContinueBubble() * lexerAux.cc (lexContinueBubble): take pCount arg * top.yy: deleted cTokenBarDotColon * lexerAux.hh: update decl for lexBubble() * lexerAux.cc (lexBubble): check to see if first token is "(" (lexBubble): support pCount argument instead * commands.yy (command): use lexerBubble for rewrite/srewrite/match/unify (numbersModuleTerm*): 7 nonterminals rewritten (command): use lexerBubble for frewrite/erewrite/search * lexerAux.hh: added decls for lexSave(), lexContinueSave() * lexerAux.cc (lexSave, lexContinueSave): added * commands.yy (command): use lexerBubble for parse/cred/red commands (moduleAndTerm, inEnd): rewritten using lexBubble() (command): use lexerBubble for loop (numberModuleTerm, numberModuleTerm1, numberModuleTerm2): rewritten using lexBubble() * lexer.ll (id): support switching to END_COMMAND_MODE * lexerAux.hh (enum TERMINATION_TOKENS): added END_COMMAND * lexer.ll (id): handle identifiers ending in "." in END_STATEMENT_MODE; added END_COMMAND_MODE 2008-02-20 Steven Eker * lexer.ll: END_BUBBLE_MODE -> END_STATEMENT_MODE * lexerAux.hh: deleted decl for lexerTokenTreeMode() * lexerAux.cc (lexerTokenTreeMode): deleted * lexer.ll (id): delete TOKEN_TREE_MODE (id): delete END_STATEMENT_MODE * commands.yy (command): bubble -> tokenSequence * modules.yy: bubble -> tokenSequence * top.yy: added FORCE_LOOKAHEAD; deleted identityChunk; bubble becomes tokenSequence * modules.yy (attribute): reimplement identity attribute using lexerBubble (tokenTree): deleted * lexerAux.hh (enum TERMINATION_TOKENS): added BAR_RIGHT_BRACKET * lexer.ll (id): added BAR_RIGHT_BRACKET case * token.cc (peelParens): don't peel bubbles of size 2 2008-02-19 Steven Eker * lexer.ll (id): added BAR_OP_ATTRIBUTE case * modules.yy (declaration): use lexerBubble for cmb/eq/ceq/rl/crl (endTree): deleted (parenBubble): added (opName, simpleOpName): use parenBubble (declaration): moved : into op/msg decls (domainRangeAttr): deleted (dra2): becomes domainRangeAttr (declaration): use lexBubble() instead of opName for op/msg decls (declaration): need to use peelParens() (opName): deleted (hook): use parenBubble rather than parenTree (parenTree): deleted (neTokenTree): deleted * lexerAux.hh: added decl for lexContinueBubble() * lexerAux.cc (lexContinueBubble): added * modules.yy (declaration): use lexerBubble for mb * lexerAux.hh: added decl for new version of lexerBubble() * lexerAux.cc (lexBubble): added new version that allows an initial token to be placed in the bubble * modules.yy (endBubble): added (viewEndOpMap): use endBubble (2 places) * lexer.ll (id): do lexerBubble length checks in . and ENDS_IN_DOT cases 2008-02-15 Steven Eker * modules.yy (mapping): use lexBubble(); delete fromOpName and toOpName * top.yy: added decl for lexerBubble * lexerAux.hh: added decl for lexBuble() * lexer.ll: FIX_UP() -> RETURN_FIX_UP(); don't fix up .{} in command mode; removed redundant code that would pass , as an IDENTIFIER 2008-02-14 Steven Eker * modules.yy (identityChunk): use tokenTree (tokens): deleted * top.yy: deleted decls for tokenBarEqual tokenBarIf tokenBarArrow2 endToken tokenBarCommaLeft tokenBarColonTo * modules.yy (viewDeclaration): use neTokenTree (opName): use tokenTree/neTokenTree (parenTree): added (fromOpName, toOpName, opName, simpleOpName): use parenTree (hook): use parenTree (endStatement, tokensBarColon, tokensBarColonTo) (tokensBarCommaLeft, tokensBarEqual): deleted (noTrailingDot, endTokens, tokensBarIf, tokensBarArrow2): deleted (endToken): deleted (tokenBarEqual, tokenBarIf, tokenBarColonTo, tokenBarCommaLeft): deleted (tokenBarArrow2): deleted * lexerAux.hh (enum TERMINATION_TOKENS): added BAR_RIGHT_PAREN * lexer.ll (id): support BAR_RIGHT_PAREN; fix BAR_LEFT_BRACKET * modules.yy (endTree): added (declaration): use tokenTree/endTree (viewEndOpMap): use endTree (fromOpName): use tokenTree * search.cc (search): fix missing space in show cmd output * lexer.ll (id): added END_STATEMENT_MODE; SAVE(), SAVE_FIX_UP(), RETURN_SAVED() macros; savedToken, savedReturn variables 2008-02-13 Steven Eker * lexerAux.hh: added decl for lexerLatexMode() * modules.yy (tokenTree): added * lexerAux.cc (lexerTokenTreeMode): added * lexerAux.hh (enum EXCLUDE_TOKENS): added added decl for lexerTokenTreeMode() * lexer.ll (id): added token tree mode 2008-01-21 Steven Eker * top.yy: added yySearchKind to %union; updated decl for search * lexer.ll: added keyword xg-narrow * commands.yy (conceal): support xg-narrow * interpreter.hh (endif): updated decl for search() * search.cc (search): added support for xg-narrow * interpreter.hh (endif): added enum SearchKind * search.cc (search): pass flags arg to NarrowingSequenceSearch * banner.cc (printBanner): update copyright date * userLevelRewritingContext.cc (traceNarrowingStep): rewritten to support trace options * userLevelRewritingContext.hh (class UserLevelRewritingContext): update decl for traceNarrowingStep() 2008-01-18 Steven Eker * userLevelRewritingContext.cc (traceNarrowingStep): added * userLevelRewritingContext.hh (class UserLevelRewritingContext): added decl for traceNarrowingStep() ===================================Maude90=========================================== 2007-11-27 Steven Eker * freshVariableSource.hh (class FreshVariableSource): added cache data member * freshVariableSource.cc (getFreshVariableName): cache computed codes and check cache before computing a new code 2007-11-21 Steven Eker * token.cc (bubbleToPrefixNameCode): commented out problematic Assert() until further investigation 2007-10-31 Steven Eker * interpreter.hh (endif): added decl for doNarrowing() * search.cc (doNarrowing): added (search): use doNarrowing 2007-10-29 Steven Eker * search.cc (search): use class NarrowingSequenceSearch 2007-10-11 Steven Eker * unify.cc (doUnification): use getVariableInfo() 2007-10-01 Steven Eker * top.yy: declare type of search * search.cc (search): partial handling of narrowing flag * interpreter.hh (endif): update decl for search() * commands.yy (search): added (command): hijack search code to handle narrowing case 2007-09-20 Steven Eker * trial.cc (traceBeginEqTrial): removed the equation == 0 case since this should never occur and could cause a null deref in profileEqConditionStart() if it did (discovered by coverity); added Assert() (traceBeginRuleTrial, traceBeginScTrial): symmetric changes to above 2007-09-19 Steven Eker * userLevelRewritingContext.cc (tracePreScApplication): added comment to flag coverity discovered bug - need interface change to fix this properly * mixfixParser.cc (makeTerm): return 0 in (unreachable) default case rather than setting t to 0 inorder to avoid coverity warning ===================================Maude89h=========================================== 2007-08-24 Steven Eker * unify.cc (unify): variablesOK() -> problemOK() 2007-08-06 Steven Eker * interpreter.cc (setCurrentModule): fix bug where we were printing out "in" as part of the "no module" warning ===================================Maude89e=========================================== 2007-07-06 Steven Eker * unify.cc (doUnification): support extension (unify): support extension 2007-06-21 Steven Eker * top.yy (directive): non need to eatComment() now that this in done in file name lexing * lexerAux.cc (lexerFileNameMode): erase accumulator * lexer.ll: latexCode -> accumulator thoughout; added FILE_NAME_QUOTE_MODE * lexerAux.cc (lexerLatexMode): latexCode becomes accumulator * lexer.ll: handle file names enclosed in quotes 2007-06-19 Steven Eker * unify.cc (unify): use new UnificationProblem() interface 2007-06-14 Steven Eker * freshVariableSource.cc (variableNameConflict): remember to unflag codes * unify.cc (unify): use variablesOK() * freshVariableSource.cc (variableNameConflict): implemented (getFreshVariableName): use baseNumber in +ve form (FreshVariableSource): store baseNumber in +ve form 2007-06-13 Steven Eker * freshVariableSource.cc (getFreshVariableName): rewritten to use mpz_class * freshVariableSource.hh (class FreshVariableSource): fix bug where we forgot to use INT64_TEXT_SIZE (class FreshVariableSource): base number becomes a mpz_class (class FreshVariableSource): deleted data member name 2007-06-11 Steven Eker * freshVariableSource.cc (variableNameConflict): added stub * freshVariableSource.hh (class FreshVariableSource): added data member baseNumber; updated decl for ctor * freshVariableSource.cc (FreshVariableSource): handle 64 bit numbers and baseNumber (getFreshVariableName): handle 64 bit numbers and baseNumber 2007-06-07 Steven Eker * prettyPrint.cc (printVariable): handle variables with flagged name codes * token.hh (flaggedCode, isFlagged, unflaggedCode): added ===================================Maude89c=========================================== 2007-03-16 Steven Eker * renaming.cc (addOpMapping): give safe dummy values to name and term fields to fail gracefully in the case where syntax error prevents addOpTarget() from being called ===================================Maude89a=========================================== 2007-03-14 Steven Eker * lexerAux.hh: added decl for checkForPending() * lexerAux.cc (checkForPending): added ===================================Maude89=========================================== 2007-03-13 Steven Eker * freshVariableSource.cc (reset): deleted (getFreshVariableName): rewritten (FreshVariableSource): don't clear counter * freshVariableSource.hh (class FreshVariableSource): rewritten 2007-02-13 Steven Eker * unify.cc (doUnification): use getSolution() 2007-02-09 Steven Eker * freshVariableSource.cc (reset): added * freshVariableSource.hh (FreshVariableGenerator): added decl for reset() ===================================Maude88f=========================================== 2007-01-23 Steven Eker * interpreter.cc (Interpreter): clear savedStrategicSearch (fixed bug) 2007-01-22 Steven Eker * interpreter.hh (endif): added data member savedUnificationProblem (endif): added decls for doUnification() and unifyCont(); switched decl for printMatchTiming() to printDecisionTime() * execute.cc (clearContinueInfo): delete and clear savedUnificationProblem * interpreter.cc (Interpreter): clear savedUnificationProblem * match.cc (printMatchTiming): becomes printDecisionTime() (doMatching): use printDecisionTime() * unify.cc (doUnification): added (unifyCont): added (unify): rewritten using doUnification() 2007-01-17 Steven Eker * unify.cc (unify): use FreshVariableSource (Namer): deleted (unify): create a new FreshVariableSource on the heap rather than on the stack * mixfix.hh: added class FreshVariableSource * freshVariableSource.hh: created * freshVariableSource.cc: created 2007-01-16 Steven Eker * interpreter.hh (endif): deleted decl for findOrderSortedUnifiers() * unify.cc (getFreshVariableName): use Token:encode() (findOrderSortedUnifiers): deleted 2007-01-12 Steven Eker * unify.cc (findOrderSortedUnifiers): use AllSat to extract sort assignments from bdd 2007-01-11 Steven Eker * unify.cc (findOrderSortedUnifiers): created 2007-01-10 Steven Eker * unify.cc (unify): generate mgu bdd (unify): use makeVariableBdd() 2007-01-09 Steven Eker * unify.cc (unify): generate unifier bdd 2006-12-11 Steven Eker * unify.cc (unify): clear solution 2006-12-07 Steven Eker * specialTokens.cc (MACRO): added unifies * makeGrammar.cc (makeComponentProductions): added syntax for UNIFY_PAIR (makeComplexProductions): added syntax for UNIFY_COMMAND * mixfixModule.hh: UNIFY_PAIR and UNIFY_COMMAND to enum NonTerminal * doParse.cc (parseUnifyCommand): added * mixfixModule.hh: added decl for parseUnifyCommand() * mixfixParser.cc (makeUnifyCommand): added * mixfixParser.hh (class MixfixParser): added decl for makeUnifyCommand() * interpreter.hh (endif): added decl for unify() * unify.cc: created * top.yy: added unify nonterminal * commands.yy (command): added syntax for unify 2006-12-01 Steven Eker * userLevelRewritingContext.cc (dontTrace): check TRACE_BUILTIN if pe null * top.yy: added KW_BUILTIN * lexer.ll: added KW_BUILTIN * commands.yy (traceOption): added KW_BUILTIN * interpreter.hh (endif): added TRACE_BUILTIN to enum Flags ===================================Maude88d=========================================== 2006-11-20 Steven Eker * bufferPrint.cc (printKind): fix bug where we were printing all but the first sort twice * erewrite.cc (doExternalRewriting): rewritten using fairTraversal() (eRewrite): rewritten using fairStart() (eRewriteCont): don't use fairContinue() 2006-11-15 Steven Eker * interpreter.hh (endif): added decl for doExternalRewriting() * erewrite.cc (eRewrite): moved here (eRewriteCont): moved here (eRewriteCont): rewritten using doExternalRewriting() (doExternalRewriting): added (eRewrite): rewritten using doExternalRewriting() ===================================Maude88c=========================================== 2006-11-10 Steven Eker * userLevelRewritingContext.cc (makeSubcontext): fix bug where we were checking TRACE_EQ rather than TRACE_CONDITION * interpreter.hh (endif): added decls for doStrategicSearch() and sRewriteCont() * srewrite.cc: created * interpreter.hh (endif): added data member savedStrategicSearch * execute.cc (sRewrite): clean up output (clearContinueInfo): clear savedStrategicSearch 2006-11-09 Steven Eker * execute.cc (sRewrite): print rewrite count and timing info 2006-11-08 Steven Eker * strategyPrint.cc (prettyPrint): added BranchStrategy and TestStrategy cases 2006-11-07 Steven Eker * execute.cc (sRewrite): use StrategyExpression version of operator<<() * strategyPrint.cc (prettyPrint): added * mixfixModule.hh (SharedTokens): added decl for StrategyExpression* version of prettyPrint(); make StrategyExpression* verison of operator<<() a friend * strategyPrint.cc: created 2006-11-02 Steven Eker * makeGrammar.cc (makeStrategyLanguageProductions): use new MAKE_APPLICATION semantics to handle all four cases * mixfixParser.hh (class MixfixParser): deleted MAKE_APPLICATION_WITH_SUBSTITUTION and MAKE_APPLICATION_WITH_STRATEGY_LIST * mixfixParser.cc (makeStrategy): combine all four application cases * makeGrammar.cc (makeStrategyLanguageProductions): added syntax for applications with substitutions and strategy lists 2006-11-01 Steven Eker * mixfixModule.hh (SharedTokens): added STRATEGY_LIST to enum NonTerminal * makeGrammar.cc (makeStrategyLanguageProductions): added syntax for strategy lists and applications with strategy lists * mixfixParser.hh (class MixfixParser): added decl for makeStrategyList() (class MixfixParser): added MAKE_APPLICATION_WITH_STRATEGY_LIST and MAKE_STRATEGY_LIST to enum SemanticActions * mixfixParser.cc (makeStrategy): added MAKE_APPLICATION_WITH_STRATEGY_LIST case (makeStrategyList): created 2006-10-11 Steven Eker * specialTokens.cc (MACRO): added amatch * makeGrammar.cc (makeStrategyLanguageProductions): xmatch becomes amatch; added new xmatch 2006-10-09 Steven Eker * banner.cc (printBanner): update copyright notice ===================================Maude88b=========================================== * modules.yy (domainRangeAttr): fix type clash 2006-10-06 Steven Eker * modules.yy (domainRangeAttr): remove dra3 production for op : Foo [ctor] . case because [ctor] is a legal kind name and after seeing the [ we can't be sure where we should process the next token as an attribute or sort name * global.cc: created to hold global stuff that used to live in main.cc * global.hh: created to hold things that used to live in main.hh * term-order.maude: created 2006-10-03 Steven Eker * prelude.maude: STO-SET becomes STRICT-TOTAL-ORDER, SWO-SET becomes STRICT-WEAK-ORDER; added TOTAL-PREORDER, TOTAL-ORDER and a version of all the order dependent stuff based on them; fix confluent bug in SORTABLE-LIST-AND-SET 2006-09-26 Steven Eker * specialTokens.cc (MACRO): removed colon3 * makeGrammar.cc (makeBoolProductions): removed syntax for lazy sort test operators (makeComponentProductions): removed syntax for COLON3_PAIR 2006-09-25 Steven Eker * specialTokens.cc (MACRO): "orelse" -> "or-else" * preModule.cc (addParameter): don't allow parameters to be added to a theory 2006-09-22 Steven Eker * quotedIdentifierTerm.cc (instantiate2): added * quotedIdentifierTerm.hh (class QuotedIdentifierTerm): added decl for instantiate2() * modules.yy (domainRangeAttr): support over parsing of constant declarations with missing -> * prelude.maude: fmod IDENTICAL expunged 2006-09-18 Steven Eker * prelude.maude: rewrote MAP and ARRAY to fix non-confluence; changed prec of _[_] to 23 2006-09-15 Steven Eker * prelude.maude: make _[_] in ARRAY always return a result at the sort level. 2006-09-14 Steven Eker * mixfixModule.hh (SharedTokens): lowered STRAT_TEST_PREC to 93 * mixfixParser.cc (makeStrategy): handle match/xmatch without "such that" clause * makeGrammar.cc (makeStrategyLanguageProductions): match strategy expression takes a term rather than a match pair (makeStrategyLanguageProductions): added match/xmatch without "such that" clause 2006-09-13 Steven Eker * mixfixParser.cc (makeStrategy): new TestStrategy() convention * makeGrammar.cc (makeConditionProductions): implement RULE_CONDITION_FRAGMENT in terms of CONDITION_FRAGMENT via PASS_THRU rather than duplicating productions (makeBoolProductions): no longer need RULE_CONDITION_FRAGMENT version of MAKE_TRUE * mixfixParser.cc (makeConditionFragment): added PASS_THRU case * prelude.maude: fix bug that the filter functions were reversing the order of the list 2006-09-12 Steven Eker * prelude.maude: replace old LIST-AND-SET fmod with new accumulator based one; move makeList to SORTABLE-LIST-AND-SET 2006-09-11 Steven Eker * prelude.maude: added th & view TOSET; renamed SORTABLE-LIST to PARTIALLY-SORTABLE-LIST, added new SORTABLE-LIST; turned predefined TAOSET views into TOSET views 2006-09-07 Steven Eker * prelude.maude: change importion in SORTABLE-LIST to avoid renaming a module with free parameters 2006-09-01 Steven Eker * mixfixParser.cc (makeStrategy): handle MAKE_TEST case * mixfixParser.hh (class MixfixParser): rm MAKE_UNARY; added MAKE_TEST * makeGrammar.cc (makeStrategyLanguageProductions): fix gather bug in ?: syntax * mixfixParser.cc (makeStrategy): don't pass data2 to IterationStrategy() * makeGrammar.cc (makeStrategyLanguageProductions): don't pass data2 for + or * * execute.cc (sRewrite): removed commented out set generator based code 2006-08-31 Steven Eker * mixfixModule.hh (SharedTokens): added STRAT_ORELSE_PREC to enum Precedence; changed STRAT_BRANCH_PREC to 101 * mixfixParser.cc (makeStrategy): removed MAKE_UNARY case * mixfixParser.hh (class MixfixParser): removed MAKE_UNARY from enum SemanticActions * makeGrammar.cc (makeStrategyLanguageProductions): added syntax for orelse * specialTokens.cc (MACRO): added orelse * makeGrammar.cc (makeStrategyLanguageProductions): pass NEW_STRATEGY data to insertProduction() (makeStrategyLanguageProductions): use MAKE_BRANCH for ! (makeStrategyLanguageProductions): use MAKE_BRANCH for not, test and try * mixfixParser.cc (makeStrategy): rewrote MAKE_BRANCH case to be very general 2006-08-30 Steven Eker * makeGrammar.cc (makeStrategyLanguageProductions): use BranchStrategy options for not, test and try (makeStrategyLanguageProductions): implement s! as a unary branch strategy (makeStrategyLanguageProductions): fix gather for ! * mixfixParser.cc (makeStrategy): use new BranchStrategy() convention (makeStrategy): use BranchStrategy() to implement stuff that was previously implemented by UnaryStrategy() * prelude.maude: made sort() stable wrt incomparable elements; added _subset_ and _psubset_ to SET and SET* 2006-08-15 Steven Eker * execute.cc (sRewrite): use class StrategicSearch (sRewrite): added Assert() 2006-07-25 Steven Eker * prelude.maude: use /\ instead of and for first TAO-SET ceq as suggest by Narcisso ===================================Maude88a=========================================== 2006-07-20 Steven Eker * maudemlBuffer.hh (class MaudemlBuffer): update decl for generateSearch() * maudemlBuffer.cc (generateFrewrite): fix bug where we were testing limit rather than gas (generateErewrite): symmetric bug (generateSearch): handle depth * search.cc (search): pass extra arg to generateSearch() * prelude.maude: added metaNormalize * machine-int.maude: now part of the distribution * top.yy: type decl for cTokenBarDotCommaNumber * commands.yy (cTokenBarDotCommaNumber): added (numbersModuleTerm1): use cTokenBarDotCommaNumber * execute.cc (printModifiers): fix whitespace bug * commands.yy (numbersModuleTerm6): fix missing moduleAndTerm * doParse.cc (parseSentence): added Assert() to check for empty sentence 2006-07-19 Steven Eker * search.cc (search): use printModifiers() (search): pass depth arg to RewriteSequenceSearch() ctor * execute.cc (fRewrite): use printModifiers() (eRewrite): use printModifiers() * interpreter.hh (endif): added decl for printModifiers() * execute.cc (printModifiers): added * interpreter.hh (endif): decl for search() now takes depth arg * commands.yy (command): allow search to take 2 parameters 2006-07-18 Steven Eker * fixUp.cc (fixUpSymbols): use shared tokens * process.cc (processOps): use shared tokens * specialTokens.cc (MACRO): added hook tokens * makeGrammar.cc (makeSpecialProductions): use shared pseudo-tokens * specialTokens.cc (MACRO): added pseudo-tokens * makeGrammar.cc (makeComponentProductions): use shared tokens * specialTokens.cc: added tokens <=? and <- * makeGrammar.cc (makeStrategyLanguageProductions): don't use Token::encode() now that we store these things in SharedTokens * specialTokens.cc (MACRO): added strategy keywords * import.cc (processImports): don't use Token::encode() now that we store these things in SharedTokens * specialTokens.cc: added import keywords * preModule.hh (User): derive from SharedTokens rather than CommonTokens * mixfixModule.hh (SharedTokens): derive from SharedTokens rather than CommonTokens * sharedTokens.cc: created from commonTokens.cc * sharedTokens.hh (class SharedTokens): was commonTokens.hh * commonTokens.hh (class CommonTokens): use specialTokens.cc * specialTokens.cc (MACRO): added smod/endsm * preModule.cc (PreModule): handle smod * specialTokens.cc: created 2006-07-17 Steven Eker * preModule.cc (compatible): handle smod/endsm * lexer.ll (id): added syntax for smod, endsm * model-checker.maude: {_,_} : State RuleName -> Transition becomes a ctor * prelude.maude: _{_} : Qid ParameterDeclList -> Header becomes a ctor ===================================Maude88=========================================== 2006-07-13 Steven Eker * mixfixModule.cc (findSymbol): for assoc op, domainAndRange[2] and not domainAndRange[nrArgs] holds the range sort 2006-04-24 Steven Eker * mixfixParser.hh (class MixfixParser): added MAKE_UNARY to enum SemanticActions * mixfixParser.cc (makeStrategy): added MAKE_UNARY case * makeGrammar.cc (makeStrategyLanguageProductions): fix bad gather in top() syntax (makeStrategyLanguageProductions): added syntax for not, test and try strategies 2006-04-18 Steven Eker * mixfixParser.cc (makeStrategy): support normalForm flag for IterationStrategy() * makeGrammar.cc (makeStrategyLanguageProductions): syntax for ! operator 2006-04-13 Steven Eker * makeGrammar.cc (makeStrategyLanguageProductions): added syntax for top() modifier * mixfixParser.hh (class MixfixParser): added MAKE_TOP to * mixfixParser.cc (makeStrategy): added case for MAKE_TOP 2006-04-12 Steven Eker * mixfixParser.hh (class MixfixParser): MAKE_SEQUENCE -> MAKE_CONCATENATION * makeGrammar.cc (makeStrategyLanguageProductions): MAKE_SEQUENCE -> MAKE_CONCATENATION * mixfixParser.cc (makeStrategy): use ConcatenationStrategy() in place of StrategySequence() (makeStrategy): MAKE_SEQUENCE -> MAKE_CONCATENATION 2006-03-23 Steven Eker * execute.cc (sRewrite): handle limit = NONE case * commands.yy (command): handle number for srewrite (command): fix bug where erewrite wasn't allowed to take two numbers * interpreter.hh (endif): updated decl for sRewrite() * execute.cc (sRewrite): support limit; garbage collect context/gen/strategy; tidy up after aborts * mixfixParser.cc (makeAssignment): check for and recover from assignment to nonvariable 2006-03-22 Steven Eker * mixfixParser.hh (class MixfixParser): added decls for makeAssignment() and makeSubstitution() (class MixfixParser): added MAKE_SUBSTITUTION to enum SemanticActions (class MixfixParser): added MAKE_APPLICATION_WITH_SUBSTITUTION to enum SemanticActions * mixfixParser.cc (makeStrategy): added semantics for applications with substitutions (makeSubstitution): added * makeGrammar.cc (makeComponentProductions): added syntax for assignments (makeComplexProductions): added syntax for substitutions (makeStrategyLanguageProductions): added syntax for applications with substitutions * mixfixModule.hh (CommonTokens): added ASSIGNMENT and SUBSTITUTION to enum NonTerminal * mixfixParser.hh (class MixfixParser): added MAKE_ALL to enum SemanticActions * mixfixParser.cc (makeStrategy): added MAKE_ALL case * makeGrammar.cc (makeStrategyLanguageProductions): added syntax for all 2006-03-21 Steven Eker * mixfixParser.hh (class MixfixParser): MAKE_ALTERNATION -> MAKE_UNION * mixfixParser.cc (makeStrategy): added semantics for MAKE_UNION * mixfixModule.hh (CommonTokens): STRAT_ALT_PREC -> STRAT_UNION_PREC * makeGrammar.cc (makeStrategyLanguageProductions): added union syntax 2006-03-20 Steven Eker * mixfixParser.cc (makeStrategy): added semantics for MAKE_BRANCH * mixfixModule.hh (CommonTokens): added STRAT_BRANCH_PREC to enum Precedence * makeGrammar.cc (makeStrategyLanguageProductions): added syntax for branch strategy; code cleaning 2006-03-17 Steven Eker * mixfixParser.cc (makeStrategy): added iterator and pass thru cases * makeGrammar.cc (makeStrategyLanguageProductions): added syntax for iterators and parens * execute.cc (sRewrite): need to reduce term first to ensure it has sort info * mixfixParser.cc (makeStrategy): handle trivial and sequence cases * makeGrammar.cc (makeStrategyLanguageProductions): added syntax for fail, idle, sequencing * mixfixModule.hh (CommonTokens): added STRAT_SEQ_PREC and STRAT_ALT_PREC to enum Precedence * makeGrammar.cc (makeComplexProductions): fix bad gathers for arrow productions * mixfixParser.hh (class MixfixParser): added more strategy actions to enum SemanticActions 2006-03-16 Steven Eker * mixfixParser.cc (makeStrategy): added (makeStrategyCommand): use makeStrategy() 2006-03-15 Steven Eker * makeGrammar.cc (makeStrategyLanguageProductions): fix resize bug (makeStrategyLanguageProductions): handle labels (makeGrammar): don't call makeLabelProductions() for complex parsers * mixfixParser.hh (class MixfixParser): added decl for makeStrategyCommand() * mixfixParser.cc (makeStrategyCommand): added * doParse.cc (parseStrategyCommand): implement * mixfixModule.hh (CommonTokens): added decl for makeStrategyLanguageProductions() * makeGrammar.cc (makeStrategyLanguageProductions): created (makeGrammar): call makeStrategyLanguageProductions() 2006-03-08 Steven Eker * makeGrammar.cc (makeComplexProductions): quick hack for strategy command syntax * mixfixModule.hh (CommonTokens): added decl for parseStrategyCommand() (CommonTokens): added STRATEGY_EXPRESSION and STRATEGY_COMMAND to enum NonTerminal; renumbered * doParse.cc (parseStrategyCommand): added stub * execute.cc: added stub for sRewrite() * lexer.ll: added sred; deleted ored * top.yy: added KW_SREWRITE; deleted KW_OREWRITE * interpreter.hh (endif): added decl for sRewrite() * commands.yy (command): added syntax for srewrite 2006-01-06 Steven Eker * visibleModule.cc (showSortsAndSubsorts): for each line of output, show main sort in color ===================================Maude87=========================================== 2005-11-28 Steven Eker * symbolType.hh: added decl for operator<<() * symbolType.cc (operator<<): added * entry.cc (addOpDeclaration): added DebugAdvisory for when attributes differ ===================================Maude86e=========================================== 2005-11-17 Steven Eker * prelude.maude: op nil : -> HookList is now a ctor; EmptyQidList deleted; EmptyCommaList added; fixed confusion between __ and _,_ based lists of Qids ===================================Maude86d2=========================================== 2005-11-16 Steven Eker * prelude.maude: sortLeq now defined on types * interact.cc (commandLoop): fix bad endXmlLog() call 2005-11-10 Steven Eker * mixfixModule.cc (MixfixModule): fix memory leak: deepSelfDestruct() identities * prelude.maude: added QID-SET; use QID-SET in META-MODULE; added extra sorts and declarations to achieve preregularity and associativity of _;_ 2005-11-09 Steven Eker * interact.cc (commandLoop): call endXmlLog() 2005-11-08 Steven Eker * moduleDatabase.hh (class ModuleDatabase): delete decl for ~ModuleDatabase(); add decl for deleteNamedModules() * moduleDatabase.cc (deleteNamedModules): added (~ModuleDatabase): deleted * interact.cc (commandLoop): delete interpreter here * preModule.cc (~PreModule): fix memory leak where we weren't deleting module expressions for parameter theories * viewDatabase.cc (~ViewDatabase): delete views 2005-11-07 Steven Eker * moduleCache.hh (User): updated decl for showCreatedModules() * moduleDatabase.hh (class ModuleDatabase): updated decl for showNamedModules() * moduleDatabase.cc (showNamedModules): take ostream& parameter * moduleCache.cc (showCreatedModules): take ostream& parameter * interpreter.cc (showModules): pass cout to showNamedModules() and showCreatedModules() * main.hh: update decl for interpreter * main.cc: make interpreter a reference to chase down memory leak 2005-11-02 Steven Eker * view.cc (clearOpTermMap): added (~View): use clearOpTermMap() (regretToInform): use clearOpTermMap() for fix stale term bug 2005-10-26 Steven Eker * prelude.maude: fixed large number of white space issues; in particular line no longer start with tab which messes with tecla * renameModule.cc (donateOps2): fixed nasty scoping bug that left format uninitialized in if branch 2005-10-25 Steven Eker * entry.cc (newFancySymbol): put pairs returned by insert() into local variables to appease purify (3 places) 2005-10-14 Steven Eker * prelude.maude: use protecting rather than inc in LIST-AND-SET ===================================Maude86d=========================================== 2005-10-07 Steven Eker * prelude.maude: added view TRIV * view.cc (View): fix memory leak: deepSelfDestruct() fromExpr and toExpr * auxProperty.cc (splitParameterList): fixed nasty new[]/delete bug (splitParameterizedSort): symmetric bug * main.cc (main): add -no-wrap flag (printHelp): mention -no-wrap flag 2005-10-06 Steven Eker * view.cc (handleOpTermMappings): fix nasty bug where we were forgetting to return a value at the end of function (evaluate): same bug! * interact.cc (segmentationFaultHandler): write \n\n after error message 2005-10-05 Steven Eker * prelude.maude: added fmod LIST-AND-SET 2005-10-04 Steven Eker * prelude.maude: X$Elt -> Item{X} for several declarations in LIST* * modules.yy (expectedIs, expectedDot): fix type mismatch bug only found by older (1.28) version of bison 2005-09-29 Steven Eker * parameterization.cc (instantiateBoundParameters): much simplification 2005-09-28 Steven Eker * importModule.hh (User): updated decl for instantiateBoundParameters() * parameterization.cc (instantiateBoundParameters): greatly simplified now that we don't have to deal with nested bound parameter instantiations (instantiateBoundParameters): eagerly rebind escaped parameters (handleRegularImports): deleted recapture code * importModule.hh (User): updated decls: extraParameterMap -> extraParameterSet * parameterization.cc (handleInstantiationByTheoryView): remove oldParameterName stuff now that parameters cannot clash and change name (handleInstantiationByTheoryView): extraParameterMap -> extraParameterSet (handleParameterizedSorts): extraParameterMap -> extraParameterSet (makeInstantiation, instantiateBoundParameters) (instantiateSortName): extraParameterMap -> extraParameterSet (instantiateRenaming): extraParameterMap -> extraParameterSet * importModule.hh (User): added typedef ParameterSet * parameterization.cc (instantiateBoundParameters): fix bug where we putting the view name in extraParameterMap 2005-09-27 Steven Eker * parameterization.cc (instantiateBoundParameters): compute parameterMap and extraParameterMap * renaming.cc (makeTypeName): fix bug by using Token::sortName instead of Token::name * parameterization.cc (instantiateSortName): added (instantiateRenaming): use instantiateSortName() (instantiateBoundParameters): use instantiateRenaming() * importModule.hh (User): added decl for instantiateRenaming() * parameterization.cc (instantiateRenaming): added * renaming.hh (class Renaming): added decl for addOpMappingPartialCopy() * renaming.cc (makeCanonicalVersion): clear term field of newly created op mapping in specific case for cleanliness (addOpMappingPartialCopy): added 2005-09-21 Steven Eker * importModule.cc (parametersBound): moved here; made recursive to deal with renaming modules having bound parameters 2005-09-20 Steven Eker * import.cc (makeModule): allow bound parameters in a module that is to be renamed * renameModule.cc (makeRenamedCopy): allow bound parameters * parameterization.cc (instantiateBoundParameters): added back old hacky code to deal with renamings * modules.yy (renameExpr): added (instantExpr): added (moduleExpr2): use renameExpr (moduleExpr3): use instantExpr, parenExpr (expectedDot): added (parenExpr): added (moduleExprDot): use tokenBarDot, expectedDot, parenExpr, renameExpr, instantExpr in order to detect and recover from missing period (typeDot): use expectedDot (typeAttr): use expectedDot (expectedIs, expectedDot): improve warnings 2005-09-19 Steven Eker * modules.yy (module): use expectedIs (expectedIs): added (view): use expectedIs 2005-09-16 Steven Eker * import.cc (makeModule): check for having both a theory-view and a PEM 2005-09-15 Steven Eker * importModule.cc (ImportModule): don't clear nrBoundParameters * renameModule.cc (makeRenamedCopy): use parametersBound() in place of nrBoundParameters * view.cc (evaluate): getNrFreeParameters() -> getNrParameters() * visibleModule.cc (showModule): remove "Free" from function calls * import.cc (processImports): use parametersBound() rather than getNrFreeParameters() (makeModule): use getNrParameters() rather than getNrFreeParameters() (makeModule): use getParameterTheory() rather than getFreeParameterTheory() (2 places) (makeModule): use parametersBound() rather than getNrBoundParameters() * parameterization.cc (handleRegularImports): use getParameterName() in place of getFreeParameterName() (instantiateBoundParameters): use getParameterName() in place of getFreeParameterName() (handleRegularImports): use parametersBound() in place of getNrFreeParameters() (instantiateBoundParameters): use getNrParameters() in place of getNrFreeParameters() * importModule.hh (getNrBoundParameters): deleted (getNrFreeParameters): deleted (parametersBound): added (User): deleted data member nrBoundParameters (getFreeParameterTheory): deleted (getFreeParameterName): becomes getParameterName() * parameterization.cc (makeInstantiation): don't set nrBoundParameters (handleInstantiationByParameter): don't use nrBoundParameters (handleInstantiationByTheoryView): don't use nrBoundParameters (handleInstantiationByModuleView): don't use nrBoundParameters (handleInstantiationByTheoryView): simplified (handleInstantiationByModuleView): simplified (handleInstantiationByTheoryView): replaced code to resolve parameter clash with an Assert() that the clash does not happen (handleRegularImports): use parametersBound() rather than testing nrBoundParameters (handleRegularImports): simplified now that we know we will have no bound parameters (handleRegularImports): check parametersBound rather than nrBoundParameters (makeInstantiation): check that we don't have bound parameters; use getNrParameters() in place of getNrFreeParameters() (makeInstantiation): don't copy bound parameters - there shouldn't be any (instantiateBoundParameters): check parametersBound rather than nrBoundParameters (instantiateBoundParameters): rearranged Asserts() (makeInstantiation): rearranged Asserts() (instantiateBoundParameters): commented out code for recursive call (instantiateBoundParameters): no need to check index against nrBoundParameters since we only have bound parameters 2005-09-14 Steven Eker * parameterization.cc (handleRegularImports): made escaped parameter Assert() very detail to try an nail obscure bug (instantiateBoundParameters): added DebugAdvisory() for escapees 2005-09-08 Steven Eker * renaming.cc (makeCanonicalVersion): genericsToAdd -> genericsToConsider (makeCanonicalVersion): clean up and fix bug that we weren't generating an advisory when user tried to rename a parameter polymorph 2005-09-07 Steven Eker * main.cc (dioTest): deleted 2005-08-31 Steven Eker * prelude.maude: changed prec for _;_ operator in ARRAY 2005-08-30 Steven Eker * ops.cc (setFlag): watn about duplicate simple attributes (setIdentity): warn about multiple identities (setPrec): warn about multiple precs (setGather): warn about multiple gathers (setMetadata): warn about multiple metadatas (setFormat): warn about multiple formats (setFrozen): warn about multiple frozens (setPoly): want about multiple polys (setLatexMacro): warn about multiple latexs (setStrat): warn about multiple strats * symbolType.hh (class SymbolType): added SIMPLE_ATTRIBUTES 2005-08-25 Steven Eker * linear.maude: built in natSystemSolve now takes a String; added op-hook stringSymbol 2005-08-23 Steven Eker * linear.maude: fix _,_ renaming 2005-08-17 Steven Eker * modules.yy (mappingList): added error handling to mappingList to ensure we swap back syntax containers (renaming2): place error handling here instead (viewDeclaration): addded error handling 2005-08-16 Steven Eker * linear.maude: created * fixUp.cc (defaultFixUp): added DebugAdvisory()s * prelude.maude: SPARSE-MAP becomes ARRAY 2005-08-15 Steven Eker * prelude.maude: added fth DEFAULT and associated views; added SPARSE-MAP ===================================Maude86c=========================================== 2005-07-29 Steven Eker * renaming.cc (makeCanonicalVersion): change the way generics are added (makeCanonicalVersion): rewritten to avoid renaming symbols and polymorphs from parameters (makeCanonicalVersion): added hack to that we generate advisory in the generic non-polymorph case * renaming.hh (class Renaming): added typedef IdSet * renaming.cc (makeCanonicalVersion): ignore mappings for sorts that come from parameters * renameModule.cc (makeRenamedCopy): deleted commented out line to copy nrBoundParameters - we do not rename modules with bound parameters * importModule.hh (parameterDeclared): added Symbol* and Sort* vesions (parameterDeclaredPolymorph): added * importModule.cc (importOps): set nrSymbolsFromParameters and nrPolymorphsFromParameters (importSorts): set nrSortsFromParameters (ImportModule): clear nrSortsFromParameters, nrSymbolsFromParameters, nrPolymorphsFromParameters * importModule.hh (User): added data members nrSortsFromParameters, nrSymbolsFromParameters, and nrPolymorphsFromParameters 2005-07-28 Steven Eker * parameterization.cc (addOpMappingsFromView): check moduleDeclaredPolymorph() * view.cc (checkPolymorphicOps): don't allow view to map module declared polymorphs * importModule.hh (User): added data member polymorphDeclaredInModule (moduleDeclaredPolymorph): added * renameModule.cc (donateOps2): keep track of polymorphs declared in modules and donated to theories * parameterization.cc (addOpMappingsFromView): handle polymorphs * view.hh (User): added decl for checkPolymorphicOps() * view.cc (checkOps): check for bad mapping between non-algebraic operators (checkPolymorphicOps): created to hold polymorph checking code (evaluate): use checkPolymorphicOps() (checkPolymorphicOps): look at all polymorphs rather than just imported ones * symbolType.hh (nonAlgebraic): added * view.cc (~View): deepSelfDestruct() terms in opTermMap 2005-07-27 Steven Eker * parameterization.cc (addOpMappingsFromView): don't map operators that have a module declaration (addOpMappingsFromView): prefer op->term mappings over op->op mappings * view.cc (checkOps): don't map operators that have a module declaration * view.hh (User): added decl for checkOps() * view.cc (checkOps): created to hold op checking code (evaluate): use checkOps() * importModule.hh (moduleDeclared): added Symbol* version * renameModule.cc (donateOps2): update opDeclaredInModule * importModule.hh (moduleDeclared): added * view.cc (checkSorts): don't allow mapping of module declared sorts 2005-07-26 Steven Eker * import.cc (makeModule): check badFlag in summation case (makeModule): reorg'd so that bad flag is always tested for modules made by interpreter * renameModule.cc (donateSorts2): handle the case where we have a sort imported from both a module and a theory * importModule.cc (addImport): changed messages; switch importation module to including for theories and don't allow other illegal imports at all. (addParameter): deleted commented out parameterTheories code 2005-07-25 Steven Eker * renameModule.cc (donateSorts2): update sortDeclaredInModule * importModule.hh (User): added data members sortDeclaredInModule, opDeclaredInModule 2005-07-21 Steven Eker * preModule.hh (getNrParameters, getParameterName, getParameter): added * parameterization.cc (handleInstantiationByTheoryView) (handleInstantiationByModuleView, instantiateBoundParameters): use new version of isTheory() (makeParameterCopy): use new version of isTheory() (instantiateBoundParameters): deleted commented out code to handle the instantiation of a renaming of a module with bound parameters since we no longer allow the renaming of modules with bound parameters * view.cc (evaluate): use new version of isTheory() 2005-07-20 Steven Eker * mixfixModule.hh (isTheory): added non-static version * prelude.maude: added hooks for headerSymbol, parameterDeclSymbol, parameterDeclListSymbol * view.cc (evaluate): check for free parameters in toModule 2005-07-19 Steven Eker * prelude.maude: replace metalevel modules with experimental metalevel; defined QID-LIST in terms of LIST{Qid} and added NeTypeList to fix preregularity problems; defined NAT-LIST in terms of LIST{Nat}; added op-hook for instantiation symbol 2005-07-18 Steven Eker * view.cc (evaluate): fullstop in "reexamining view" message * importModule.cc (deepSelfDestruct): remove ourself as a user from each view argument * parameterization.cc (makeInstantiation): always keep track pf view arguments * importModule.hh (User): update comment on viewArgs * parameterization.cc (handleInstantiationByModuleView): make copy a user of argumentView (handleInstantiationByTheoryView): make copy a user of argumentView * moduleCache.cc (destructUnusedModules): fix bug; we now look for modules with a single user since _we_ are that user * entity.hh (hasUsers): becomes getNrUsers() * entity.cc (removeUser): fix {} problem * view.cc (finishModule2): don't call addUser() - this is already done by ImportModule() * entity.cc (addUser): fix {} problem (DebugAdvisory() macro contains an if statement) * importModule.cc (ImportModule): replace delete canonicalRenaming with an Assert() (deepSelfDestruct): delete canonicalRenaming here 2005-07-15 Steven Eker * modules.yy (view): need to insert view _before_ we finish it to avoid the existence of two views with the same name when a view is replaced * view.hh (User): UNKNOWN -> STALE * view.cc (evaluate): added more DebugAdvisory()s (regretToInform): UNKNOWN -> STALE (evaluate): UNKNOWN -> STALE * preModule.hh (operator<<): added (User): made Entity::User derivation public * view.hh (operator<<): added * importModule.hh (operator<<): added * entity.cc (operator<<): added Entity* and Entity::User* versions (removeUser): rewritten (addUser): rewritten (informUsers): added DebugAdvisory() * view.cc (regretToInform): rewritten (~View): deepSelfDestruct() newFromTheory and newToModule (finishModule2): call addUser() (~View): call informUsers() * importModule.cc (deepSelfDestruct): deleted commented out parameterTheories code * view.hh (User): derive from Entity * entity.cc (informUsers): simplified by fusing loops 2005-07-14 Steven Eker * renaming.cc: unmake change * renaming.hh (class Renaming): unmake change * importModule.hh (User): unmake change * parameterization.cc: unmake previous changes since the deepCopy() idea is a dead duck - both because of a chicken & egg over sorts/symbols and the loss of variable index info from the original * renaming.cc (~Renaming): added * renaming.hh (class Renaming): adde decl for dtor * importModule.hh (User): updated decl for addOpMappingsFromView() * parameterization.cc (addOpMappingsFromView): take instance parameter; deepCopy() term part of op->term mappings into instance rather than using the original (handleInstantiationByTheoryView): pass instance parameter to addOpMappingsFromView() (handleInstantiationByModuleView): pass instance parameter to addOpMappingsFromView() 2005-07-13 Steven Eker * importModule.hh (User): added decl for translateComponent() (User): deleted commented out parameterTheories data member * parameterization.cc (addOpMappingsFromView): use translateComponent() (translateComponent): added * importTranslation.cc (translate): use FIRST_USER_SORT 2005-06-30 Steven Eker * view.cc (evaluate): skip to symbol existence check for ops that are being mapped to terms * importTranslation.cc (translateTerm): added translation splitting (translateTerm): added DebugAdvisory()s * importTranslation.hh (class ImportTranslation): added typedef ModuleList (ImportTranslation): added private ctor 2005-06-29 Steven Eker * importTranslation.hh (class ImportTranslation): updated decl for translateRegularSymbol() * importTranslation.cc (translateRegularSymbol): need to fill out opToTerm when we hit op->term mapping (translateRegularSymbol): pass back const_iterator (translateTerm, translate): use const_iterator * view.cc (evaluate): quick hack to allow bad views to be used for testing * importTranslation.cc (translateTerm): crude first implementation 2005-06-28 Steven Eker * parameterization.cc (addOpMappingsFromView): handle op->term mappings * view.hh (User): updated decls for getOpMapTerm() and both versions of typeMatch() * view.cc (typeMatch): rewritten (both versions) (getOpMapTerm): rewritten * parameterization.cc (addOpMappingsFromView): removed qualification for renameOp() call * view.cc (evaluate): removed qualification for renameOp() call * renaming.hh (class Renaming): de-virtualized renameOp() * view.cc (getOpMapTerm): removed CantHappen() (renameOp): deleted * view.hh (User): deleted decl for renameOp() * importTranslation.cc (translateRegularSymbol): handle id == NONE (translateRegularSymbol): moved Assert() checking for missing translation here * renaming.cc (printRenaming): added Assert() to check that we don't try to print a renaming that contains an op->term mapping * renaming.hh (class Renaming): added decl for getOpTargetTerm() (getOpTargetTerm): added * renaming.cc (addOpTarget): (both versions) clear term field (addOpTargetTerm): added * renaming.hh (class Renaming): added term field to struct OpMapping (class Renaming): added decl for addOpTargetTerm(Term* term) 2005-06-27 Steven Eker * parameterization.cc (addOpMappingsFromView): qualify renameOp() call * view.hh (User): added decls for typeMatch() (both versions) * view.cc (typeMatch): added (two versions) (renameOp): added (getOpMapTerm): added (evaluate): qualify renameOp() call * view.hh (User): added decls for getOpMapTerm() and renameOp() * renaming.hh (class Renaming): virtualize id version of renameOp() * importTranslation.cc (translate): only store mapping int directMap if it is non-null, i.e. op->op; comment out Assert() that mapping is non-null 2005-06-24 Steven Eker * importTranslation.cc (translateTerm): term is const Term* * importTranslation.hh (class ImportTranslation): updated decl for translateTerm() * importTranslation.cc (findTargetVersionOfSymbol): added (translateTerm): new calling convention for instantiate() * importTranslation.hh (class ImportTranslation): added decl for findTargetVersionOfSymbol() 2005-06-23 Steven Eker * importTranslation.cc (translate): use translateRegularSymbol() (translateTerm): partly implemented * importTranslation.hh (class ImportTranslation): added decl for translateRegularSymbol() * importTranslation.cc (translateRegularSymbol): added (translate, translateLabel): using RenamingList * renaming.hh (class Renaming): added decls for new member functions * renaming.cc (renameOp): added id version (typeMatch): added Vector version * importTranslation.hh (class ImportTranslation): added typedef RenamingList 2005-06-22 Steven Eker * importTranslation.cc (makeTranslatedTerm): becomes translateTerm() * importTranslation.hh (class ImportTranslation): replaced makeTranslatedTerm() with translateTerm() 2005-06-17 Steven Eker * parameterization.cc (makeParameterCopy): simplified using new addSortMapping(), parameterRename() and addLabelMapping() functions (handleInstantiationByParameter): simplified using new addSortMapping(), parameterRename() (handleInstantiationByTheoryView): simplified using new addSortMapping(), parameterRename() (handleInstantiationByModuleView): simplified using new addSortMapping() (handleParameterizedSorts): simplified using new addSortMapping() (handleInstantiationByTheoryView): call addOpMappingsFromView() to handle op mappings in the theory-view * token.hh (class Token): updated decl for parameterRename() * token.cc (parameterRename): now work on ints rather than tokens * renaming.hh (class Renaming): added decls for new addSortMapping() and addLabelMapping() versions * renaming.cc (addSortMapping): added int version (addLabelMapping): added int version 2005-06-16 Steven Eker * mixfixModule.hh (CommonTokens): updated decl for findSort() * mixfixModule.cc (findSort): made const * parameterization.cc (addOpMappingsFromView): crude first implementation * renaming.hh (class Renaming): added decls for new functions * renaming.cc (addType): added component* version (addOpTarget): added int version (addOpMapping): added int version 2005-06-15 Steven Eker * parameterization.cc (handleInstantiationByModuleView): call addOpMappingsFromView() * importModule.hh (User): added decl for addOpMappingsFromView() * parameterization.cc (makeInstantiation): use handleInstantiationByTheoryView() (handleInstantiationByModuleView): added (makeInstantiation): use handleInstantiationByModuleView() (addOpMappingsFromView): added stub * importModule.hh (User): added decl for handleInstantiationByTheoryView() * parameterization.cc (handleInstantiationByTheoryView): added (makeInstantiation): use handleInstantiationByParameter() * importModule.hh (User): added decl for handleInstantiationByParameter() * parameterization.cc (handleInstantiationByParameter): created (makeInstantiation): use handleParameterizedSorts() * importModule.hh (User): added decl for handleRegularImports() * parameterization.cc (makeInstantiation): use handleRegularImports() (handleParameterizedSorts): added * importModule.hh (User): added decl for handleRegularImports() * parameterization.cc (handleRegularImports): created 2005-06-14 Steven Eker * parameterization.cc (makeInstantiation): changed importation mode for modules that are the target of module-views from INCLUDING to PROTECTING 2005-06-13 Steven Eker * importTranslation.cc (translate): ERROR_SORT -> KIND 2005-06-10 Steven Eker * view.hh (User): deleted struct OpTermMapping; updated typedef OpTermMap * view.cc (mapComponent, mapSort): moved here (handleOpTermMappings): store from and to (showView): print op->term mappings * view.hh (User): updated decl for indexRhsVariables() * view.cc (handleOpTermMappings): use mapSort(); put sort info in VarMap * view.hh (mapSort): added * view.cc (handleOpTermMappings): use mapComponent() (evaluate): simplified using mapComponent() * view.hh (mapComponent): added * view.cc (indexRhsVariables): use VarMap; check variables sort * view.hh (User): added decl for indexRhsVariables() (User) IntMap becomes VarMap * view.cc (handleOpTermMappings): use indexRhsVariables() (indexRhsVariables): added 2005-06-09 Steven Eker * view.cc (handleOpTermMappings): added to handle op->term mapping code (evaluate): use handleOpTermMappings() (handleOpTermMappings): check lhs arguments (handleOpTermMappings): check for double use of variable name in lhs * view.hh (User): added decls for checkSorts(), handleVarDecls() * view.cc (evaluate): handle variable aliases (evaluate): fix line numbers for warnings in new code (handleVarDecls): added to hold variable alias code (evaluate): use handleVarDecls() (checkSorts): added to hold sort checking code (evaluate): use checkSorts() * preModule.hh (User): deleted friend decl for operator<<() * command.cc (operator<<): PreModule::Type& version; moved to syntaxContainer.cc * syntaxContainer.cc: created 2005-06-08 Steven Eker * view.hh (User): added decls for finishModule1(), finishModule2() * view.cc (finishModule): added (finishModule): split into finishModule1() and finishModule2() (evaluate): generate and use newFromTheory, newToModule * importModule.hh (User): added VIEW_LOCAL to enum Origin * view.hh (User): added data members newFromTheory, newToModule * view.cc (showView): handle variables (View): clear newFromTheory, newToModule * mixfix.hh: added class SyntaxContainer * view.cc (addVarDecl): implemented (addType): implemented * view.hh (User): added struct VarDecl; typedef VarDeclList, typedef TypeList; added data members varDecls and varDefs * preModule.hh (User): deleted struct Type * syntaxContainer.hh (class SyntaxContainer): added struct Type 2005-06-07 Steven Eker * modules.yy (view): set currentSyntaxContainer (viewDeclaration): use varNameList, typeDot (viewBadType, viewTypeDot, viewTypeList, viewType): deleted (viewVarNameList, viewVarNameList): deleted (viewEndOpMap): use typeList and typeName * top.yy: added variable oldSyntaxContainer * modules.yy (module): set currentSyntaxContainer (varNameList): use currentSyntaxContainer (badType): use currentSyntaxContainer (typeName): use currentSyntaxContainer (fromSpec): use typeList and typeName (fromTypeList): deleted (fromType): deleted (renaming): save, set and restore currentSyntaxContainer * top.yy: added variable currentSyntaxContainer * view.hh (User): declaration for addType2() becomes addType() * view.cc (addType2): becomes addType() * renaming.cc (addVarDecl): added (addType): updated * renaming.hh (class Renaming): derive from SyntaxContainer (class Renaming): added decl for addVarDecl(); updated decl for addType() * preModule.hh (User): derive from SyntaxContainer * syntaxContainer.hh: created * modules.yy (viewDeclaration): added syntax for variable declarations (viewVarNameList, viewBadType, viewTypeDot, viewTypeDot): added * view.cc (addVarDecl): added stub (addType2): added stub * view.hh (User): added decls for addVarDecl() and addType2() * doParse.cc (parseSentence): fix longstanding bug where we were testing firstBad against nrTokens rather than begin + nrTokens * view.cc (addOpTermMapping): implemented (evaluate): parse op->term mapping bubbles (evaluate): make sure we parse destination term into the correct component * view.hh (User): added struct BubblePair, struct OpTermMapping, typedef OpTermList, typedef OpTermMap; added data members opTermList and opTermMap 2005-06-06 Steven Eker * lexer.ll: deleted KW_TERM * view.hh (User): updated decl for addOpTermMapping(); deleted decl for addOpTargetTerm() * view.cc (addOpTermMapping): updated stub (addOpTargetTerm): deleted stub * top.yy: deleted decl for KW_TERM * modules.yy (viewFromBubble): deleted (viewDeclaration): use tokensBarColonTo (viewEndOpMap): rewritten (tokenBarTerm): deleted; removed all mention of KW_TERM * token.hh (class Token): added decl for peelParens() * token.cc (peelParens): added * modules.yy (viewTypeList): was viewFromTypeList (viewType): was viewFromType (tokenBarDot, endToken, tokenBarCommaLeft, sortToken, identifier): added KW_TERM (inert): removed KW_TERM (tokenBarColonTo): added KW_TERM (tokenBarTerm): added (viewFromBubble): set parenFlag 2005-06-03 Steven Eker * view.cc (addOpTermMapping): added stub (addOpTargetTerm): added stub * view.hh (User): added decls for addOpTermMapping() and addOpTargetTerm() * modules.yy (inert): added KW_TERM * lexer.ll: added KW_TERM * top.yy: added decl for KW_TERM * modules.yy (viewFromType): added (viewFromTypeList): added (viewEndOpMap): added (view): dont use currentRenaming = CV trick (viewFromBubble): added (viewDeclaration): rewritten to use viewFromBubble and viewEndOpMap 2005-06-02 Steven Eker * importTranslation.hh (class ImportTranslation): added decl for makeTranslatedTerm() * importTranslation.cc (makeTranslatedTerm): added stub ===================================Maude86b=========================================== 2005-04-29 Steven Eker * main.cc (main): added -no-advise flag (printHelp): mention -no-advise flag 2005-04-27 Steven Eker * moduleCache.cc (makeSummation): don't put parens around name (makeRenamedCopy): put parens around module arg if it is a summation (makeInstatiation): put parens around module arg if it is a renaming * visibleModule.cc (VisibleModule): pass TEXT to ImportModule() * importModule.cc (ImportModule): init origin from argument * renameModule.cc (makeRenamedCopy): pass RENAMING to ImportModule() * parameterization.cc (makeParameterCopy): pass PARAMETER to ImportModule() (makeInstantiation): pass INSTANTIATION to ImportModule() * moduleCache.cc (makeSummation): pass ImportModule::SUMMATION to ImportModule() * importModule.hh (User): added data member origin (getOrigin): added (User): update decl for ctor * importModule.cc (ImportModule): init origin to TEXT * importModule.hh (User): added enum Origin * renameModule.cc (makeRenamedCopy): comment out code to copy nrBoundParameters; Assert that nrBoundParameters == 0 * parameterization.cc (instantiateBoundParameters): comment out code for handling renaming case; add Assert() to check that our original arguments and base module exist * import.cc (makeModule): don't allow renaming of modules with bound parameters * importModule.hh (getNrBoundParameters): added 2005-04-26 Steven Eker * prelude.maude: do renaming on LIST{TAO-SET} in SORTABLE-LIST 2005-04-25 Steven Eker * parameterization.cc (makeInstantiation): added DebugAdvisory() for rebinding case (makeInstantiation): rewrote code that generates instantiations for imports so that it can handle imports that share both free and bound parameters (instantiateBoundParameters): added DebugAdvisory() for bound parameters that escape during the construction of a new foundation (instantiateBoundParameters): rewrote code that generates new instantiations of foundations so that it rebinds escaped parameters * importModule.hh (User): updated decl of instantiateBoundParameters() and make it private * parameterization.cc (instantiateBoundParameters): keep track of escaped parameters (makeInstantiation): check for escaped parameters from imports and generate rebinding instantiations if needed 2005-04-21 Steven Eker * parameterization.cc (makeInstantiation): generate extra argument lists for sorts parameterized by parameter instantiated by theory-view (makeInstantiation): added assert to check for free parameters in instance of imported module 2005-04-20 Steven Eker * parameterization.cc (instantiateBoundParameters): added (makeInstantiation): save arguments if we have bound parameters; use instantiateBoundParameters() rather than ModuleCache::makeInstatiation() to handle imports with bound parameters (makeInstantiation): simplified and reorganized, now that we never have to instantiate bound parameters (instantiateBoundParameters): rewritten for a first crude attempt at handling renamed modules * importModule.hh (User): added data members viewArgs, paramArgs (User): added decl for instantiateBoundParameters() 2005-04-19 Steven Eker * mixfixModule.cc (findSymbol): use new firstSymbols convention * entry.cc (addOpDeclaration): use new firstSymbols convention * mixfixModule.hh (CommonTokens): deleted data member symbolNames; data member firstSymbols becomes an IntMap * moduleDatabase.cc (setOmodInclude): substract() -> erase() * moduleDatabase.hh (class ModuleDatabase): added typedef ImportSet (class ModuleDatabase): defaultOmodIncludes becomes an ImportSet * bufferPrint.cc (printDotSort, printVarSort, printSort): AUX_PARAMETERIZED_SORT -> AUX_STRUCTURED_SORT * mixfixParser.cc (makeTerm): AUX_PARAMETERIZED_SORT -> AUX_STRUCTURED_SORT * quotedIdentifierSymbol.cc (determineSort): AUX_PARAMETERIZED_SORT -> AUX_STRUCTURED_SORT * makeGrammar.cc (makeComponentProductions) (makeParameterizedSortProductions): AUX_PARAMETERIZED_SORT -> AUX_STRUCTURED_SORT * parameterization.cc (makeInstantiation): AUX_PARAMETERIZED_SORT -> AUX_STRUCTURED_SORT * token.hh (class Token): AUX_PARAMETERIZED_SORT -> AUX_STRUCTURED_SORT * auxProperty.cc (computeAuxProperty, sortName) (splitParameterizedSort, splitParameterList): AUX_PARAMETERIZED_SORT -> AUX_STRUCTURED_SORT * renaming.cc (printRenaming): use sortName for printing sort mappings (printRenamingType): use sortName * visibleModule.cc (showModule): print parameters * importModule.hh (getFreeParameterName): added * command.cc (showModule): print parameters 2005-04-18 Steven Eker * command.cc (showModule): use printSortTokenVector() (2 places) * preModule.hh (User): added decl for printSortTokenVector() * command.cc (showModule): use sortName() on sort and subsort tokens (operator<<): PreModule::Type& version; use sortName() (printSortTokenVector): added * prettyPrint.cc (operator<<): (Sort* version) simplified; no longer check PRINT_MIXFIX flag * view.cc (evaluate): use sortName() in error message about missing sort * import.cc (makeModule): use getFreeParameterTheory() rather than getParameterTheory() in 2 of 3 places to fix bug in the case there are bound parameters * importModule.hh (getFreeParameterTheory): added * parameterization.cc (makeParameterCopy): moved here from renameModule.cc (makeInstantiation): moved here from renameModule.cc (makeInstantiation): allow promotion from fmod to mod if a view has a system module as a target 2005-04-14 Steven Eker * banner.cc (printBanner): update copyright notice to 2005 * prelude.maude: changed prec and added format for _,_ in MAP; changed prec for _,_ in META-TERM ===================================Maude86a=========================================== 2005-04-13 Steven Eker * modules.yy (parameters): fixed value bug that is picked up by bison on darwin but not by bison on linux * process.cc (processSorts): avoid using name() for redecl'd sort (getSort): avoid using name() for undecl'd sort * renameModule.cc (localSort2): use sortName() * renaming.cc (makeCanonicalName): use sortName() * prettyPrint.cc (operator<<): Sort* version: use sortName() * auxProperty.cc (sortName): added * token.hh (class Token): added decl for sortName() * prelude.maude: added occurs op to LIST; added many standard views; changed the way split works in an attempt to get stable sort if incomparability happens to be transitive; added LIST*, SET*, MAP 2005-04-12 Steven Eker * prelude.maude: added append() operator to LIST * import.cc (makeModule): don't allow modules with parameters to be summed (processImports): don't allow modules with free parameters to be imported * importModule.hh (getNrParameters): added (getParameterTheory): use getNrParameters() * renameModule.cc (makeRenamedCopy): rewritten to handle parameters correctly * prelude.maude: added SET, moved COUNTER 2005-04-11 Steven Eker * prelude.maude: added TAO-SET, LIST and SORTABLE-LIST * importModule.hh (User): added decl for finishCopy() * renameModule.cc (makeInstantiation): rewritten to maintain a parameter map for parameter names in sorts that need to be mapped - this allows use to handle $ prefixing properly (makeInstantiation): avoid generating identity sort mappings when parameter X is instantiated by parameter X (makeInstantiation): avoid added identity sort mappings in the theory view case (finishCopy): added (makeInstantiation): use finishCopy() (makeParameterCopy): use finishCopy() (makeRenamedCopy): use finishCopy() * importModule.hh (User): added typedef ParameterMap * prelude.maude: give an explicit format for the _=[_]_ operator 2005-04-06 Steven Eker * renameModule.cc (makeInstantiation): fix argument indexing * importModule.hh (getNrFreeParameters): missing return (why didn't g++ catch this?) * renameModule.cc (makeInstantiation): added advisory for parameter clash (makeInstantiation): resolve parameter clashes by prefixing $ on free parameter name * moduleCache.cc (makeInstatiation): changed naming convention for parameters instantiated by parameters * renameModule.cc (makeInstantiation): only instantiate free parmeters OR bound parameters; copy bound parameters if we are not instantiating them (makeInstantiation): fixed bug: passing parameterArgs rather than names to makeInstatiation() for instantiating parameterized imports (makeInstantiation): added Assert()s for number of arguments (makeInstantiation): fixed bug where we were checking if findParameterIndex() returned != NONe rather than == NONE * importModule.cc (ImportModule): clear nrBoundParameters * importModule.hh (getParameterTheory): update Assert() * import.cc (makeModule): use getNrFreeParameters() * importModule.hh (getNrParameters): becomes getNrFreeParameters() * renameModule.cc (makeInstantiation): keep track of number of bound parameters * importModule.cc (deepSelfDestruct): comment out parameterTheories code * renameModule.cc (makeInstantiation): split parameter and theory view cases into seperate loops * importModule.hh (User): added data member nrBoundParameters; commented out data member parameterTheories 2005-04-04 Steven Eker * modules.yy (view): clear currentRenaming at the end in order to avoid memory corruption on subsequent call to cleanUpModuleExpression() 2005-04-01 Steven Eker * prelude.maude: added fth TRIV 2005-03-29 Steven Eker * renameModule.cc (makeInstantiation): keep track of parameters from enclosing module that have been used so we can handle things like PAIR{X,X} without adding duplicate parameters 2005-03-28 Steven Eker * import.cc (makeModule): rewritten to check instantiation arguments rigorously and provide detailed warnings * importModule.cc (findParameterIndex): added (addParameter): use findParameterIndex() * preModule.hh (User): updated decl for makeModule() * import.cc (processImports): pass flatModule to makeModule() (makeModule): take and pass enclosingModule * renameModule.cc (makeInstantiation): don't replace parameter in a parameterized sort if it is instantiated by a parameter form an enclosing module (localSort2): addded more info to Assert() (makeInstantiation): crude hack to make sure that paramaterized sorts coming from an imported parameterized module have their parameters replaced (makeInstantiation): do correct replacement of a parameter in a parameterized sort if it is instantiated by a parameter form an enclosing module 2005-03-25 Steven Eker * moduleCache.cc (makeInstatiation): rewrote name generation code * renameModule.cc (makeInstantiation): handle parameters instantiated by parameters from an enclosing module * import.cc (makeModule): gross hack to generate a vector for parameterArgs * importModule.hh (User): updated decl for makeInstatiation() * moduleCache.hh (User): updated decl for makeInstatiation() * moduleCache.cc (makeInstatiation): accept and pass parameterArgs * renameModule.cc (makeInstantiation): make instantiations of our parameterized imports rather than merely importing them (makeInstantiation): accept and pass parameterArgs 2005-03-23 Steven Eker * renameModule.cc: added handling for "theory views" (makeInstantiation): don't replace parameters in a parameterized sort that got instantiated by a "theory view" * auxProperty.cc (joinParameterList): fixed doubled { bug * renameModule.cc (makeInstantiation): added crude first attempt at parameterized sorts * token.hh (class Token): added decls for splitParameterList() and joinParameterList() * auxProperty.cc (joinParameterList): added (splitParameterList): added * import.cc (makeModule): check that the number of arguments matches the number of parameters in instantiation case; and check that parameter theories agree with from theories * view.hh (getToModule): added * importModule.hh (getParameterTheory): added (getNrParameters): added 2005-03-22 Steven Eker * renameModule.cc (makeInstantiation): fix bad use of renameSort() (makeInstantiation): only import modules that aren't parameters into copy * view.cc (evaluate): set status to GOOD if we pass all the checks * moduleCache.hh (User): added decl for makeInstatiation() * moduleCache.cc (makeInstatiation): added * import.cc (makeModule): first crude attempt at handling instantiation * importModule.hh (User): added decl for makeInstantiation() * renameModule.cc (makeInstantiation): added * view.hh (getToModule): added * view.cc (showView): use printRenaming() (showView): print final .\n * renaming.hh (class Renaming): added decls for printRenamingType() and printRenaming() * renaming.cc (printRenaming): added (operator<<): use printRenaming (printRenamingType): turn into member function * view.cc (showView): added * view.hh (isComplete): added * modules.yy (view): use setCurrentView(), CV (viewDeclaration): use CV * interpreter.cc (Interpreter): clear currentView * top.yy: added macro CV; delete variable currentView * view.hh (User): added decls for isComplete(), showView() * commands.yy (command): added "show view {name} ." command * interpreter.hh (endif): added decl for showView() * interpreter.cc (setCurrentView): added (complex version) (showView): added * interpreter.hh (setCurrentView): added (simple version) * interpreter.cc (makeClean): discard incomplete view * interpreter.hh (endif): added decls for getCurrentView(), setCurrentView() (*2) (getCurrentView): added (endif): added data member currentView * commands.yy (command): added "show views ." command * top.yy: declare KW_VIEWS * lexer.ll: added KW_VIEWS 2005-03-21 Steven Eker * modules.yy (view): call insertView() * interpreter.hh (endif): derive from ViewDatabase * mixfix.hh: added class ModuleDatabase and class ViewDatabase * viewDatabase.cc: created * viewDatabase.hh (class ViewDatabase): created * top.yy: added decl for sortDot * modules.yy (sortDot): added (viewDeclaration): use sortDot to allow overparsing for view sort mappings * view.cc (evaluate): added code to check for existence of polymorphic operators * modules.yy (viewDeclaration): clear bubble before viewToOpName (viewToOpName): allow single token operator names (viewToOpName): deleted (viewDeclaration): use endStatement in place of viewToOpName * view.cc (evaluate): added code to do basic operator existence check 2005-03-18 Steven Eker * moduleExpression.cc (deepSelfDestruct): rewritten to handle INSTANTIATION case (operator<<): parenthsize syntactically legal but semantically invalid module expressions correctly to avoid generating unparsable nonsense from users mistakes * moduleExpression.hh (getArguments): added * moduleExpression.cc (operator<<): handle INSTANTIATION case * import.cc (makeModule): warning for INSTANTIATION case * moduleExpression.cc (ModuleExpression): (instantiation version) added * moduleExpression.hh (class ModuleExpression): added INSTANTIATION to enum Type (class ModuleExpression): added decl for instantiation ctor (getModule): allow for instantiation (class ModuleExpression): added arguments data member * modules.yy (moduleExpr3): added (moduleExpr): use moduleExpr3 (argList): added * view.cc (evaluate): added code to check kinds and subsort relations * view.hh (User): added enum Status and data member status; added decl for evaluate() (User): added decl for dtor * view.cc (View): set status to INITIAL (regretToInform): set status to UNKNOWN (View): added dtor (regretToInform): self destruct all calculated stuff (finishView): use evaluate() (evaluate): added 2005-03-17 Steven Eker * view.hh (User): don't derive from BadFlag - a view should not become irredeemably bad * entity.cc (addUser): turned the Assert() for "already added user" into a DebugAdvisory() since it's possible for a module or view to use a module or view multiple times or in multiple ways (removeUser): turned the Assert() for "missing user" into DebugAdvisory() since if we add a user multiple times we may well remove the user that number of times * view.cc (regretToInform): added (View): init fromTheory, toModule (regretToInform): handle the case where fromTheory == toModule * view.hh (User): derive from Entity::User (User): added decl for regretToInform(); * entity.cc (removeUser): add entity name to debugging message if it is an ImportModule * entity.hh (class Entity): added decl for dummyToAllowDynamicCasts() if we are debugging * entity.cc (removeUser): fancier debugging messages * preModule.cc (regretToInform): removed removeUser() hack * moduleCache.cc (regretToInform): removed removeUser() hack * entity.hh (class Entity): moved definition of UserLt here * entity.cc (UserLt): added (addUser): use insert() rather than push_back() (removeUser): rewritten using set operations (informUsers): rewritten to be robust in the face of not knowing whether a call to regretToInform() will remove any particular user * entity.hh (class Entity): added struct UserLt and typedef UserSet; deleted typedef UserList; users becomes a UserSet 2005-03-16 Steven Eker * entity.cc (informUsers): 2nd attempt at fixing iterator invalidation bug * moduleCache.cc (regretToInform): call removeUser() * preModule.cc (regretToInform): call removeUser() * entity.cc (informUsers): fix nasty iterator invalidation bug * importModule.cc (ImportModule): Parent -> Entity::User * renameModule.cc (makeRenamedCopy, makeParameterCopy): dependentModules.append() -> addUser() * visibleModule.cc (VisibleModule): Parent -> Entity::User * visibleModule.hh (class VisibleModule): Parent -> Entity::User * preModule.cc (regretToInform): now takes Entity* * preModule.hh (User): derive from Entity::User rather than ImportModule::Parent; update decl for regretToInform() * moduleCache.hh (Parent): derive from Entity::User rather than ImportModule::Parent; update decl for regretToInform() * moduleCache.cc (destructUnusedModules): hasUsers() in place of hasDependents() (regretToInform): need to cast doomedEntity * importModule.cc (addImport): addUser() in place of dependentModules.append() (addParameter): addUser() in place of dependentModules.append() (deepSelfDestruct): removeUser() in place of removeDependent() (deepSelfDestruct): use informUsers() in place of much special purpose code() (regretToInform): added (removeDependent): deleted * importModule.hh (hasDependents): deleted (User): added decl for regretToInform() * entity.hh (hasUsers): added * importModule.hh (User): derive from Entity and Entity::User (User): deleted class Parent, updated ctor decl (User): deleted data members parent and dependentModules (User): deleted decl for removeDependent() * mixfix.hh: added class Entity * entity.cc: created * entity.hh: created * view.cc (finishView): evaluate from and to parts; check that from part is a theory * view.hh (class View): added data members fromTheory, toModule (class View) derive from BadFlag 2005-03-15 Steven Eker * view.cc (finishView): added stub * view.hh (class View): added decl for finishView() * modules.yy (viewToOpName): added (viewDeclaration): use viewToOpName to fix shift/reduce conflict and allow overparsing * top.yy: declare KW_VIEW to have type yyToken * lexer.ll: use RETURN() for KW_VIEW * modules.yy (view): add calls to fileTable; reset lexer mode at the end * top.yy: added currentView * modules.yy (view): add semantics (viewDeclaration): add op mappings * view.cc: created * mixfix.hh: added class View * view.hh: created 2005-03-11 Steven Eker * mixfixModule.hh (CommonTokens): added decks for printDotSort() and printVarSort() * bufferPrint.cc (prettyPrint): use printDotSort() (printDotSort): added (printVarSort): added (handleVariable): use printVarSort() * mixfixModule.hh (CommonTokens): updated decls for handleVariable(), printKind(); added decl for printSort() * bufferPrint.cc (printKind): take printFlags argument (handleVariable): take printFlags and pass it to printKind() (prettyPrint): pass printFlags to handleVariable() (printSort): added (printKind): use printSort() 2005-03-10 Steven Eker * prettyPrint.cc (operator<<): (Sort* version) only print parameterized sorts as multitoken if PRINT_MIXFIX flag is set * visibleModule.cc (showPolymorphAttributes): don't use operator<< for sorts in op-hooks (showPolymorphAttributes): handle the case that sorts in an op-hook might be kinds (showAttributes): don't use operator<< for sorts in op-hooks * mixfixModule.cc (nonTerminal): (Sort* version) fix potential rather than actual bug in that we were passing TERM_TYPE rather than type (in all current uses, type is bound to TERM_TYPE) * doParse.cc (getParserStats): pass back correct value for nrNonterminals now that iter & oft variable nonterminals are allocated on demand * makeGrammar.cc (makeParameterizedSortProductions): use GARBAGE as initial map entry (makeSymbolProductions): use GARBAGE as initial map entry * prettyPrint.cc (operator<<): (Sort* version) be recursive in the kind case (operator<<): (Sort* version) handle parameterized sorts 2005-03-09 Steven Eker * mixfixParser.cc (makeTerm): changed Assert() to allow for parameterized sorts in MAKE_VARIABLE case * makeGrammar.cc (makeComponentProductions): add syntax for otf variables of parameterized sorts; update syntax for otf variables of non parameterized sorts that happen to be the lead token of a parameterized sort (makeSpecialProductions): take leadTokens into account for the CONTAINS_COLON case (makeParameterizedSortProductions): fixed nasty bug where we were using iterSymbols instead of leadTokens (makeComponentProductions): use gatherAny rather than emptyGather where we have a nonterminal * mixfixModule.hh (CommonTokens): added decl for makeParameterizedSortProductions() * makeGrammar.cc (makeParameterizedSortProductions): added (makeGrammar): call makeParameterizedSortProductions() * mixfixModule.hh (CommonTokens): added data member leadTokens * makeGrammar.cc (makeSymbolProductions): handle the case where we've already seen an iter symbol with the same name * mixfixModule.hh (CommonTokens): deletd decl for iterSymbolNonTerminal() (CommonTokens): typedef IntMap; * mixfixModule.cc (iterSymbolNonTerminal): deleted * entry.cc (addOpDeclaration): don't update iterSymbols * makeGrammar.cc (makeSymbolProductions): use new iterSymbols together with newNonTerminal() (makeSpecialProductions): use new iterSymbols semantics (2 places) * mixfixModule.hh (CommonTokens): iterSymbols changed from IntSet to map * makeGrammar.cc (makeGrammar): initialize nextNonTerminal; don't use iterSymbols * mixfixModule.hh (CommonTokens): added decl for newNonTerminal() * mixfixModule.cc (newNonTerminal): added * mixfixModule.hh (findIterSymbolIndex): deleted (CommonTokens): added data member nextNonTerminal 2005-03-08 Steven Eker * makeGrammar.cc (makeSpecialProductions): use new insertIterSymbolTerminal() convention * mixfixParser.hh (class MixfixParser): updated decl for insertIterSymbolTerminal() * mixfixParser.cc (insertIterSymbolTerminal): use iterSymbolNameCode rather than iterSymbolIndex; no need to resize iterSymbolTerminals (translateSpecialToken): use new definition of iterSymbolTerminals * mixfixParser.hh (class MixfixParser): updated decl for insertVariableTerminal() (class MixfixParser): added typedef IntMap; change iterSymbolTerminals from Vector to IntMap * mixfixParser.cc (insertVariableTerminal): use sortNameCode rather than sortIndex (MixfixParser): don't initialize variableTerminals (translateSpecialToken): use map rather than Vector; look up sortNameCode directly rather than sortIndex * makeGrammar.cc (makeComponentProductions): pass sortNameCode rather than sortIndex to insertVariableTerminal() * mixfixParser.hh (class MixfixParser): change variableTerminals from Vector to map * token.hh (class Token): fix decl for skipSortName() * auxProperty.cc (skipSortName): parameterized arg needs to be passed by reference * makeGrammar.cc (makeComponentProductions): insert productions for multitoken versions of parameterized sorts (makeComponentProductions): removed comment - sortIndex is actually used in MixfixParser::getSort() * token.hh (class Token): added decl for splitParameterizedSort() * auxProperty.cc (splitParameterizedSort): added * token.cc (splitKind): use clear() 2005-03-07 Steven Eker * token.hh (class Token): updated decl for skipSortName() * token.cc (splitKind): use new skipSortName * auxProperty.cc (skipSortName): rewritten to take account of parameterized sorts and moved here (computeAuxProperty): rewritten to take account of parameterized sorts and moved here * token.cc (computeAuxProperty): handle AUX_PARAMETERIZED_SORT * quotedIdentifierSymbol.cc (determineSort): handle AUX_PARAMETERIZED_SORT * token.hh (class Token): added AUX_PARAMETERIZED_SORT 2005-02-28 Steven Eker * modules.yy (sortName): rewritten to fix a bunch of symmetric reduce/reduce conflicts 2005-02-25 Steven Eker * top.yy: added fragClear(), fragStore(), fragments * modules.yy (sortNameFrags): added (sortNameFrag): added (sortName): rewritten * top.yy: add back sortToken * modules.yy (sortName): recursive definition * top.yy: sortToken -> sortName * modules.yy: type -> typeName, sortToken -> sortName, sortTokens -> sortNames, sortTokenList -> sortNameList 2005-02-24 Steven Eker * modules.yy (startKeyword): added KW_ENDV (inert): added KW_FROM (midKeyword): moved KW_IS to inert (endToken, tokenBarEqual, tokenBarIf, tokenBarColon) (tokenBarColonTo): removed KW_IS * lexer.ll: added KW_VIEW, KW_FROM, KW_ENDV * top.yy (item): added view; added KW_VIEW, KW_FROM, KW_ENDV * modules.yy (view, viewDecList, viewDeclaration): added 2005-02-23 Steven Eker * renameModule.cc (makeParameterCopy): first attempt at label renaming (makeParameterCopy): do local stuff first and imported stuff second since with our naive approach will could get dup label mappings which will safely be ignored by addSortAndLabelMappings() * makeGrammar.cc (makeComponentProductions): use find() on bubbleComponents (2 places) (makePolymorphProductions): use find() on bubbleComponents * mixfixModule.hh (CommonTokens): bubbleComponents becomes a set 2005-02-22 Steven Eker * makeGrammar.cc (makeLabelProductions): use potentialLabels * mixfixModule.hh (insertLabels): becomes insertPotentialLabels(); take const set& (CommonTokens): IntSet labels becomes set potentialLabels * process.cc (process): use insertPotentialLabels() and potentialLabels * preModule.cc (addStatement): use potentialLabels * preModule.hh (Parent): IntSet labels becomes set potentialLabels 2005-02-18 Steven Eker * import.cc (processImports): use makeParameterCopy() * importModule.cc (addParameter): store parameterTheory in importModules rather than parameterTheories * moduleCache.hh (Parent): added decl for makeParameterCopy() * moduleCache.cc (makeParameterCopy): added * token.hh (class Token): added declaration for parameterRename() * token.cc (parameterRename): added * renaming.cc (addSortAndLabelMappings): added * renaming.hh (class Renaming): added decl for addSortAndLabelMappings() * renameModule.cc (makeParameterCopy): added 2005-02-15 Steven Eker * import.cc (processImports): handle module expression for parameter theory * preModule.hh (Parent): updated decl for addParameter() (Parent): updated struct Parameter * preModule.cc (addParameter): take module expression * modules.yy (parameter): allow parameters to be module expressions 2005-02-10 Steven Eker * importModule.cc (deepSelfDestruct): use FOR_EACH_CONST() on importedModules; handle parameters * modules.yy (module): need to set current module before we parse parameters so that parameters get added to the correct module * import.cc (processImports): use FOR_EACH_CONST() in explicity import code (processImports): handle parameters * modules.yy (parameter): call addParameter() * preModule.hh (Parent): added decl for addParameter() (Parent): added data member parameters * preModule.cc (addParameter): added * preModule.hh (Parent): added struct Parameter * importModule.hh (class ImportModule): added decl for addParameter() * mixfixModule.hh (canHaveAsParameter): added * importModule.cc (addParameter): added * importModule.hh (class ImportModule): added data members parameterNames and parameterTheories * importModule.cc (addImport): simplified condition 2005-02-08 Steven Eker * lexer.ll (id): recognize :: { } tokens * top.yy: declare inert, '{', '}', KW_COLON2 * modules.yy (parameters): added parameter syntax (inert): added (identifier): use inert (tokenBarDot): use inert (endToken): use inert (tokenBarColonTo, tokenBarCommaLeft): use inert * import.cc (processImports): no automatic imports for theories 2005-01-19 Steven Eker * mixfixModule.hh (CommonTokens): deleted static data member concealed and decl for concealSymbols() * dagNodePrint.cc (prettyPrint): use concealedSymbol() * interpreter.hh (endif): added decl for concealedSymbol() * interpreter.cc (concealedSymbol): added * prettyPrint.cc (concealSymbols): deleted * userLevelRewritingContext.hh (class UserLevelRewritingContext): deleted decls for selectSymbols(), excludeModules(), selectBreakSymbols(); deleted static data members selected, excluded, breakSymbols * interpreter.hh (traceId, excludedModule): added * userLevelRewritingContext.cc (excludeModules, selectSymbols): deleted (dontTrace): use excludedModule and traceId instead of excluded and selected * interpreter.hh (breakId): added * interact.cc (selectBreakSymbols): deleted (handleDebug): use breakId() instead of breakSymbols * interpreter.hh (printConceal, traceExclude, breakSelect) (traceSelect): rewritten, moved here (endif): added decl for updateSet() * interpreter.cc (updateSet): added * interpreter.hh (endif): added data members traceIds, breakIds, excludedModules, concealedSymbols * userLevelRewritingContext.cc (dontTrace): update testing of excluded, selected * interact.cc (selectBreakSymbols): rewritten * userLevelRewritingContext.cc (selectSymbols): rewritten (excludeModules): rewritten * interact.cc (handleDebug): update testing of breakSymbols * userLevelRewritingContext.cc: selected, breakSymbols changed from IntSet to set * userLevelRewritingContext.hh (class UserLevelRewritingContext): selected, excluded, breakSymbols changed from IntSet to set (class UserLevelRewritingContext): updated decls for selectSymbols(), excludeModules(), selectBreakSymbols() * interpreter.cc (printConceal, traceExclude, breakSelect) (traceSelect): clear() replaces makeEmpty() * interpreter.hh (endif): selected changed from IntSet to set 2005-01-18 Steven Eker * userLevelRewritingContext.cc (tracePreScApplication) (tracePreRuleRewrite, tracePreEqRewrite): support TRACE_BODY option * interpreter.hh (endif): added TRACE_REWRITE and TRACE_BODY to DEFAULT_FLAGS * userLevelRewritingContext.cc (tracePreScApplication) (tracePostRuleRewrite, tracePreRuleRewrite, tracePostEqRewrite) (tracePreEqRewrite): implement TRACE_REWRITE option * trial.cc (traceBeginRuleTrial): use getFlag() rather than traceRuleFlag, traceSubstitutionFlag (traceBeginScTrial): use getFlag() rather than traceScFlag, traceSubstitutionFlag (traceEndFragment): use getFlag() rather than traceSubstitutionFlag * userLevelRewritingContext.cc (tracePreRuleRewrite) (tracePreScApplication): use getFlag() rather than traceSubstitutionFlag * trial.cc (traceBeginEqTrial): use getFlag() rather than traceEqFlag (traceBeginEqTrial): use getFlag() rather than traceSubstitutionFlag * userLevelRewritingContext.cc: deleted defs for trace flags below * userLevelRewritingContext.hh (class UserLevelRewritingContext): deleted static members traceConditionFlag, traceWholeFlag, traceSubstitutionFlag, traceSelectFlag, traceScFlag, traceEqFlag, traceRuleFlag (setTraceConditionFlag, setTraceWholeFlag) (setTraceSubstitutionFlag, setTraceSelectFlag, setTraceScFlag) (setTraceEqFlag, setTraceRuleFlag): deleted * userLevelRewritingContext.cc (dontTrace): use getFlag() rather than traceSelectFlag (tracePreEqRewrite): use getFlag() rather than traceEqFlag (tracePostEqRewrite): use getFlag() rather than traceWholeFlag (tracePreEqRewrite): use getFlag() rather than traceWholeFlag (tracePreRuleRewrite): use getFlag() rather than traceRuleFlag (tracePreRuleRewrite): use getFlag() rather than traceWholeFlag (tracePostRuleRewrite): use getFlag() rather than traceWholeFlag (tracePreScApplication): use getFlag() rather than traceScFlag (tracePreScApplication): use getFlag() rather than traceWholeFlag (tracePreEqRewrite): use getFlag() rather than traceSubstitutionFlag (makeSubcontext): use getFlag() rather than traceConditionFlag 2005-01-17 Steven Eker * interpreter.hh (endif): added TRACE_REWRITE and TRACE_BODY to enum Flags * top.yy: declare traceOption and KW_BODY; delete decl for KW_CONTEXT * lexer.ll: added KW_BODY; deleted KW_CONTEXT * commands.yy (command): use traceOption (traceOption): added; include syntax for set trace rewrite and set trace body * mixfixModule.hh (CommonTokens): deleted decls for 7 setPrint*() functions and the commented out functions themselves 2005-01-07 Steven Eker * prelude.maude: added rat print option 2005-01-06 Steven Eker * prelude.maude: added print option hooks 2005-01-05 Steven Eker * prelude.maude: added PrintOptions; metaPrettyPrint() now takes PrintOptionSet arg; backward compatibility metaPrettyPrint() added * interpreter.hh (endif): renumbered enum PrintFlags * main.cc (main): use setPrintFlag() instead of setPrintMixfix() * mixfixModule.hh (CommonTokens): updated decls for printTokens(), printTails() and printPrefixName() * bufferPrint.cc (printTokens): use printFlags instead of printFormat (printPrefixName, printTails): use printFlags instead of printFormat (printTokens): added printFlags arg (printTails): added printFlags arg (printPrefixName): added printFlags arg (prettyPrint): pass printFlags to printTokens(), printTails() (handleIter): pass printFlags to printPrefixName() (prettyPrint): pass printFlags to printPrefixName() * prettyPrint.cc (printVariable): use getPrintFlag() instead of printWithAliases * bufferPrint.cc (prettyPrint): use printFlags instead of printMixfix, printWithParens, printFlat * mixfixModule.hh (setPrintMixfix, setPrintWithParens) (setPrintWithAliases, setPrintFlat, setPrintGraph) (setPrintConceal, setPrintFormat): deleted * prettyPrint.cc: deleted static print* variables (operator<<): use getPrintFlag() in place of printGraph (printTokens): use getPrintFlag() in place of printFormat (printPrefixName): use getPrintFlag() in place of printFormat (printTails): use getPrintFlag() in place of printFormat * mixfixModule.hh (CommonTokens): deleted static data members printMixfix, printWithParens, printWithAliases, printFlat, printGraph, printConceal, printFormat * dagNodePrint.cc (prettyPrint): use getPrintFlag() in place of printMixfix, printWithParens, printFlat, printConceal * termPrint.cc (prettyPrint): use getPrintFlag() in place of printMixfix, printWithParens, printFlat * top.yy: added yyPrintFlag added decl for printOption * commands.yy (command): use setPrintFlag() for 3 print cases (printOption): added (command): combine all print options using printOption and setPrintFlag() * bufferPrint.cc (bufferPrint): handle printFlags arg * mixfixModule.hh (CommonTokens): updated buffer print op decls * bufferPrint.cc (handleIter): handle printFlags arg (handleMinus): handle printFlags arg (handleDivision): handle printFlags arg (prettyPrint): pass printFlags arg to handleIter(), handleMinus(), handleDivision() (prettyPrint): take printFlags arg * dagNodePrint.cc (computeColor, handleIter, handleMinus) (handleDivision, prettyPrint): use getPrintFlag() * termPrint.cc (computeColor, handleIter, handleMinus) (handleDivision): use getPrintFlag() * interpreter.hh (getPrintFlag): added * prettyPrint.cc (operator<<): use getPrintFlag() * interpreter.cc (Interpreter): init printFlags * interpreter.hh (endif): added decl for setPrintFlag() * interpreter.cc (setPrintFlag): added * interpreter.hh (endif): added enum PrintFlags; moved print flags here (endif): added data member printFlags (getPrintFlags): added 2005-01-04 Steven Eker * loopMode.cc (printBubble): print unknown tokens of the form \c with naively rather than skipping them altogther - this at least handles _\/_ pretty printed in mixfix mode correctly ===================================Maude86=========================================== 2004-12-23 Steven Eker * execute.cc (eRewrite): call clearInterrupt() after eventLoop() exits with an interrupt * userLevelRewritingContext.hh (class UserLevelRewritingContext): added decl for clearInterrupt() * interact.cc (clearInterrupt): added 2004-12-22 Steven Eker * prelude.maude: added portal <> operator; made Portal a subsort of Configuration * socket.maude: removed Nat args from receive message; allowing specification of min and max number of bytes we will deal with seems more trouble than its worth removed protocol family arg from createClientTcpSocket and createServerTcpSocket; it seems unlikely we will support anything other than IPv4 for the immediate future and we can always rewrite outgoing messages for backwards compatibity if we go to a more general interface added reason arg to closedSocket message since sometimes we will want to know if a socket closed naturally or because of a fatal error 2004-12-21 Steven Eker * socket.maude: createServerTcpSocket now takes a backlog length; acceptedClientMsg now passes back a client IP address * execute.cc (eRewrite): call root() to force the virtual dag to be concretized before doing another fairRewrite() 2004-12-20 Steven Eker * execute.cc (eRewrite): call eventLoop() 2004-12-15 Steven Eker * commands.yy (command): fixed nasty bug with optDebug KW_EREWRITE where we were failing to initialize number2 to NONE * execute.cc (eRewrite): call generateErewrite() rather than generateFrewrite() 2004-12-09 Steven Eker * prelude.maude: added _&_ : Nat Int -> Nat since anding with a nat will remove any high order 1s 2004-12-08 Steven Eker * number-sorts.maude: created * visibleModule.cc (showPolymorphAttributes): handle metadata * renameModule.cc (donateOps2): handle metadata in polymorphs * process.cc (processOps): pass metadata to addPolymorph() * mixfixModule.hh (CommonTokens): updated addPolymorph() decl (getPolymorphMetadata): added * entry.cc (addPolymorph): take and handle metadata arg * mixfixModule.hh (CommonTokens): added metadata field to struct Polymorph * renameModule.cc (donateOps2): copy metadata * command.cc (printAttributes): handle metadata 2004-12-07 Steven Eker * visibleModule.hh (class VisibleModule): updated decl for showAttributes() * visibleModule.cc (showAttributes): take declIndex rather than decl; handle metadata (showDecls): new showAttributes() convention * entry.cc (addOpDeclaration): store metadata * ops.cc (setMetadata): check that metadata is actually a string * modules.yy (attrKeyword2): added KW_METADATA * lexer.ll (ID_MODE): added metadata * top.yy: added KW_METADATA * preModule.hh (Parent): added decl for setMetadata() * ops.cc (setMetadata): added * modules.yy (attribute): allow metadata in operator attributes * preModule.cc (OpDef): initialize metadata to NONE * preModule.hh (Parent): added metadata field to struct OpDef * renameModule.cc (donateOps2): pass dummy metadata arg to addOpDeclaration() * process.cc (processOps): pass metadata arg to addOpDeclaration() * mixfixModule.hh (CommonTokens): updated decl for addOpDeclaration() * entry.cc (addOpDeclaration): added metadata arg * metadataStore.cc (insertMetadata): added opdecl version (getMetadata): added opdecl version * metadataStore.hh (class MetadataStore): rewritten to handle symbol/opdecls * prelude.maude: fixed 3 missing ctors ===================================Maude85a=========================================== 2004-12-06 Steven Eker * loopMode.cc (doLoop): check AUTO_CLEAR_RULES before calling resetRules() 2004-12-02 Steven Eker * prelude.maude: lift idempotence equation to TypeListSet combined kind sets with sort sets and type sets deleted kindSetSymbol and emptyKindSetSymbol op hooks added EmptyTypeSet to avoid the issue of whether none belongs to SortSet or KindSet use ditto for TermList ctor 2004-12-01 Steven Eker * prelude.maude: added TypeListSets, maximalAritySet; change prec of _;_ : SortSet SortSet-> SortSetto 43 to avoid interaction with __ : TypeList TypeList -> TypeList * execute.cc (rewrite): make calling resetRules() conditional on AUTO_CLEAR_RULES (fRewrite, eRewrite): make calling resetRules() conditional on AUTO_CLEAR_RULES * commands.yy (command): set clear counters -> set clear rls * top.yy: removed KW_COUNTERS * lexer.ll: removed counters; rule|rules synonym for rls * interpreter.hh (endif): AUTO_CLEAR_COUNTERS -> AUTO_CLEAR_RULES 2004-11-30 Steven Eker * top.yy: added KW_COUNTERS * lexer.ll: added counters * commands.yy (command): added set clear counters on/off * interpreter.hh (endif): added AUTO_CLEAR_COUNTERS to enum Flags; added to DEFAULT_FLAGS 2004-11-22 Steven Eker * prelude.maude: added format attr to trace ctor 2004-11-17 Steven Eker * prelude.maude: added trace ctors; added metaSearchPath() 2004-11-16 Steven Eker * profileModule.cc: output a percentage for number of rewrites * commands.yy (command): added show search path labels . * interpreter.hh (endif): added decl for showSearchPathLabels() * lexer.ll: recognize label in initial mode * search.cc (showSearchPathLabels): added 2004-10-14 Steven Eker * diophantine.maude: diophantineSystemSolve -> natSystemSolve 2004-09-16 Steven Eker * dagNodePrint.cc (prettyPrint): added handling for null pointer in debugging case 2004-09-14 Steven Eker * entry.cc (newFancySymbol): handle MATRIX_OP_SYMBOL * specialSymbolTypes.cc (MACRO): added MatrixOpSymbol * symbolType.hh (class SymbolType): added MATRIX_OP_SYMBOL 2004-09-10 Steven Eker * prelude.maude: glbSorts now defined on types 2004-09-09 Steven Eker * prelude.maude: made notFound and unbounded into ctors; added TypeSet 2004-08-26 Steven Eker * prelude.maude: added extra decl for _/_ to solve ctor problem 2004-08-25 Steven Eker * prelude.maude: added PosRat to RAT to solve assoc problems with max op decls 2004-08-24 Steven Eker * prelude.maude: added min and max to NAT, INT and RAT ===================================Maude85=========================================== 2004-08-03 Steven Eker * commands.yy (command): handle erewrite * interpreter.hh (endif): added decls for eRewrite() and eRewriteCont() * maudemlBuffer.hh (class MaudemlBuffer): added decl for generateErewrite() * maudemlBuffer.cc (generateErewrite): added * execute.cc (eRewrite): added (eRewriteCont): added 2004-07-12 Steven Eker * entry.cc (newFancySymbol): handle SocketManagerSymbol rather than SystemSymbol * symbolType.hh (class SymbolType): SYSTEM_SYMBOL replaced by SOCKET_MANAGER_SYMBOL * specialSymbolTypes.cc (MACRO): SystemSymbol replaced by SocketManagerSymbol 2004-07-09 Steven Eker * entry.cc (newFancySymbol): handle SYSTEM_SYMBOL * specialSymbolTypes.cc (MACRO): added SYSTEM_SYMBOL * symbolType.hh (class SymbolType): added SYSTEM_SYMBOL 2004-06-29 Steven Eker * prelude.maude: make module selectors work on theories ===================================Maude84d=========================================== 2004-06-15 Steven Eker * renaming.cc (typeMatch): fixed bug where we weren't catching the case where the arities differed 2004-06-03 Steven Eker * entry.cc (newFancySymbol): added case for CounterSymbol * specialSymbolTypes.cc (MACRO): added CounterSymbol * symbolType.hh (class SymbolType): added COUNTER_SYMBOL 2004-06-02 Steven Eker * main.cc (main): handle -random-seed= flag (printHelp): added lines for -random-seed= and -xml-log= flags * entry.cc (newFancySymbol): added case for RandomOpSymbol * specialSymbolTypes.cc (MACRO): added RandomOpSymbol * symbolType.hh (class SymbolType): added RANDOM_OP_SYMBOL 2004-06-01 Steven Eker * prelude.maude: added fmod RANDOM ===================================Maude84c=========================================== 2004-05-25 Steven Eker * import.cc (getModule): don't fall into mutually recursive import warning * fixUp.cc (fixUpSymbols): added check for missing identity * ops.cc (setIdentity): check for missing identity (setIdentity): unmade change - parser never calls this function with an empty bubble! 2004-05-24 Steven Eker * mixfixModule.cc (fixUpBubbleSpec): pass qidSymbol as a Symbol* and check it * fixUp.cc (fixUpSymbols): use new fixUpBubbleSpec() convention * mixfixModule.hh (CommonTokens): updated decl for fixUpBubbleSpec() * fixUp.cc (fixUpSymbols): use dynamic_cast<> instead of safeCast() * mixfixModule.cc (fixUpBubbleSpec): check for missing symbols 2004-05-19 Steven Eker * fixUp.cc (fixUpSymbols): use safeCast() (findHookSymbol): rewritten to avoid running of the end of the Vector if the hook has bad syntax * entry.cc (addOpDeclaration): added warnings for ad hoc overloaded operators that have same domain but different ranges 2004-05-18 Steven Eker * prelude.maude: changed definition of ['FOO] so that it works with theories * importModule.hh (class ImportModule): updated decl for * importModule.cc (addImport): pass lineNumber by value addImport() 2004-05-17 Steven Eker * commands.yy (importMode): ModuleDatabase -> ImportModule (3 places) * moduleCache.cc (makeSummation): use new addImport() conventions * import.cc (processImports): rewritten to use new addImport() conventions * moduleDatabase.cc (setAutoImport): ImportMode now belongs to ImportModule * moduleDatabase.hh (class ModuleDatabase): deleted enum ImportMode * importModule.hh (class ImportModule): added enum ImportMode; updated decl for addImport() * importModule.cc (addImport): take mode and lineNumber; do importation checks here * prelude.maude: added thSymbol and fthSymbol * import.cc (processImports): added warnings for violation of importation rules by automatic imports * modules.yy (declaration): use moduleExprDot (moduleExprDot): added (moduleExprDot): added (mapping): use sortToken rather than token for sort mappings; use token rather than identifier for label mappings 2004-05-12 Steven Eker * top.yy: added decl for endsInDot * modules.yy (endStatement): added (endsInDot): added (endToken): redefined to eliminate ENDS_IN_DOT (endTokens): endsInDot replaces '.' (2 places) (tokenBarDot): redefined to eliminate ENDS_IN_DOT (endStatement): use dot * top.yy: deleted decl for tokenBarLt * modules.yy (subsortList): added (listBarLt): deleted (listBarDot): deleted (typeAttr): added (domainRangeAttr): use typeAttr (typeDot): added (badType): added (typeAttr): use badType (tokenBarLt): deleted * token.cc (dropChar): added * modules.yy (identifier): added ENDS_IN_DOT (tokenBarColonTo): added ENDS_IN_DOT (tokenBarCommaLeft): added ENDS_IN_DOT (sortToken): rule out ENDS_IN_DOT and , (sortTokenList): added (dot): added to try to recover from missing space * lexer.ll (id): added decl for ENDS_IN_DOT * top.yy: added ENDS_IN_DOT 2004-05-11 Steven Eker * import.cc (processImports): check to see that theories are only imported using the including mode (processImports): check that module types are legal for import * mixfixModule.hh (CommonTokens): added enum Bits (isTheory): added (canImport): added * preModule.cc (addStatement): check for rules in functional theory/module * preModule.hh (Parent): added decl for compatible() * preModule.cc (PreModule): init startTokenCode (compatible): added (finishModule): use compatible() * preModule.hh (Parent): added data member startTokenCode * modules.yy (startModule): added * lexer.ll: seperated out omod * top.yy: put KW_OMOD back added nonterminal startModule * preModule.cc (PreModule): handle start token * commonTokens.cc (CommonTokens): added th fth mod fmod omod obj endth endfth endm endfm endom endo jbo * commonTokens.hh (class CommonTokens): added th fth mod fmod omod obj endth endfth endm endfm endom endo jbo * preModule.hh (Parent): updated decls for ctor and finishModule() * modules.yy (startKeyword2): deleted KW_ENDTH KW_ENDFTH KW_ENDFM KW_ENDOM * top.yy: deleted KW_ENDTH KW_ENDFTH KW_ENDFM KW_ENDOM KW_TH KW_FTH KW_FMOD KW_OMOD * lexer.ll: merged th fth fmod omod into mod; merged endth endfth endfm into endm * modules.yy: deleted productions for endfm notEndfm endm notEndm endom notEndom (module): simplified to a single production (oDecList): deleted (fDecList): deleted (declaration): merged with fDeclaration and oDeclaration * top.yy: deleted nonterminals notEndfm notEndm notEndom * modules.yy (startKeyword2): added KW_ENDTH KW_ENDFTH * top.yy: added KW_TH KW_FTH KW_ENDTH KW_ENDFTH * lexer.ll (id): added keywords th fth endth endfth 2004-05-07 Steven Eker * ops.cc (setIdentity): added check for empty identity; didn't fix our proble though since we never get here with an empy identity; reverted change ===================================Maude84b=========================================== 2004-04-27 Steven Eker * command.cc (showModule): use moduleEndString() * visibleModule.cc (showModule): use moduleEndString() * mixfixModule.cc (moduleEndString): added * mixfixModule.hh (CommonTokens): added decl for moduleEndString() * moduleCache.cc (showCreatedModules): use moduleTypeString() * moduleDatabase.cc (showNamedModules): use moduleTypeString() * command.cc (showModule): use moduleTypeString() * mixfixModule.cc (moduleTypeString): added * mixfixModule.hh (CommonTokens): added FUNCTIONAL_THEORY and SYSTEM_THEORY to enum ModuleType (CommonTokens): added decl for moduleTypeString() * import.cc (processImports): use new autoImports * preModule.hh (Parent): data member autoImports becomes a ModuleDatabase::ImportMap (getAutoImport): becomes getAutoImports() (getNrAutoImports): deleted * preModule.cc (finishModule): use getAutoImports() in place of getIncludes() * moduleDatabase.cc (setAutoImport): use autoImports instead of defaultIncludes * moduleDatabase.hh (class ModuleDatabase): added ImportMap typedef; getIncludes() becomes getAutoImports(); data member defaultIncludes becomes autoImports (getAutoImports): replaces getIncludes() * prelude.maude: set include BOOL becomes set protect BOOL * moduleDatabase.cc (setInclude): becomes setAutoImport() * moduleDatabase.hh (class ModuleDatabase): setInclude() becomes setAutoImport() * top.yy: added yyImportMode to union * commands.yy (importMode): added (command): use setAutoImport() * moduleDatabase.hh (class ModuleDatabase): added enum ImportMode * top.yy: added tokens KW_PROTECT and KW_EXTEND * lexer.ll: added keywords protect and extend ===================================Maude84a=========================================== 2004-03-10 Steven Eker * modules.yy (fDeclaration): fixed nasty bug where we were not popping the final module expression from the stack with the result that syntax errors caused the deletion of live module expressions via cleanUpModuleExpression() with resulting memory corruption 2004-03-03 Steven Eker * prelude.maude: strats for _and-then_ and _or-else_ become (1 0) 2004-02-27 Steven Eker * main.cc (main): added -no-banner option (printHelp): added -no-banner option * interpreter.cc: removed extern ModuleCache moduleCache hack * import.cc: deleted moduleCache global variable (processImports): use interpreter instead of moduleCache * interpreter.cc (showModules): don't use moduleCache * interpreter.hh (endif): inherit from ModuleCache * interpreter.cc (showModules): use showCreatedModules() * moduleCache.cc (showModules): becomes showCreatedModules() * moduleCache.hh (Parent): showModules() -> showCreatedModules() * mixfixModule.cc (copyPolymorph): deleted * mixfixModule.hh (CommonTokens): deleted commented out decl for copyPolymorph() ===================================Maude84=========================================== 2004-02-25 Steven Eker * commands.yy (command): remove show all modules . as it conflicts with show all . * interpreter.cc (showModules): use showNamedModules() * moduleDatabase.cc (showModules): renamed to showNamedModules() * moduleDatabase.hh (class ModuleDatabase): showModules() -> showNamedModules() * commands.yy (command): added commands show modules . and show all modules . * top.yy: added KW_MODULES * lexer.ll: added keyword modules * moduleDatabase.hh (class ModuleDatabase): added decl for showModules() * moduleDatabase.cc (showModules): added * preModule.hh (getModuleType): added * moduleCache.hh (Parent): adde decl for showModules * moduleCache.cc (showModules): added * interpreter.hh (endif): added decl for showModules() * interpreter.cc (showModules): added 2004-02-24 Steven Eker * modules.yy (fDeclaration): added call to cleanUpModuleExpression() * top.yy: added forward decl for cleanUpModuleExpression() * bottom.yy (cleanUpModuleExpression): added * moduleCache.cc (makeRenamedCopy): fixed bug where we were forgetting to delete the canonical renaming that we made if the module we wanted was in cache * top.yy: use explicit stack to hold module expressions; updated %union; fixed + vs * prec bug * modules.yy (moduleExpr): rewritten so that module expression pointers are stored on an explicit stack rather than the bison stack; this allows us to free memory after an error (renaming): same trick as above (fDeclaration): new module expression conventions * mixfixModule.cc (findSymbol): check that true and false are in the same connected component before trying to make a sort test * makeGrammar.cc (makeBoolProductions): check that true and false are in the same connected component before adding syntax for sort tests * entry.cc (addOpDeclaration): check for duplicate SystemTrue and SystemFalse symbols 2004-02-23 Steven Eker * fixUp.cc (fixUpSymbols): check for identity clash between dupicate polymorphic operators * entry.cc (addPolymorph): check for dups * mixfixModule.hh (CommonTokens): added decl for domainAndRangeMatch() (CommonTokens): updated decl for findPolymorphIndex() * mixfixModule.cc (findPolymorphIndex): handle domain and range argument (domainAndRangeMatch): added * renameModule.cc (fixUpDonatedOps2): rewrote polymorph fixup code to handle distinct polymorphs with the same name 2004-02-20 Steven Eker * import.cc (processImports): call destructUnusedModules() * moduleCache.cc: (destructUnusedModules): added * importModule.hh (hasDependents): added * moduleCache.hh (Parent): added decl for destructUnusedModules() 2004-02-17 Steven Eker * prelude.maude: added metasyntax and hooks for summation and renaming * moduleExpression.cc (deepSelfDestruct): can't assume module member is valid unless we are a renaming * preModule.hh (Parent): deleted decl for importModule() * import.cc (processImports): use getModule() (makeModule): rewritten using getModule() (importModule): deleted * moduleExpression.cc (ModuleExpression): store module name as a token (operator<<): new getModuleName() semantics * moduleExpression.hh (class ModuleExpression): moduleName becomes a token in order to have line number (getModuleName): updated return type * import.cc (getModule): added * moduleCache.cc (makeSummation): compute correct module type using join() * mixfixModule.hh (join): added 2004-02-13 Steven Eker * importModule.hh (class ImportModule): added decl for dtor * importModule.cc (~ImportModule): added * preModule.cc (PreModule): use deepSelfDestruct() * moduleExpression.cc (deepSelfDestruct): added * moduleExpression.hh (class ModuleExpression): added decl for deepSelfDestruct() * import.cc (makeModule): handle list<> for summations * moduleExpression.cc (ModuleExpression): handle flattening of nested summations (operator<<): handle list<> for summations * moduleExpression.hh (class ModuleExpression): store summations as a list<> 2004-02-11 Steven Eker * import.cc (makeModule): use ModuleCache version of makeRenamedCopy() * importModule.hh (class ImportModule): deleted decls for makeSummation() and moduleCompare() * renameModule.cc (makeSummation): deleted (moduleCompare): deleted * importModule.hh (class ImportModule): updated decl for makeRenamedCopy() * renameModule.cc (makeRenamedCopy): rewritten using new conventions * mixfix.hh: added class ModuleCache * import.cc (makeModule): use ModuleCache version of makeSummation() * moduleCache.hh: created * moduleCache.cc: created * renameModule.cc (makeRenamedCopy): copy becomes one of our dependent modules * importModule.cc (deepSelfDestruct): remove self from dependent modules of baseModule 2004-02-09 Steven Eker * import.cc (makeModule): check for recursive imports * preModule.hh (Parent): added decl for makeModule() * import.cc (processImports): rewritten to use makeModule() (makeModule): added 2004-02-06 Steven Eker * importModule.hh (class ImportModule): added decls for makeSummation() and moduleCompare() * renameModule.cc (makeSummation): added (moduleCompare): added 2004-02-05 Steven Eker * renameModule.cc (makeRenamedCopy): crude first attempt at caching * userLevelRewritingContext.cc (printSubstitution): added DebugAdvisory() * renaming.cc (makeCanonicalName): handle attributes * renaming.hh (class Renaming): added decl for makeTypeName() * renaming.cc (makeTypeName): added * renameModule.cc (makeRenamedCopy): new makeCanonicalName() convention * renaming.cc (makeCanonicalVersion): fix same bug in polymorph case (makeCanonicalName): handle labels and op mappings * renameModule.cc (makeRenamedCopy): use makeCanonicalName() * renaming.cc (makeCanonicalName): added * renaming.hh (class Renaming): added decl for makeCanonicalName() * renaming.cc (makeCanonicalVersion): fix bug where we could potentially miss an operator renaming by using upper_bound() and lower_bound() instead of end() and find() 2004-02-04 Steven Eker * importModule.cc (donateStatements2): use translateLabel() * importTranslation.hh (class ImportTranslation): added decl for translateLabel() * importTranslation.cc (translateLabel): added * importModule.hh (getLabels): added * renaming.cc: handle labels * renameModule.cc (localStatementsComplete): moved here * importModule.cc (localStatementsComplete): handle labels and label renaming * importModule.hh (class ImportModule): added data member labels 2004-02-03 Steven Eker * importModule.cc (fixUpDonatedOps): use fixUpDonatedOps2() * importModule.hh (class ImportModule): fixUpRenamedOps() decl -> fixUpDonatedOps2() * renameModule.cc (localSort2): renamed from localSort() (localSort): added version that handles kinds (donateSorts2): use localSort2() (fixUpDonatedOps2): renamed from fixUpRenamedOps() (fixUpDonatedOps2): fix Vector copy bug (fixUpDonatedOps2): handle polymorphs in fully general way (makeRenamedCopy): use fixUpDonatedOps2() 2004-02-02 Steven Eker * importModule.cc (donateOps): use donateOps2() * importModule.hh (class ImportModule): decl for donateRenamedOps() becomes donateOps2() * renameModule.cc (donateRenamedOps): deleted renameTranslation local variable (donateRenamedOps): use localSort() (2 places) (donateRenamedOps): Warning for imports from multiple places without a common ancestor downgraded to an advisory (donateRenamedOps): fix nasty bug where we were accidentally copying Vector of symbol pointers (donateRenamedOps): renamed to donateOps2() (makeRenamedCopy): donateRenamedOps() -> donateOps2() * importModule.hh (class ImportModule): findSort() -> localSort() * renameModule.cc (donateRenamedStatements): deleted (findSort): renamed to localSort() (donateSorts2): findSort() -> localSort() * importModule.hh (class ImportModule): repaced decl for findSort() donateRenamedSorts() with donateSorts2(); added decl for (class ImportModule): deleted decl for donateRenamedStatements() * renameModule.cc (makeRenamedCopy): use donateSorts2() * importModule.cc (donateSorts): use donateSorts2() * renameModule.cc (makeRenamedCopy): don't call donateRenamedStatements() (donateRenamedSorts): becomes donateSorts2(); handle null renaming correctly; issue advisory rather than warning for dup sort (findSort): added * importTranslation.cc (ImportTranslation): use push(), take renaming argument (translate): rewrote all 3 versions so that we can handle imports of symbols into renamed modules for fixups * importTranslation.hh (class ImportTranslation): deleted data member importer; updated decl for ctor 2004-01-30 Steven Eker * importTranslation.hh (class ImportTranslation): added decl for static version of translate() * importTranslation.cc (translate): added static version * importModule.cc (donateStatements2): use ImportTranslation::push() * importTranslation.cc (ImportTranslation): no intialization for renamings (translate): use new definition for renamings * importTranslation.hh (push): added (class ImportTranslation): updated data member renamings; added data member targets; upated decl for ImportTranslation() 2004-01-29 Steven Eker * renameModule.cc (makeRenamedCopy): set canonicalRenaming and baseModule * importModule.cc (donateStatements): use donateStatements2() (ImportModule): initialize canonicalRenaming and baseModule * importModule.hh (class ImportModule): added decl for donateStatements2(); added data members canonicalRenaming and baseModule * importModule.cc (donateStatements2): added * renameModule.cc (fixUpRenamedOps): don't use firstPolymorphCopy (donateRenamedOps): don't set firstPolymorphCopy * importModule.hh (class ImportModule): deleted data member firstPolymorphCopy * importModule.cc (donateOps): don't set firstPolymorphCopy (fixUpDonatedOps): use findPolymorphIndex() rather than firstPolymorphCopy * mixfixModule.hh (CommonTokens): added decl for findPolymorphIndex() * mixfixModule.cc (findPolymorphIndex): added * mixfixModule.hh (findIterSymbolIndex): made const 2004-01-28 Steven Eker * importModule.hh (class ImportModule): deleted data member responsibleForFixUp * renameModule.cc (donateRenamedOps): don't initialize or fill out the responsibleForFixUp set (fixUpRenamedOps): rewritten to avoid needing the responsibleForFixUp set * importModule.cc (fixUpDonatedOps): rewritten to avoid needing the responsibleForFixUp set (donateOps): don't initialize or fill out the responsibleForFixUp set 2004-01-27 Steven Eker * renameModule.cc (donateRenamedOps): handle bubbles (fixUpRenamedOps): new copyFixUpBubbleSpec() convention * importModule.cc (donateOps): new copyBubbleSpec() convention (fixUpDonatedOps): new copyFixUpBubbleSpec() convention * mixfixModule.hh (CommonTokens): updated decls for copyBubbleSpec() and copyFixUpBubbleSpec() * mixfixModule.cc (copyFixUpBubbleSpec): rewritten with new semantics to allow incremental/multiple fixups (copyBubbleSpec): rewritten with new semantics; also fix a nasty bug where we were copying the bubble spec from the wrong module 2004-01-26 Steven Eker * renameModule.cc (donateRenamedOps): removed static stuff for cleanliness (fixUpRenamedOps): implemented * renaming.cc (makeCanonicalVersion): fixed bug where we had to test for whether we had already added a generic op renaming the wrong way around. * renameModule.cc (donateRenamedOps): handle polymorphs * renaming.hh (class Renaming): added decl for renamePolymorph() * renaming.cc (makeCanonicalVersion): handle polymorphs (renamePolymorph): added 2004-01-23 Steven Eker * renameModule.cc (donateRenamedOps): use assignFlags() (4 places) (donateRenamedOps): use gather.clear() * symbolType.hh (assignFlags): added 2003-12-23 Steven Eker * renameModule.cc (makeRenamedCopy): use makeCanonicalVersion() * renaming.hh (class Renaming): added decl for setType() * renaming.cc (setType): added * renaming.hh (class Renaming): added decl for makeCanonicalVersion() * renaming.cc (typeMatch): updated args (both versions) (addType): don't take kind arg (convertSortsToKinds): deleted (printRenamingType): don't check isKind() (makeCanonicalVersion): added * renaming.hh (class Renaming): updated decl for addType(); deleted decl for convertSortsToKinds(); delete struct Type (isKind): deleted (getTypeSorts): updated * modules.yy (fromType): use new addType() convention; don't use convertSortsToKinds() * renaming.hh (class Renaming): typeConflict() decls become typeMatch() * renaming.cc (addType): use new Type (typeConflict): becomes typeMatch() (both versions) (renameOp): use typeMatch() (printRenamingType): added (operator<<): use printRenamingType() * renaming.hh (class Renaming): updated struct Type; replaced decl for getTypeTokens() with getTypeSorts() (getTypeTokens): becomes getTypeSorts() 2003-12-19 Steven Eker * importTranslation.cc (ImportTranslation): handle renamings argument (translate): (sort version) handle renamings * importTranslation.hh (class ImportTranslation): updated decl for ctor, added data member renamings 2003-12-09 Steven Eker * importModule.hh (class ImportModule): added decls for donateRenamedSorts(), donateRenamedOps(), fixupRenamedOps(), donateRenamedStatements() * renameModule.cc (donateRenamedOps): added (fixupRenamedOps): added stub (donateRenamedStatements): added stub (makeRenamedCopy): call donateRenamedOps(), fixupRenamedOps() and donateRenamedStatements() * renaming.cc (renameLabel): added * renaming.hh (class Renaming): adeed decls for renameLabel(), renameOp() and both versions of typeConflict() * renaming.cc (addOpMapping): set index field (renameOp): added (typeConflict): added two versions * renaming.hh (class Renaming): added index field to struct OpMapping 2003-12-08 Steven Eker * renameModule.cc (donateRenamedSorts): added * importModule.hh (class ImportModule): added decl for donateRenamedSorts() * import.cc (processImports): quick hack to handle simple renaming * renaming.hh (class Renaming): added decl for renameSort() * renaming.cc (renameSort): added * importModule.hh (class ImportModule): added decl for makeRenamedCopy() * renameModule.cc: created 2003-12-01 Steven Eker * command.cc (printAttributes): use printGather() and printFormat() * renaming.cc (operator<<): handle attributes * preModule.hh (Parent): added decls for printGather() and printFormat() * command.cc (printGather): added (printFormat): added * renaming.cc (setPrec): don't set symbolType member (setGather): don't set symbolType member (setFormat): don't set symbolType member (setLatexMacro): don't set symbolType member (addOpMapping): initialize prec member to invalid value * renaming.hh (getPrec): added (getGather): added (getFormat): added (class Renaming): deleted symbolType member from struct OpMapping * renaming.cc (setPrec): implemented (setFormat): implemented (setLatexMacro): implemented (addSortMapping): handle line number (addLabelMapping): handle line number * ops.cc (setPrec): use getInt() * token.cc (getInt): added * token.hh (class Token): added decl for getInt() * renaming.cc (setGather): implemented 2003-11-24 Steven Eker * renaming.cc (convertSortsToKinds): added * renaming.hh (class Renaming): added decl forconvertSortsToKinds() * modules.yy (fromSpec): handle ~> semantics * token.hh (class Token): added decl for printTokens(); * token.cc (printTokens): added * renaming.hh (isKind): added (getTypeTokens): added (getNrTypes): added * renaming.cc (addType): added * renaming.hh (class Renaming): added data member lastOpMapping; added symbolType member to struct OpMapping (getOpFrom): added (getOpTo): added (class Renaming): added struct Type; added data member types to struct OpMapping * renaming.cc (operator<<): handle sort and label mappings * renaming.hh (getSortFrom): added (getSortTo): added (getLabelFrom): added (getLabelTo): aded * modules.yy (moduleExpr): use new ModuleExpression convention * renaming.cc (addSortMapping): rewritten (addLabelMapping): rewritten * renaming.hh (class Renaming): added data members sortMapIndex, labelMapIndex, opMapIndex (getNrSortMappings): added (getNrLabelMappings): added (getNrOpMappings): added * moduleExpression.hh (class ModuleExpression): updated decl for ModuleExpression() * moduleExpression.cc (ModuleExpression): take Token rather than int * modules.yy (fDeclaration): fix the bug that bubble gets reused for parsing identifiers in renamings * renaming.cc (operator<<): added * moduleExpression.cc (operator<<): handle summation and renaming 2003-11-20 Steven Eker * top.yy: added decls for tokenBarColonTo, tokenBarCommaLeft * modules.yy (mapping): added semantics for sort and label mappings (tokenBarColonTo): added (tokensBarColonTo): added (tokenBarCommaLeft): added (tokensBarCommaLeft): added (mapping): added semantics for op mappings * top.yy: added global variable current renaming * renaming.cc: created * renaming.hh: created ===================================Maude83a=========================================== 2003-11-12 Steven Eker * preModule.cc (PreModule): delete module expressions in imports 2003-11-11 Steven Eker * command.cc: added support for special and poly attributes 2003-11-10 Steven Eker * prelude.maude: added format attributes to meta hook ops * termPrint.cc (disambiguatorSort): added (prettyPrint): use suffix (suffix): use disambiguatorSort() 2003-11-07 Steven Eker * ops.cc (addHook): only set basic type if it is not STANDARD; this fixes the object level Bubble Exclude bug * mixfixModule.hh (CommonTokens): findBubbleSpecIndex() decl replaces findBubbleSpec() decl * mixfixModule.cc (copyFixUpBubbleSpec): use findBubbleSpecIndex() (findBubbleSpecIndex): was findBubbleSpec() (copyBubbleSpec): use findBubbleSpecIndex() (getDataAttachments): use findBubbleSpecIndex() (getSymbolAttachments): use findBubbleSpecIndex() * mixfixModule.hh (CommonTokens): updated decl for findBubbleSpec() * mixfixModule.cc (getSymbolAttachments): handle bubbles (getDataAttachments): handle bubbles (findBubbleSpec): made const * visibleModule.cc (showAttributes): use MixfixModule versions of getDataAttachments(), getSymbolAttachments(), getTermAttachments() * mixfixModule.cc (getDataAttachments): added (getSymbolAttachments): added (getTermAttachments): added * mixfixModule.hh (CommonTokens): added decls for getDataAttachments(), getSymbolAttachments(), getTermAttachments() * visibleModule.cc (showAttributes): use hasSpecial() rather than hasAttachments() (showPolymorphAttributes): use hasSpecial() rather than hasAttachments() * symbolType.hh (hasSpecial): added 2003-11-06 Steven Eker * mixfixModule.cc (getPolymorphDataAttachment): added (getPolymorphSymbolAttachment): added (getPolymorphTermAttachment): added * mixfixModule.hh (CommonTokens): added decls for getPolymorphDataAttachment(), getPolymorphSymbolAttachment(), getPolymorphTermAttachment() * visibleModule.cc: simplified using hookSort() (showPolymorphAttributes): handle attachments * mixfixModule.hh (hookSort): added * symbolType.hh (class SymbolType): reordered enum BasicTypes to make those that are instantiated with the special attribute contiguous * visibleModule.hh (class VisibleModule): updated showDecls() decl * visibleModule.cc (showOps): don't print internally created symbols, even in "all" case (showDecls): don't print internally created decls; take index rather than sort (showOps): new showDecls() convention 2003-11-05 Steven Eker * quotedIdentifierOpSymbol.cc (getDataAttachments): use CODE_CASE() * loopSymbol.cc (getDataAttachments): use APPEND_DATA() * visibleModule.cc (showAttributes): changed formatting of specials * loopSymbol.cc (getDataAttachments): added (getSymbolAttachments): added * quotedIdentifierOpSymbol.cc (getSymbolAttachments): call FreeSymbol::getSymbolAttachments() for cleaness * loopSymbol.hh (class LoopSymbol): added decls for getDataAttachments() and getSymbolAttachments() 2003-11-04 Steven Eker * visibleModule.cc (showDecls): use new showAttributes() calling convention * visibleModule.hh (class VisibleModule): updated decl for showAttributes() * visibleModule.cc (showAttributes): handle attachments; take OpDeclaration arg 2003-11-03 Steven Eker * quotedIdentifierOpSymbol.cc (eqRewrite): use safeCast() (getDataAttachments): added (getSymbolAttachments): added * quotedIdentifierOpSymbol.hh (class QuotedIdentifierOpSymbol): added decls for getDataAttachments() and getSymbolAttachments() * quotedIdentifierSymbol.cc (getDataAttachments): added * quotedIdentifierSymbol.hh (class QuotedIdentifierSymbol): added decl for getDataAttachments() 2003-10-29 Steven Eker * prelude.maude: added upOpDecls(), upImports() * preModule.hh (getNrAutoImports): added (getNrImports): added (getAutoImport): added (getImportMode): added (getImport): added 2003-10-28 Steven Eker * prelude.maude: added upSorts(), upSubsortDecls() * visibleModule.cc (showAttributes): code cleaning * mixfixModule.hh (getPolymorphPrec): added (getPolymorphGather): added (getPolymorphFormat): added * visibleModule.cc (showPolymorphAttributes): added handling for prec, gather and format * mixfixModule.hh (getPolymorphIdentity): added (getPolymorphStrategy): added (getPolymorphFrozen): added * visibleModule.cc (showPolymorphAttributes): added handling for identity, strategy and frozen 2003-10-27 Steven Eker * visibleModule.hh (class VisibleModule): added decl for showPolymorphAttributes() * visibleModule.cc (showModule): call showPolymorphs() (showPolymorphAttributes): added * interpreter.cc (showOps): call showPolymorphs() * mixfixModule.hh (getPolymorphName): added (getPolymorphDomainAndRange): added * visibleModule.hh (class VisibleModule): added decls for showPolymorphs() and showPolymorphDecl() * visibleModule.cc (showVars): rewritten using FOR_EACH_CONST() (showSummary): split symbols into user symbols and total symbols; print number of polymorphic operators (showPolymorphDecl): added (showPolymorphs): added * mixfixModule.cc (copyFixUpPolymorph): don't copy specialTerms (~MixfixModule): deepSelfDestruct() term hook terms rather than specialTerms * mixfixModule.hh (CommonTokens): deleted decls for fixUpPolymorph() (CommonTokens): deleted specialTerms and shareWithSymbol from struct Polymorph * entry.cc (addPolymorph): don't clear shareWithSymbol * mixfixModule.cc (fixUpPolymorph): deleted both versions (copyFixUpPolymorph): deleted support for shareWithSymbol (copyPolymorph): don't clear shareWithSymbol * importModule.hh (getNrImportedPolymorphs): added 2003-10-24 Steven Eker * mixfixModule.hh (getPolymorphType): added * mixfixModule.cc (instantiatePolymorph): no need to create Token from name (instantiatePolymorph): set symbol line number * entry.cc (addPolymorph): copy name Token * mixfixModule.hh (CommonTokens): made Polymorph name field into a Token 2003-10-23 Steven Eker * entry.cc (newFancySymbol): don't pass term args to EqualitySymbol() or BranchSymbol() (addPolymorph): set overloaded flags in symbolInfo.iflags 2003-10-22 Steven Eker * mixfixModule.cc (instantiatePolymorph): deep copy term hooks * fixUp.cc (fixUpSymbols): handle identities for polymorphs (fixUpSymbols): fixed warning messages for bad special * process.cc (processSorts): use lessThan from CommonTokens * fixUp.cc (findHookSymbol): use colon and partial from CommonTokens * commonTokens.hh (class CommonTokens): added lessThan and partial * commonTokens.cc (CommonTokens): added lessThan and partial 2003-10-20 Steven Eker * prelude.maude: added op poly : NatList -> Attr [ctor] and polySymbol hook * specialSymbolTypes.cc (MACRO): deleted UP_SYMBOL, DOWN_SYMBOL instantiations * symbolType.hh (class SymbolType): deleted UP_SYMBOL, DOWN_SYMBOL from enum BasicTypes 2003-10-17 Steven Eker * mixfixModule.cc (instantiatePolymorph): fixed bug where we were using idHooks purpose for attaching an opHook * prelude.maude: updated definitions of if_then_else_fi, upTerm and downTerm 2003-10-16 Steven Eker * fixUp.cc (fixUpSymbols): rewritten * preModule.hh (Parent): added decl for polymorph version of defaultFixUp() * fixUp.cc (defaultFixUp): added polymorph version * mixfixModule.cc (instantiatePolymorph): rewritten to use standardized method for polymorphs 2003-10-15 Steven Eker * entry.cc (addPolymorph): zero polymorph identity * mixfixModule.cc (addIdHookToPolymorph): added (addOpHookToPolymorph): added (addTermHookToPolymorph): added (copyFixUpPolymorph): copy identity and hooks (addIdentityToPolymorph): added (copyPolymorph): zero polymorph identity * mixfixModule.hh (CommonTokens): added structs IdHook, OpHook and TermHook (CommonTokens): added identity, idHooks, opHooks, termHooks to struct Polymorph * entry.cc (newFancySymbol): handle BRANCH_SYMBOL and EQUALITY_SYMBOL * symbolType.hh (hasAttachments): BRANCH_SYMBOL and EQUALITY_SYMBOL now are treated as having attachments * fixUp.cc (fixUpSymbols): check for polymorphs using POLY flag; reorganized 2003-10-14 Steven Eker * mixfixModule.cc (findSymbol): rewritten to handle polymorphs in a generic way and to be more picky about matching components (instantiatePolymorph): must not change original polymorph domainAndRange now that we rely on it to know which arguments are polymorphic - make a copy 2003-10-13 Steven Eker * process.cc (processOps): don't pass polyArgs to addPolymorph() * entry.cc (addPolymorph): don't take polyArgs argument * mixfixModule.hh (CommonTokens): removed polyArgs from struct Polymorph (CommonTokens): updated decl for addPolymorph() * mixfixModule.cc (copyPolymorph): use domainAndRange to decide how to copy sorts; copy frozen * makeGrammar.cc (makeVariableProductions): use new nonTerminal() (makeBoolProductions): use new nonTerminal() (makePolymorphProductions): rewritten to use new nonTerminal() and polyArgs (makePolymorphProductions): use domainAndRange instead of polyArgs * mixfixModule.cc (nonTerminal): added Sort* version * mixfixModule.hh (CommonTokens): added decl for Sort* version of nonTerminal() * entry.cc (addPolymorph): handle frozen and polyArgs atrguments * mixfixModule.hh (CommonTokens): updated decl for addPolymorph() (CommonTokens): added polyArgs and frozen to struct Polymorph * symbolType.hh (isPolymorph): deleted (isCreatedOnTheFly): don't use isPolymorph() * process.cc (checkOpTypes): rewritten using polyArgs (computeOpTypes): rewritten using polyArgs (processOps): don't use isPolymorph(); use new addPolymorph() convention * ops.cc (setLatexMacro): set LATEX flag 2003-10-10 Steven Eker * preModule.hh (Parent): added polyArgs to struct OpDef; added decl for setPoly() * ops.cc (setPoly): added * symbolType.hh (class SymbolType): added POLY to enum Flags * modules.yy (attrKeyword): added KW_POLY (attribute): added KW_POLY * top.yy: added decl for KW_POLY * lexer.ll (id): added keywords poly, polymorphic ===================================Maude83=========================================== 2003-10-09 Steven Eker * command.cc (printAttributes): need to check for DITTO in first if (printAttributes): fix spacing before [ 2003-10-08 Steven Eker * import.cc (processImports): handle struct Import * command.cc (showModule): handle struct Import * preModule.hh (Parent): updated decl for addImport() * preModule.cc (addImport): moved here; now handle mode * preModule.hh (Parent): added struct Import * moduleExpression.cc (operator<<): added * command.cc (printAttributes): handle format properly 2003-09-29 Steven Eker * mixfixModule.hh (CommonTokens): added decl for Symbol* version of fixUpPolymorph() * mixfixModule.cc (fixUpPolymorph): added Symbol* version * fixUp.cc (fixUpSymbols): handle UP_SYMBOL and DOWN_SYMBOL * makeGrammar.cc (makePolymorphProductions): handle UP_SYMBOL and DOWN_SYMBOL * mixfixModule.hh (CommonTokens): added shareWithSymbol to struct Polymorph * mixfixModule.cc (copyPolymorph): clear shareWithSymbol * entry.cc (addPolymorph): clear shareWithSymbol * mixfixModule.cc (findSymbol): handle UP_SYMBOL and DOWN_SYMBOL (instantiatePolymorph): handle UP_SYMBOL and DOWN_SYMBOL (copyFixUpPolymorph): handle shareWithSymbol (copyPolymorph): handle UP_SYMBOL and DOWN_SYMBOL * process.cc (checkOpTypes): handle UP_SYMBOL and DOWN_SYMBOL (computeOpTypes): handle UP_SYMBOL and DOWN_SYMBOL * symbolType.hh (isPolymorph): rewritten (isCreatedOnTheFly): rewritten * specialSymbolTypes.cc (MACRO): added UpSymbol and DownSymbol * symbolType.hh (class SymbolType): added UP_SYMBOL and DOWN_SYMBOL 2003-09-23 Steven Eker * interact.cc (handleDebug): check to see if pe is 0 before checking its label 2003-09-17 Steven Eker * termPrint.cc (prefix): deleted (this was commented out before) * mixfixModule.hh (CommonTokens): added decl for handleVariable() * bufferPrint.cc (handleVariable): added (prettyPrint): use handleVariable() * mixfixModule.hh (CommonTokens): added decl for printKind() * bufferPrint.cc (printKind): replaces printSort() (prettyPrint): use printKind in variable case 2003-09-15 Steven Eker * bufferPrint.cc (printSort): added 2003-09-09 Steven Eker * modules.yy (listBarDot): added (endTokens2): deleted (noTrailingDot2): deleted (oDeclaration): listBarDot replaces endTokens2 (3 places) 2003-09-08 Steven Eker * visibleModule.cc (showAttributes): print space after left/right when printing identity 2003-09-05 Steven Eker * command.cc (printAttributes): added (printOpDef): rewritten to use printAttributes( 2003-09-04 Steven Eker * mixfix.hh: added class Renaming * top.yy: added yyModuleExpression to union * modules.yy (fDeclaration): use moduleExpr * import.cc (processImports): quick hack to use ModuleExpression * preModule.hh (addImport): updated (Parent): imports is now a Vector * moduleExpression.cc: created * moduleExpression.hh: created * mixfix.hh: added class ModuleExpression 2003-09-03 Steven Eker * top.yy: added KW_TO, KW_LABEL, '+', '*' * lexer.ll: added KW_TO, KW_LABEL, '+', '*' * modules.yy (identifier): added KW_TO, KW_LABEL, '+', '*' 2003-08-20 Steven Eker * prettyPrint.cc (operator<<): added Assert() to check for null component (operator<<): decided to make sort print function bullet proof instead; it can now be called before connnected components are calculated and sort indices are assigned ===================================Maude82=========================================== 2003-07-22 Steven Eker * main.cc (printHelp): added (printVersion): added (main): added --help and --version flags * interact.cc (segmentationFaultHandler): use PACKAGE_BUGREPORT 2003-07-21 Steven Eker * quotedIdentifierDagNode.cc (compareArguments): use new internal ordering on quoted identifiers * quotedIdentifierTerm.cc (compareArguments): use new internal ordering on quoted identifiers (both versions) 2003-07-16 Steven Eker * token.hh: use ropeStuff.hh * entry.cc (addOpDeclaration): if we detect empty syntax for a single argument operator, clear PREC, GATHER and FORMAT flags and clear mixfix syntax to avoid infinite recursion in MSCP later on 2003-07-01 Steven Eker * banner.cc: #include ===================================Maude81=========================================== 2003-05-31 Steven Eker * interact.cc (segmentationFaultHandler): use system call rather than stream to output message since line wrapper can't be relied on * fixUp.cc (findHookSymbol): made slightly more robust in the case of a missing sort 2003-05-30 Steven Eker * maudemlBuffer.cc (generate): (Term* version) use variable q (generate): (DagNode* version) use variable q * lexerAux.cc: deleted SUNOS #ifdef 2003-05-28 Steven Eker * banner.cc: replaced LIBv3 #ifdef 2003-05-23 Steven Eker * importModule.cc (donateStatements): copy metadata (this fixes a bug) * prelude.maude: added config, object, message and nonexec ops to META-MODULE; removed frozen hack * mixfixParser.cc (makeStatementPart): use setNonexec() * prettyPrint.cc (printAttributes): handle nonexec * importModule.cc (donateStatements): copy nonexec status 2003-05-21 Steven Eker * execute.cc (fRewrite): call setObjectMode() * entry.cc (addOpDeclaration): don't fill out configSymbols * userLevelRewritingContext.cc (UserLevelRewritingContext): call ObjectSystemRewritingContext() (both versions) * userLevelRewritingContext.hh (class UserLevelRewritingContext): derive from ObjectSystemRewritingContext rather than RewritingContext * mixfixModule.cc (setConfigMode): deleted (closeSignature): reverted * mixfixModule.hh (CommonTokens): deleted data member configSymbols and decl for setConfigMode() - setting state info like this would play havoc with re-entrancy * execute.cc (fRewrite): call setConfigMode() * mixfixModule.cc (closeSignature): use configSymbols * mixfixModule.hh (CommonTokens): added data member configSymbols * mixfixModule.cc (setConfigMode): rewritten to use configSymbols * entry.cc (addOpDeclaration): put symbols with config attribute in configSymbols 2003-05-20 Steven Eker * mixfixModule.hh (CommonTokens): added decl for setConfigMode() * mixfixModule.cc (setConfigMode): added * entry.cc (addOpDeclaration): warn about operators that have both object and msg attributes or that have an object or msg attribute and no arguments 2003-05-05 Steven Eker * banner.cc: removed SUNOS and LIBv3 #ifdefs ===================================Maude80a=========================================== 2003-05-03 Steven Eker * prelude.maude: added 2003-05-01 Steven Eker * compiler.cc (makeBaseName): use ostringstream * quotedIdentifierOpSymbol.cc (eqRewrite): use ostringstream * quotedIdentifierDagNode.cc (overwriteWithClone): rewritten (makeClone): rewritten 2003-04-18 Steven Eker * loopSymbol.cc (extractQidList): use DagArgumentIterator 2003-04-09 Steven Eker * mixfixModule.hh (CommonTokens): updated many decls for color arg * termPrint.cc (computeColor): added (prefix): deleted (suffix): take color arg (handleIter): take color arg (handleMinus): take color arg (handleDivision): take color arg (handleFloat): take color arg (handleString): take color arg (handleQuotedIdentifier): take color arg (handleVariable): take color arg (prettyPrint): pass color arg to many functions 2003-04-07 Steven Eker * model-checker.maude: added => and <=> LTL operators ===================================Maude80=========================================== 2003-03-21 Steven Eker * execute.cc (reduce): added threshold search version 2003-03-18 Steven Eker * search.cc (search): fixed symmetric bug * match.cc (match): fixed bug where we were printing patternTerm when we printed the command even though this may have been invalidated by normalization 2003-02-26 Steven Eker * xmlBuffer.cc: removed #pragma (endElement): updated Assert() * xmlBuffer.hh: removed #pragma * visibleModule.cc: removed #pragma (showDecls): updated Assert() * visibleModule.hh: removed #pragma * userLevelRewritingContext.cc: removed #pragma (tracePostEqRewrite): updated Assert() (printSubstitution): updated Assert() * userLevelRewritingContext.hh: removed #pragma * token.cc: removed #pragma (codeToInt64): DebugAdvisoryCheck() -> DebugAdvisory() (codeToInt64): updated Assert() (codeToDouble): updated Assert() (bubbleToPrefixNameCode): updated Assert() (getRational): updated Assert() * token.hh: removed #pragma * symbolType.cc: removed #pragma * symbolType.hh: removed #pragma * quotedIdentifierTerm.cc: removed #pragma * quotedIdentifierTerm.hh: removed #pragma * quotedIdentifierSymbol.cc: removed #pragma * quotedIdentifierSymbol.hh: removed #pragma * quotedIdentifierOpSymbol.cc: removed #pragma (eqRewrite): updated Assert() * quotedIdentifierOpSymbol.hh: removed #pragma * quotedIdentifierDagNode.cc: removed #pragma * quotedIdentifierDagNode.hh: removed #pragma * profileModule.cc: removed #pragma * profileModule.hh: removed #pragma * process.cc (computeType): updated Assert()s * prettyPrint.cc (computeGraphStatus): updated Assert() * preModule.cc: removed #pragma (regretToInform): updated Assert() * preModule.hh: removed #pragma * ops.cc (convertSortsToKinds): updated Assert() * moduleDatabase.cc: removed #pragma * moduleDatabase.hh: removed #pragma * mixfixParser.cc: removed #pragma (parseSentence): updated DebugAdvisoryCheck() (parseSentence): updated Assert() (makeTerms): updated Assert() (insertStatement): updated Assert() (makeMatchCommand): updated Assert() (makeSearchCommand): updated Assert() (makeTerm): updated Assert()s * mixfixParser.hh: removed #pragma * mixfixModule.cc: removed #pragma (findSymbol): updated Assert() (computePrecAndGather): updated Assert()s * mixfixModule.hh: removed #pragma * metadataStore.cc: removed #pragma * metadataStore.hh: removed #pragma * maudemlBuffer.cc: removed #pragma * maudemlBuffer.hh: removed #pragma * loopSymbol.cc: removed #pragma * loopSymbol.hh: removed #pragma * interpreter.cc: removed #pragma * interpreter.hh: removed #pragma * importTranslation.cc: removed #pragma (translate): updated Assert() (both versions) * importTranslation.hh: removed #pragma * importModule.cc: removed #pragma (donateOps): updated Assert()s (fixUpDonatedOps): updated Assert()s * importModule.hh: removed #pragma * graphPrint.cc (graphCount): updated Assert()s * fileTable.cc: removed #pragma * fileTable.hh: removed #pragma * execute.cc (cont): fixed buggy IssueWarning() * entry.cc (addSort): updated Assert() (hasSameDomain): updated Assert()s (addOpDeclaration): updated Assert() * dagNodePrint.cc (computeColor): updated Assert() * compiler.cc: removed #pragma (makeExecutable): fixed buggy IssueWarning() * compiler.hh: removed #pragma * commonTokens.cc: removed #pragma * commonTokens.hh: removed #pragma ===================================Maude79=========================================== 2003-02-20 Steven Eker * interact.cc (segmentationFaultHandler): updated bug report address * entry.cc (addOpDeclaration): added WarningCheck for 1 arg ops with empty syntax * model-checker.maude: split off fmod SATISFACTION; use modelCheck for model checker * prelude.maude: NUMBER-CONVERSION -> CONVERSION 2003-02-19 Steven Eker * makeGrammar.cc (makeComplexProductions): use =>1 instead of => for one step rewriting * commonTokens.hh (class CommonTokens): added arrowOne * commonTokens.cc (CommonTokens): addedarrowOne * search.cc (search): use =>1 instead of => for one step rewriting ===================================Maude78=========================================== 2003-01-06 Steven Eker * main.cc (main): removed various commented out crap 2003-01-03 Steven Eker * lexerAux.cc (includeFile): save fakeNewline status (handleEof): restore fakeNewline status (cleanUpLexer): clear fakeNewline flag 2003-01-02 Steven Eker * lexerAux.cc (getInput): set result = YY_NULL if there are no more characters available from file (rather than , for portability). 2002-11-27 Steven Eker * main.cc (findPrelude): removed extraneous quote from IssueWarning() * banner.cc: fixed #include for LIBv3 2002-11-25 Steven Eker * interpreter.cc (setCurrentModule): removed default arg 2002-11-15 Steven Eker * entry.cc (addOpDeclaration): use new style IssueWarning()/WarningCheck()s (addVariableAlias): use new style WarningCheck() (newFancySymbol): use new style IssueWarning()s (addPolymorph): use new style IssueWarning()/WarningCheck()s * doParse.cc (parseTerm): use new style IssueWarning()s (parseStatement): use new style IssueWarning()s (parseMatchCommand): use new style IssueWarning()s (parseSearchCommand): use new style IssueWarning()s (parseSentence): use new style IssueWarning()s * moduleDatabase.cc (insertModule): use new style IssueAdvisory() * fixUp.cc (fixUpSymbols): use new style IssueWarning()/WarningCheck() * import.cc (processImports): use new style IssueWarning()/WarningCheck() (importModule): use new style IssueWarning()s * importModule.cc (donateSorts): use new style IssueWarning() (donateOps): use new style IssueWarning() * interact.cc (commandLoop): use new style IssueWarning() * interpreter.cc (setCurrentModule): use new style IssueWarning()s (makeClean): use new style IssueAdvisory() * loopMode.cc (contLoop2): use new style IssueWarning()s (contLoop): use new style IssueAdvisory()s * main.cc (findPrelude): use new style IssueWarning() (main): use new style IssueWarning() (findFile): use new style IssueWarning() * match.cc (match): use new style IssueWarning() * mixfixParser.cc (makeStatementPart): use new style WarningCheck()s * lexerAux.cc (includeFile): use new style IssueWarning()s * lexer.flex: use new style IssueWarning()s * bottom.y (yyerror): use new style IssueWarning() * modules.y: use new style IssueWarning()s * top.y: use new style IssueWarning()s * ops.cc (convertSortsToKinds): use new style IssueWarning() (setPrec): use new style IssueWarning() (setGather): use new style IssueWarning()s (setFormat): use new style IssueWarning()s (setFrozen): use new style IssueWarning()/WarningCheck()s (setStrat): use new style IssueWarning() * preModule.cc (getFlatModule): use new style IssueWarning() (getFlatSignature): use new style IssueAdvisory() * process.cc (process): use new style IssueWarning()s (processSorts): use new style IssueWarning()/WarningCheck() (getSort): use new style IssueWarning() * search.cc (search): use new style IssueWarning() (showSearchPath): use new style IssueWarning()s (showSearchGraph): use new style IssueWarning() 2002-11-14 Steven Eker * mixfixParser.cc (parseSentence): Assert() to check for bad error position being returned from MSCP * interpreter.cc (parse): use getFlatModule() rather than getFlatSignature() since we have now deferred sort table calculations until the module is flattened 2002-11-12 Steven Eker * dagNodePrint.cc (handleIter): only compute color info if PRINT_COLOR is set to avoid UMRs (prettyPrint): only compute color info if PRINT_COLOR is set to avoid UMRs 2002-11-11 Steven Eker * prelude.maude: added owise meta attribute * mixfixParser.cc (makeStatementPart): added line number to warnings * mixfixModule.hh (CommonTokens): updated decl for printAttributes() * prettyPrint.cc (printAttributes): handle owise * importModule.cc (donateStatements): pass owise flag to Equation() * mixfixParser.cc (makeAttributePart): handle MAKE_OWISE_ATTRIBUTE (makeStatementPart): pass owise flag to Equation() * mixfixParser.hh (class MixfixParser): added MAKE_OWISE_ATTRIBUTE to enum SemanticActions (class MixfixParser): added enum Flags (class MixfixParser): updated decls for makeAttributePart() and makeStatementPart() * makeGrammar.cc (makeAttributeProductions): added syntax for otherwise and owise * commonTokens.hh (class CommonTokens): added otherwise and owise * commonTokens.cc (CommonTokens): added otherwise and owise 2002-11-07 Steven Eker * lexerAux.cc (getInput): deleted commented out i/o code * userLevelRewritingContext.hh (class UserLevelRewritingContext): added decl for changePrompt() * interact.cc (changePrompt): added (handleDebug): call changePrompt() (setHandlers): call changePrompt(), setContPrompt() (commandLoop): deleted messy prompt setting code (setHandlers): deleted commented out SIGWINCH code * match.cc (doMatching): DagNode::okToCollectGarbage() -> MemoryCell::okToCollectGarbage() 2002-11-06 Steven Eker * bufferPrint.cc (handleFormat): use ansiEscapeSequences.cc * loopMode.cc (printBubble): use ansiEscapeSequences.cc * ops.cc (checkFormatString): use ansiEscapeSequences.cc * prettyPrint.cc (fancySpace): use ansiEscapeSequences.cc * ansiEscapeSequences.cc: added * ops.cc (checkFormatString): added 14 extra allow chars * prettyPrint.cc (fancySpace): added remaining 14 ANSI escape sequences 2002-11-04 Steven Eker * token.cc (fixUp): added * token.hh (class Token): added decl for fixUp() * lexer.flex: allow \ newline in stringContent; added FIX_UP macro; use it to fix up identifiers with \ newline in them 2002-10-22 Steven Eker * prelude.maude: added extra decl for _^_ in NAT, INT and RAT 2002-10-21 Steven Eker * commands.y: use MemoryCell::setShowGC() (2 places) * prelude.maude: corrected declaration for abs in RAT 2002-10-08 Steven Eker * entry.cc (newFancySymbol): check that iter symbols only have a single domain sort * ops.cc (setFrozen): handle case where list of arguments is empty; check for trying to set frozen attribute on a constant * modules.y: use setFrozen() even for case where there is no frozen list * visibleModule.cc (showAttributes): updated printout of frozen attribute * command.cc (printOpDef): updated printout of frozen attribute * preModule.hh (Parent): struct OpDef data member frozen is now a NatSet * ops.cc (setFrozen): frozen is now a NatSet; check for duplicate args * mixfixModule.hh (CommonTokens): updated decl for addOpDeclaration() * entry.cc (addOpDeclaration): new frozen handling * importModule.cc (donateOps): cleaned up frozen handling 2002-10-03 Steven Eker * command.cc (printOpDef): fix missing ( in frozen case 2002-10-02 Steven Eker * command.cc (printOpDef): handle frozen attribute with list of arg numbers * visibleModule.cc (showAttributes): handle frozen attribute with list of arg numbers * importModule.cc (donateOps): pass frozen arg to addOpDeclaration() * process.cc (processOps): pass frozen arg to addOpDeclaration() * mixfixModule.hh (CommonTokens): updated decl for addOpDeclaration() * entry.cc (addOpDeclaration): take and handle frozen arg * modules.y: added syntax for partially frozen attribute * ops.cc (setFrozen): added * preModule.hh (Parent): added data member frozen to struct OpDef (Parent): added decl for setFrozen() 2002-09-27 Steven Eker * modules.y: use KW_ convention for keywords * top.y: use KW_ convention for keywords * lexer.flex: use KW_ convention for keywords * interact.cc (setHandlers): don't call new_GetLine() or gl_trap_signal() * userLevelRewritingContext.hh (class UserLevelRewritingContext): deleted decls for getInput(), displayPrompt(), setAutoWrap() * interact.cc (commandLoop): don't call resetCursor() (setAutoWrap): deleted (displayPrompt): deleted (getInput): deleted (setInteractive): don't call displayPrompt() * main.cc (main): use ioManager.setAutoWrap() 2002-09-26 Steven Eker * lexerAux.cc (getInput): use ioManager.getInput() * main.cc (main): use ioManager.setCommandLineEditing(); added global variable ioManager * interact.cc (setHandlers): use gl_trap_signal() 2002-09-25 Steven Eker * interact.cc (setHandlers): added hack to init tecla (commandLoop): don't call displayPrompt() (setInteractive): don't call displayPrompt() (commandLoop): call resetCursor() (commandLoop): clear continuation flag (getInput): use continuation flag (getInput): rewritten to respect max_size * userLevelRewritingContext.hh (class UserLevelRewritingContext): added decl for getInput() * interact.cc (getInput): added * lexerAux.cc (getInput): use UserLevelRewritingContext::getInput() 2002-09-06 Steven Eker * mixfixModule.hh (CommonTokens): many decls added and changed to accomodate new Term* -> ostream& pretty printer * termPrint.cc: complete rewrite to handle disambiguation for nats/ints/rats/vars * prettyPrint.cc (fancySpace): don't output attributes if we're are in print color mode * entry.cc (addOpDeclaration): added WarningCheck() for pseudo variable that cannot be distinguished from the real thing * dagNodePrint.cc (handleVariable): handle disambiguation (except for kinds) and color * entry.cc (addOpDeclaration): fill out overloadedVariables * mixfixModule.hh (CommonTokens): added data memeber overloadedVariables 2002-09-05 Steven Eker * dagNodePrint.cc (handleDivision): handle disambiguation (prettyPrint): new handleDivision() calling convention (handleIter): handle disambiguation in succ case (prettyPrint): hoist common coloringInfo calcs * mixfixModule.hh (CommonTokens): updated decl for handleDivision() * dagNodePrint.cc (prettyPrint): new handleMinus() calling convention * mixfixModule.hh (CommonTokens): updated decl for handleMinus() * dagNodePrint.cc (handleMinus): handle disambiguation * sharedPrint.cc: created * dagNodePrint.cc: major rewrite * mixfixModule.hh (CommonTokens): added PSEUDOS to enum InternalFlags (CommonTokens): added decls for ambiguous() and prefix() (CommonTokens): added decls for handleFloat(), handleString(), handleQuotedIdentifier(), handleVariable(), suffix() * dagNodePrint.cc (prettyPrint): check for PSEUDO_NAT, PSEUDO_NEG and PSEUDO_RAT * entry.cc (newFancySymbol): update kindsWithMinus and kindsWithDivision * mixfixModule.hh (CommonTokens): made newFancySymbol() non static * entry.cc (newFancySymbol): update kindsWithSucc * prettyPrint.cc (operator<<): check PRINT_COLOR flag * mixfixModule.hh (CommonTokens): deleted static data member printCtors * dagNodePrint.cc (computeColor): check PRINT_COLOR flag * interpreter.hh: added PRINT_COLOR to enum Flags * commands.y: added set print color on/off * top.y: added KW_COLOR * lexer.flex: added KW_COLOR 2002-09-04 Steven Eker * token.hh (class Token): added decl for getRational() * token.cc (getRational): added * entry.cc (addOpDeclaration): support for PSEUDO_NAT, PSEUDO_NEG and PSEUDO_RAT * mixfixModule.hh (CommonTokens): added decl for hasSameDomain() (CommonTokens): added data members overloadedIntegers, overloadedRationals, kindsWithSucc, kindsWithMinus, kindsWithDivision (CommonTokens): added PSEUDO_NAT, PSEUDO_NEG, PSEUDO_RAT to enum InternalFlags * entry.cc (hasSameDomain): added, in order to deal with assoc domain overloading (addOpDeclaration): use hasSameDomain() * quotedIdentifierSymbol.hh (class QuotedIdentifierSymbol): added decl for isConstructor() * quotedIdentifierSymbol.cc (isConstructor): added 2002-09-03 Steven Eker * mixfixModule.hh (CommonTokens): updated decls for prettyPrint(), handleIter(), computeColor( * dagNodePrint.cc (computeColor): use struct ColoringInfo (handleIter): use struct ColoringInfo * prettyPrint.cc (operator<<): use struct ColoringInfo * mixfixModule.hh (CommonTokens): updated decls for DagNode* versions of handleIter(), handleMinus(), handleDivision() (CommonTokens): added decl for computeColor() (CommonTokens): added struct ColoringInfo * dagNodePrint.cc (prettyPrint): handle coloring in unflatten assoc case (handleIter): handle color arg (handleMinus): handle color arg (computeColor): added (prettyPrint): use computeColor() (prettyPrint): pass color arg to handleIter(), handleMinus() and handleDivision() * prettyPrint.cc (operator<<): pass ectra arg to prettyPrint() * mixfixModule.hh (CommonTokens): updated decl for DagNode* version of prettyPrint() * dagNodePrint.cc (handleIter): pass reducedDirectlyAbove arg to prettyPrint() (prettyPrint): use cyan for unreduced node that have a reduced node above them but not directly above them 2002-08-29 Steven Eker * mixfixModule.hh (CommonTokens): updated decls for printTokens() and printTails() * prettyPrint.cc (printTokens): handle color arg (printTails): handle color arg * dagNodePrint.cc (prettyPrint): handle printCtors in mixfix case 2002-08-28 Steven Eker * dagNodePrint.cc (prettyPrint): handle printCtors in prefix case * mixfixModule.hh (CommonTokens): updated decls for DagNode* versions of handleIter() and prettyPrint() * dagNodePrint.cc (handleIter): take and pass visited, statusVec and reducedAbove (prettyPrint): take and pass visited, statusVec and reducedAbove * prettyPrint.cc (operator<<): (DagNode* version) call computeGraphStatus() * mixfixModule.hh (CommonTokens): added enum DagNodeStatus (CommonTokens): added decl for computeGraphStatus() (CommonTokens): added static data member printCtors * prettyPrint.cc (graphStatus): added * lexer.flex: added : space to skipped IssueWarning() 2002-08-27 Steven Eker * importModule.cc (donateOps): set or clear CTOR flag before passing symbolType to MixfixModule::addOpDeclaration() * entry.cc (addOpDeclaration): don't store ctor flag in symbolInfo[].symbolType since this is a per-symbol struct whereas ctor flag can vary between op decls for the same symbol 2002-08-26 Steven Eker * symbolType.hh (class SymbolType): added decl for dittoProblem() * entry.cc (addOpDeclaration): use dittoProblem() * symbolType.cc (dittoProblem): added (compatible): exclude DITTO when checking for compatibility * entry.cc (addOpDeclaration): allow ditto to be combined with ctor * prelude.maude: made QID-LIST ops ctors; use ditto for op __ : TypeList TypeList in fmod META-MODULE; made true and false ctors * modules.y: use setFlag(SymbolType::CTOR) * visibleModule.cc (showDecls): use isConstructor() (showAttributes): handle iter theory * bufferPrint.cc (prettyPrint): deleted miValue * dagNodePrint.cc (prettyPrint): deleted miValue * termPrint.cc (prettyPrint): deleted miValue * visibleModule.cc (showDecls): use new getOpDeclarations() semantics * quotedIdentifierSymbol.cc (compileOpDeclarations): use new getOpDeclarations() semantics * prettyPrint.cc (chooseDisambiguator): use new getOpDeclarations() semantics * importModule.cc (donateOps): use new getOpDeclarations() semantics * mixfixModule.cc (instantiatePolymorph): use new addOpDeclarations() semantics (copyBubbleSpec): use new getOpDeclarations() semantics (mayAssoc): use new getOpDeclarations() semantics (findSymbol): use new getOpDeclarations() semantics (instantiateVariable): use new addOpDeclarations() semantics; variables are always constructors (instantiateSortTest): use new addOpDeclarations() semantics; sort tests are never constructors * entry.cc (addBubbleSpec): use new getOpDeclarations() semantics (addOpDeclaration): use new getOpDeclarations() and addOpDeclarations() semantics 2002-08-23 Steven Eker * userLevelRewritingContext.cc (dontTrace): added Assert to tray and catch bug reported by Paco (dontTrace): removed Assert(); handle the case where pe == 0, fixing bug reported by Paco ===================================Maude75================================================== 2002-08-02 Steven Eker * modules.y: added KW_ENDOM to startKeyword2 2002-08-01 Steven Eker * token.cc (codeToRope): replaced Assert(false,...) with CantHappen() * prettyPrint.cc (operator<<): replaced Assert(false,...) with CantHappen() * mixfixParser.cc (makeTerm): replaced Assert(false,...) with CantHappen() (makeConditionFragment): replaced Assert(false,...) with CantHappen() (makeStatementPart): replaced Assert(false,...) with CantHappen() * interact.cc (handleDebug): replaced Assert(false,...) with CantHappen() * importModule.cc (removeDependent): replaced Assert(false,...) with CantHappen() (deepCopyCondition): replaced Assert(false,...) with CantHappen() (deepSelfDestruct): replaced DebugAdvisoryCheck(false, ...) with DebugAdvisory() (unprotect): replaced DebugAdvisoryCheck(false, ...) with DebugAdvisory() (removeDependent): replaced DebugAdvisoryCheck(false, ...) with DebugAdvisory() 2002-07-31 Steven Eker * visibleModule.cc (showAttributes): fix bug that we were not setting space after comm (showAttributes): handle MESSAGE, OBJECT and CONFIG flags * command.cc (printOpDef): handle MESSAGE, OBJECT and CONFIG flags * lexer.flex: move in to * modules.y: removed KW_PWD, KW_CD, KW_PUSHD, KW_POPD, KW_LS, IN, KW_LOAD, KW_QUIT, KW_EOF from startKeyword2; removed directive from fDeclaration * top.y: tokens KW_PWD KW_CD KW_PUSHD KW_POPD KW_LS KW_LOAD KW_QUIT KW_EOF no longer declared to have a type * lexer.flex: moved in, load, pwd, cd, pushd, popd, ls, quit, q, eof, from to 2002-07-30 Steven Eker * lexer.flex (id): added | , class and subclass to tokens that are return in ID_MODE * modules.y: added '|' to identifier; added syntax for subclasses; added KW_CLASS and KW_SUBCLASS to startKeyword2 * top.y: added tokens KW_CLASS, KW_SUBCLASS * modules.y: added syntax for class definitions 2002-07-29 Steven Eker * top.y: added decl for startKeyword2 nonterminal * modules.y: added KW_MSG and KW_MSGS to startKeyword; removed KW_MSG from attrKeyword2; added startKeyword2 so we can exclude msg from identity chunks 2002-07-26 Steven Eker * modules.y: reorganized declarations so that rules cannot appear in fmods; added syntax for msg/msgs statements * top.y: added decls for nonterminals notEndfm and notEndm * modules.y: added omod ... endom syntax; handle ended by warings in an extensible way * top.y: added tokens KW_MSGS and KW_ENDOM; added decl for nonterminal notEndom * lexer.flex (id): added keywords msgs and endom 2002-07-25 Steven Eker * makeGrammar.cc (makeSymbolProductions): deleted MACHINE_INTEGER case * mixfixParser.hh (class MixfixParser): deleted MAKE_MACHINE_INT from enum SemanticActions * symbolType.hh (class SymbolType): deleted MACHINE_INTEGER and MACHINE_INTEGER_OP from enum BasicTypes (hasAttachments): use FLOAT_OP instead of MACHINE_INTEGER_OP * specialSymbolTypes.cc (MACRO): deleted MachineIntegerSymbol and MachineIntegerOpSymbol cases * mixfixParser.cc (makeTerm): deleted MAKE_MACHINE_INT case * mixfixModule.cc (findMachineIntegerSymbol): deleted * maudemlBuffer.cc (generate): (both versions) deleted MachineIntegerSymbol case * entry.cc (addOpDeclaration): deleted PSEUDO_MACHINE_INTEGER and overloadedMachineIntegers stuff (addOpDeclaration): don't update machineIntegerSymbols (newFancySymbol): don't make MachineIntegerSymbols or MachineIntegerOpSymbols * termPrint.cc (prettyPrint): deleted handling for PSEUDO_MACHINE_INTEGERs and MACHINE_INTEGERs * graphPrint.cc (graphPrint): deleted MACHINE_INTEGER case * dagNodePrint.cc (prettyPrint): deleted handling for PSEUDO_MACHINE_INTEGERs and MACHINE_INTEGERs * bufferPrint.cc (prettyPrint): deleted handling for PSEUDO_MACHINE_INTEGERs and MACHINE_INTEGERs * mixfixModule.hh (CommonTokens): deleted decl for findMachineIntegerSymbol(); deleted PSEUDO_MACHINE_INTEGER from enum InternalFlags; deleted data members overloadedMachineIntegers and machineIntegerSymbols ===================================Maude74================================================== 2002-06-17 Steven Eker * prettyPrint.cc (printCondition): don't print "." (operator<<): (SortConstraint* version) use printAttributes() (printAttributes): added (operator<<): (Equation* version) use printAttributes() * mixfix.hh: added class MetadataStore * mixfixModule.hh (CommonTokens): derive from MetadataStore * metadataStore.hh (class MetadataStore): created from metadata stuff in MixfixModule * metadataStore.cc (getMetadata): moved here (insertMetadata): moved here * mixfixModule.cc (insertMetadata): added (getMetadata): added * mixfixModule.hh (CommonTokens): added MetadataMap, data member metadataMap, enum ItemType and decls for insertMetadata() and getMetadata() * mixfixParser.cc (makeAttributePart): handle metadata attribute (makeStatementPart): insert metadata 2002-06-14 Steven Eker * mixfixParser.hh (class MixfixParser): added MAKE_LABEL_ATTRIBUTE, MAKE_METADATA_ATTRIBUTE, MAKE_NONEXEC_ATTRIBUTE and MAKE_ATTRIBUTE_LIST to enum SemanticActions (class MixfixParser): added decl for makeAttributePart(), updated decl for makeStatementPart() * mixfixParser.cc (makeAttributePart): added (makeStatementPart): added metadata and flags arguments (makeStatement): call makeAttributePart() * commonTokens.cc (CommonTokens): added label, metadata and nonexec * commonTokens.hh (class CommonTokens): added label, metadata and nonexec * preModule.cc (addStatement): check for labels in attribute list; use CommonTokens (addRule): deleted * preModule.hh (PreModule): derive from ComonTokens (PreModule): deleted decl for addRule() * makeGrammar.cc (makeAttributeProductions): added label and nonexec attributes * mixfixModule.hh (CommonTokens): added decl for makeAttributeProductions() * makeGrammar.cc (makeStatementProductions): added production for statement with attributes (makeAttributeProductions): created (makeGrammar): call makeAttributeProductions() 2002-06-13 Steven Eker * prettyPrint.cc (operator<<): (SortConstraint* version) handle label (operator<<): (Equation* version) handle label * userLevelRewritingContext.hh (class UserLevelRewritingContext): updated decl for handleDebug() * userLevelRewritingContext.cc (tracePreEqRewrite): pass equation to handleDebug() (tracePreScApplication): pass sc to handleDebug() * trial.cc (traceBeginEqTrial): pass equation to handleDebug() (traceBeginScTrial): pass sc to handleDebug() * interact.cc (handleDebug): deal with PreEquation* rather than Rule* * userLevelRewritingContext.hh (dontTrace): delete 1 arg version (class UserLevelRewritingContext): updated decl for dontTrace() * userLevelRewritingContext.cc (tracePreEqRewrite): pass equation to dontTrace() (tracePreScApplication): pass sc to dontTrace() * trial.cc (traceBeginRuleTrial): test traceRuleFlag (traceBeginEqTrial): pass equation to dontTrace() (traceBeginScTrial): pass sc to dontTrace() * userLevelRewritingContext.cc (dontTrace): moved here; deal with PreEquation* rather than Rule* (dontTrace): don't check traceRuleFlag (tracePreRuleRewrite): test traceRuleFlag * modules.y: use addStatement() rather than addRule() * preModule.cc (addStatement): moved here; check for labels * mixfixModule.hh (CommonTokens): added decl for makeComponentProductions() (CommonTokens): RULE_BODY -> RL_BODY; added STATEMENT_PART, ATTRIBUTE_PART, MB_BODY, EQ_BODY to enum NonTerminal * makeGrammar.cc (makeStatementProductions): rewritten; statements now consists of statment parts; now have MB_BODY, EQ_BODY so that mbs and eqs can be prefixed by a label; RULE_BODY becomes RL_BODY (makeConditionProductions): added to contain all the condition code from makeStatementProductions() (makeGrammar): call makeConditionProductions(); * mixfixParser.hh (class MixfixParser): added decl for makeStatementPart() (class MixfixParser): added MAKE_ATTRIBUTE_PART to enum SemanticActions * mixfixParser.cc (makeStatementPart): added (makeStatement): use makeStatementPart() 2002-06-12 Steven Eker * importModule.cc (donateStatements): copy label arg for eqs and mbs * mixfixParser.cc (makeStatement): pass NONE as first arg of Equation() and SortConstraint() * quotedIdentifierOpSymbol.cc (eqRewrite): oracle "or" changed to "mo" for "mos-oracle" 2002-06-10 Steven Eker * makeGrammar.cc (makeSymbolProductions): MACHINE_FLOAT -> FLOAT * mixfixParser.hh (class MixfixParser): MACHINE_FLOAT -> FLOAT * symbolType.hh (class SymbolType): MACHINE_FLOAT -> FLOAT * specialSymbolTypes.cc (MACRO): MachineFloat -> Float * termPrint.cc (prettyPrint): MachineFloat -> Float * mixfixParser.cc (makeTerm): MachineFloat -> Float * mixfixModule.cc: MachineFloat -> Float * maudemlBuffer.cc (generate): MachineFloat -> Float * graphPrint.cc (graphPrint): MachineFloat -> Float * entry.cc: MachineFloat -> Float * dagNodePrint.cc (prettyPrint): MachineFloat -> Float * bufferPrint.cc (prettyPrint): MachineFloat -> Float * mixfixModule.hh: MachineFloat -> Float 2002-06-03 Steven Eker * maudemlBuffer.cc (generate): (term and dagnode versions) handle iter theory * graphPrint.cc (graphPrint): moved here (graphCount): moved here (graphPrint): deleted comment out code from pre mpz_class implementation (graphPrint): handle iter theory 2002-05-24 Steven Eker * mixfixModule.hh (CommonTokens): added decl for buffer versions of handleMinus() and handleDivision() * termPrint.cc (prettyPrint): removed old iter code * bufferPrint.cc (handleMinus): added (handleDivision): added (prettyPrint): use handleMinus() and handleDivision() * mixfixModule.hh (CommonTokens): added decl for buffer version of handleIter() * bufferPrint.cc (handleIter): added (prettyPrint): use handleIter() * termPrint.cc (handleIter): use makeIterName() * dagNodePrint.cc (handleIter): use makeIterName() * mixfixModule.hh (CommonTokens): added decl for makeIterName() * prettyPrint.cc (makeIterName): added * interact.cc (commandLoop): treat an error from yyparse() just like a ctrl-C for cleanup purposes. This fixes a bug where if the user quits part way through a module with ^D we have a module in a bad state that we don't delete 2002-05-23 Steven Eker * termPrint.cc (prettyPrint): (Term* version) use handleMinus() and handleDivision() (handleDivision): added Term* version * mixfixModule.hh (CommonTokens): added decls for Term* versions of handleIter(), handleMinus(), handleDivision() * termPrint.cc (prettyPrint): (Term* version) moved here (prettyPrint): use handleIter() (handleIter): added Term* version * dagNodePrint.cc (handleDivision): use PRINT_RAT flag * interpreter.hh (endif): added PRINT_RAT to enum Flags * commands.y: added syntax for set print rat on/off . * top.y: added KW_RAT * lexer.flex: added KW_RAT * makeGrammar.cc (makeSymbolProductions): added DIVISION_SYMBOL case (makeSpecialProductions): added RATIONAL cases for both seen and unseen tokens * mixfixModule.hh (CommonTokens): added RATIONAL to enum NonTerminal and renumbered * mixfixParser.cc: added MAKE_RATIONAL case * mixfixParser.hh (class MixfixParser): added MAKE_RATIONAL to enum SemanticActions * token.hh (class Token): added decl for looksLikeRational() * token.cc (looksLikeRational): added (checkForSpecialProperty): use looksLikeRational() * token.hh (class Token): added RATIONAL to enum SpecialProperties * mixfixModule.hh (CommonTokens): added decl for handleDivision() * dagNodePrint.cc (handleMinus): rewritten to be simpler as the cost if an extra mpz_class copy (handleDivision): added (prettyPrint): use handleDivision() 2002-05-22 Steven Eker * token.cc (bubbleToPrefixNameCode): patched second (old) algorithm to avoid spurious backquote between token that ends in _ and token that starts with nonspecial. (extractMixfix): allow prefix name with ITER_SYMBOL special property such as |_|^2 to be spit into mixfix syntax 2002-05-21 Steven Eker * symbolType.hh (class SymbolType): added DIVISION_SYMBOL to enum BasicTypes * specialSymbolTypes.cc (MACRO): added DivisionSymbol * commands.y: added syntax for set print number on/off command * top.y: added KW_NUMBER * lexer.flex: added KW_NUMBER * dagNodePrint.cc (handleIter): respect PRINT_NUMBER flag (handleMinus): respect PRINT_NUMBER flag * interpreter.hh (endif): added 9 print flags to enum Flags 2002-05-20 Steven Eker * mixfixModule.hh (CommonTokens): added decl for handleMinus() * dagNodePrint.cc (handleMinus): added (prettyPrint): use handleMinus() * mixfixModule.hh (CommonTokens): added decl for handleIter() * dagNodePrint.cc (prettyPrint): (DagNode* version) moved here (handleIter): added (prettyPrint): use handleIter() * prettyPrint.cc (prettyPrint): (DagNode* version) added SUCC_SYMBOL case * token.cc (codeToInt64): added hack to catch out of range integer errors that are now possible; this will go away with MachineInts * mixfixParser.cc (makeTerm): make sure that the C-string -> mpz_class conversion is done base 10 even if string start with a 0 * token.cc (checkForSpecialProperty): support arbitrary precision integers * mixfixParser.cc (makeTerm): added MAKE_INTEGER case * mixfixParser.hh (class MixfixParser): added MAKE_INTEGER to * makeGrammar.cc (makeSymbolProductions): added negative integer syntax for MINUS_SYMBOL case * mixfixModule.hh (CommonTokens): added ZERO to enum NonTerminal and renumbered following constants * makeGrammar.cc (makeSymbolProductions): handle Token::ZERO case (makeSpecialProductions): handle Token::ZERO case * token.cc (checkForSpecialProperty): handle ZERO case * entry.cc (addOpDeclaration): handle Token::ZERO case when checking for PSEUDO_MACHINE_INTEGERs * token.hh (class Token): added ZERO to enum SpecialProperties * mixfixParser.hh (class MixfixParser): added MAKE_NATURAL to enum SemanticActions * mixfixParser.cc (makeTerm): added MAKE_NATURAL case * makeGrammar.cc (makeSymbolProductions): added natural number syntax for SUCC_SYMBOL case 2002-05-17 Steven Eker * specialSymbolTypes.cc (MACRO): MINUS_SYMBOL added * entry.cc (newFancySymbol): added MINUS_SYMBOL case * symbolType.hh (class SymbolType): added MINUS_SYMBOL to enum BasicTypes 2002-05-15 Steven Eker * importModule.cc (fixUpDonatedOps): for all symbol types where hasAttachments() is true we handle fixups in an incremental manner; previous we only did this for symbol type QUOTED_IDENTIFIER and actually for a QUOTED_IDENTIFIER where we were responsibleForFixUp we would do it twice! * specialSymbolTypes.cc (MACRO): added CUI_NumberOpSymbol * entry.cc (newFancySymbol): support CUI_NUMBER_OP_SYMBOL within CUI_SYMBOL case * symbolType.hh (class SymbolType): added CUI_NUMBER_OP_SYMBOL to enum BasicTypes 2002-05-13 Steven Eker * entry.cc (newFancySymbol): added ACU_NUMBER_OP_SYMBOL case * specialSymbolTypes.cc (MACRO): added ACU_NumberOpSymbol * symbolType.hh (class SymbolType): added ACU_NUMBER_OP_SYMBOL to enum BasicTypes 2002-05-09 Steven Eker * symbolType.hh (hasAttachments): test against END_OF_SYMBOLS_WITH_ATTACHMENTS rather than LOOP_SYMBOL (class SymbolType): added END_OF_SYMBOLS_WITH_ATTACHMENTS to enum BasicTypes * entry.cc (newFancySymbol): added SUCC_SUMBOL and NUMBER_OP_SYMBOL cases * symbolType.hh (class SymbolType): added SUCC_SUMBOL and NUMBER_OP_SYMBOL to enum BasicTypes * specialSymbolTypes.cc (MACRO): added SuccSymbol and NumberOpSymbol 2002-05-08 Steven Eker * prettyPrint.cc (prettyPrint): (DagNode* version) don't use s^n notation when n = 1 (prettyPrint): (Term* version) support s^n notation 2002-05-02 Steven Eker * prettyPrint.cc (prettyPrint): (DagNode* version) simplified using mpz_class operator<<() * mixfixParser.cc (makeTerm): BigNum -> mpz_class (translateSpecialToken): BigNum -> mpz_class * makeGrammar.cc (makeSpecialProductions): BigNum -> mpz_class * token.cc (split): becomes mpz_class version * token.hh: decl for BigNum split() becomes decl for mpz_class split() * prettyPrint.cc (graphPrint): mpz_class replaces class BigNum (graphCount): mpz_class replaces class BigNum * mixfixModule.hh (CommonTokens): updated decl for graphCount() 2002-05-01 Steven Eker * mixfixParser.cc (insertIterSymbolTerminal): resize() if needed * makeGrammar.cc (makeSpecialProductions): handle productions and terminal insertion for iter symbols * mixfixModule.hh (findIterSymbolIndex): added * mixfixParser.hh (class MixfixParser): added decl for insertIterSymbolTerminal() * mixfixParser.cc (insertIterSymbolTerminal): added * mixfixParser.hh (class MixfixParser): added data member iterSymbolTerminals * mixfixParser.cc (translateSpecialToken): added ITER_SYMBOL case * token.cc (checkForSpecialProperty): check for ITER_SYMBOL property * makeGrammar.cc (makeSymbolProductions): add foo^n(t) syntax for symbols foo with the iter attribute * mixfixParser.hh (class MixfixParser): added MAKE_ITER to enum SemanticActions * mixfixParser.cc (makeTerm): added MAKE_ITER case * token.hh (class Token): added decl for BigNum version of split() * token.cc (split): added BigNum version * mixfixModule.hh (CommonTokens): added decl foriterSymbolNonTerminal() * mixfixModule.cc (iterSymbolNonTerminal): added * makeGrammar.cc (makeGrammar): take iterSymbols into account when calculating componentNonTerminalBase * entry.cc (addOpDeclaration): update iterSymbols * mixfixModule.hh (CommonTokens): added data member iterSymbols * mixfixModule.cc (nonTerminal): use componentNonTerminalBase * makeGrammar.cc (makeGrammar): set componentNonTerminalBase * mixfixModule.hh (CommonTokens): added data member componentNonTerminalBase * token.hh (class Token): added ITER_SYMBOL to SpecialProperties 2002-04-24 Steven Eker * prettyPrint.cc (prettyPrint): (DagNode* version) handle ITER flag/S_Symbol * entry.cc (newFancySymbol): support ITER flag/S_Symbol * modules.y: added syntax for iter attribute * top.y: added KW_ITER * lexer.flex: added iter token * symbolType.hh (class SymbolType): added ITER to enum Flags 2002-04-19 Steven Eker * mixfixParser.cc (insertBubbleProduction): set bubblesAllowed = true; this fixes a nasty bug we introduced when we split out class MixfixParser * mixfixModule.hh (CommonTokens): deleted decl for old instantiatePolymorph() * mixfixModule.cc (instantiatePolymorph): collapse the two versions into a single function (findSymbol): use new instantiatePolymorph() interface * visibleModule.hh (class VisibleModule): updated decl for showSummary() * visibleModule.cc (showSummary): use getParserStats() (showSummary): can't be const since we may force creation of a parser * mixfixParser.hh (getNrProductions): added * mixfixModule.hh (CommonTokens): added decl for getParserStats() * doParse.cc (getParserStats): added * makeGrammar.cc (makeComplexProductions): use new CommonTokens (makeStatementProductions): use new CommonTokens * commonTokens.hh (class CommonTokens): added static data members arrowPlus, arrowStar, arrowBang, suchThat, such, that, mb, cmb, eq, ceq, rl, crl, cq, ifToken * commonTokens.cc (CommonTokens): added tokens arrowPlus, arrowStar, arrowBang, suchThat, such, that, mb, cmb, eq, ceq, rl, crl, cq, ifToken * makeGrammar.cc (makeComponentProductions): arrow2 -> arrow * commonTokens.cc (CommonTokens): arrow2 -> arrow * commonTokens.hh (class CommonTokens): arrow2 -> arrow * mixfix.hh: added fwd decl for class CommonTokens * mixfixModule.cc (MixfixModule): don't init token codes * mixfixModule.hh (MixfixModule): derive from CommonTokens; delete own static token data members * commonTokens.hh: created * commonTokens.cc: created * mixfixModule.hh (class MixfixModule): deleted decl for parseCommand() 2002-04-17 Steven Eker * commands.y: added set omod include command * top.y: added token KW_OMOD * lexer.flex: added keyword omod * mixfixModule.hh (class MixfixModule): deleted decls for showOps(), showVars(), showMbs(), showEqs(), showRls(), showAll(), showSummary() and printAttributes() * prettyPrint.cc (showOps): deleted (printAttributes): deleted (showVars): deleted (showMbs): deleted (showEqs): deleted (showRls): deleted (showAll): deleted (showSummary): deleted * interpreter.hh (endif): added decls for showModule() and showVars() * interpreter.cc (showVars): added (showModule): added * commands.y: use interpreter.showModule(true) for show all command; use interpreter.showVars() for show vars * visibleModule.cc (showVars): added * mixfixModule.hh (class MixfixModule): deletd decl for showSorts(); made AliasMap public (getVariableAliases): added * prettyPrint.cc (showSorts): deleted * commands.y: use showSortsAndSubsorts() * interpreter.hh (endif): added decl for showSortsAndSubsorts() * interpreter.cc (showSortsAndSubsorts): added * visibleModule.hh (class VisibleModule): added decl for showSortsAndSubsorts() * visibleModule.cc (showSortsAndSubsorts): added * mixfixModule.hh (getModuleType): made const * visibleModule.hh (class VisibleModule): added decls for showSorts1(), showSubsorts(), showModule() * visibleModule.cc (showSubsorts): added (showSorts1): added (showModule): added * importModule.cc (donateSorts): use getNrImportedSubsortSorts() * importModule.hh (getNrImportedSorts): added (getNrUserSorts): added (getNrImportedSubsortSorts): added * commands.y: use Interpreter version of showOps() * interpreter.hh (endif): added decl for showOps() * interpreter.cc (showOps): added * visibleModule.cc (showDecls): added (printAttributes): becomes showAttributes() * importModule.cc (donateOps): use getNrImportedDeclarations() (fixUpDonatedOps): use getNrImportedDeclarations() * importModule.hh (getNrImportedSymbols): added (getNrUserSymbols): added (getNrImportedDeclarations): added (getNrUserDeclarations): added * visibleModule.cc (showOps): added 2002-04-16 Steven Eker * visibleModule.hh (class VisibleModule): added decl for printAttributes() * visibleModule.cc (printAttributes): added * symbolType.hh (class SymbolType): added ATTRIBUTES toenum Flags * commands.y: use Interpreter version of showSummary() * interpreter.cc (showSummary): added * interpreter.hh (endif): added decl for showSummary() * mixfixModule.hh (class MixfixModule): deleted decl for showComponents() * prettyPrint.cc (showComponents): deleted * commands.y: use showKinds() in place of showComponents() * interpreter.hh (endif): added decl for showKinds() * interpreter.cc (showKinds): added * visibleModule.cc (showSummary): added * visibleModule.hh (class VisibleModule): added decls for showSummary() and showKinds() * visibleModule.cc (showKinds): added * commands.y: use Interpreter versions of showMbs(), showEqs(), showRls() * interpreter.cc (showMbs): added (showEqs): added (showRls): added * interpreter.hh (endif): added decls for showMbs(), showEqs() and showRls() * compiler.cc (fullCompile): ImportModule -> VisibleModule * loopMode.cc: renamed from loopMode2.cc; ImportModule -> VisibleModule in 4 places * search.cc: renamed from search2.cc; ImportModule -> VisibleModule in 3 places * match.cc: renamed from match2.cc; ImportModule -> VisibleModule in 3 places * execute.cc: renamed from execute2.cc; ImportModule -> VisibleModule in many places * interpreter.hh: ImportModule -> VisibleModule in many places * process.cc (process): ImportModule -> VisibleModule * import.cc (importModule): ImportModule -> VisibleModule * preModule.cc: ImportModule -> VisibleModule in 3 places * preModule.hh: ImportModule -> VisibleModule in many places * visibleModule.hh: created * visibleModule.cc: created 2002-04-15 Steven Eker * mixfixModule.hh (class MixfixModule): deleted decl for specialNameToBasicType() * mixfixModule.cc (specialNameToBasicType): deleted * ops.cc (addHook): use SymbolType::specialNameToBasicType() * symbolType.hh (class SymbolType): added decl for specialNameToBasicType() * symbolType.cc (specialNameToBasicType): added 2002-04-12 Steven Eker * mixfixParser2.cc (getTokenSet): moved here (insertVariableTerminal): fix bug where we were inserting into specialTerminals rather than variableTerminals * mixfixParser.hh (getTokenSet): added * makeGrammar.cc (makeSpecialProductions): use getTokenSet() * prettyPrint.cc (showSummary): temporarily commented out grammar stuff * mixfixModule.hh (class MixfixModule): data member parser becomes a MixfixParser* (class MixfixModule): deleted data members actions, data, specialTerminals, currentSentence, currentOffset, tokens (class MixfixModule): deleted enum Actions (class MixfixModule): delete data member variableTokenCode (class MixfixModule): deleted decl for insertProd() * mixfixModule.cc (makeGrammar): deleted (makeVariableProductions): deleted (makeSpecialProductions): deleted (makePolymorphProductions): deleted (makeBoolProductions): deleted (makeComplexProductions): deleted (makeStatementProductions): deleted (makeComponentProductions): deleted (makeSymbolProductions): deleted (makeLabelProductions): deleted (makeBubbleProductions): deleted * mixfix.hh: added fwd decl for class MixfixParser * doParse.cc: created * mixfixParser2.cc (parseSentence): use nrParses (makeTerms): added (insertStatement): added (parseSentence): treat -ve number of parses as INT_MAX rather than 2 (makeMatchCommand): added (makeSearchCommand): added * mixfixParser.hh (class MixfixParser): added data member nrParses * mixfixParser2.cc (parseSentence): was parseSentence2() (parseSentence): set currentSentence & currentOffset * makeGrammar.cc: created * mixfixParser.hh (class MixfixParser): added decls for insertBubbleProduction(), insertSpecialTerminal(), insertVariableTerminal(), translateSpecialToken() * mixfixParser2.cc (insertVariableTerminal): added (translateSpecialToken): added (parseSentence2): added (MixfixParser): initialize specialTerminals and variableTerminals to maximum needed size (insertVariableTerminal): no need to resize variableTerminals (insertSpecialTerminal): no need to resize specialTerminals (insertProduction): renamed from insertProd() (insertBubbleProduction): added 2002-04-11 Steven Eker * mixfixParser2.cc (insertSpecialTerminal): added * mixfixParser.hh (class MixfixParser): added bubblesAllowed data member * mixfixParser2.cc (MixfixParser): initialize bubblesAllowed flag * mixfixModule.hh (class MixfixModule): updated decl for makeBubble() * mixfixModule.cc (makeBubble): make token arg const * mixfixParser2.cc (makeTerm): removed new variable hack now that new variable symtax is properly supported; use makeBubble() 2002-04-10 Steven Eker * mixfixModule.cc (makeBubble): added * mixfixModule.hh (class MixfixModule): added decl for makeBubble * mixfixParser2.cc (MixfixParser): initialize client * mixfixParser.hh (class MixfixParser): make client a reference rather than a const pointer 2002-04-09 Steven Eker * mixfixParser2.cc: created * mixfixParser.hh: created * mixfixModule.cc (makeTrueTerm): moved here * mixfixModule.hh (class MixfixModule): added decl for makeTrueTerm() (makeTrueTerm): added * mixfixModule.cc (instantiatePolymorph): added new version * mixfixModule.hh (class MixfixModule): added decl for instantiatePolymorph() version that takes a polymorphIndex and a kindIndex * compiler.cc: renamed from compiler2.cc * import.cc (findModule): deleted * preModule.hh (PreModule): deleted decl for findModule() ===================================Maude72================================================== 2002-04-08 Steven Eker * main.hh: added decl for findExecutableDirectory(); updated decl for findPrelude() * main.cc (findExecutableDirectory): added (findPrelude): use executableDirectory; also look for prelude in current directory (findFile): use executableDirectory; also look for users file in executable directory 2002-04-05 Steven Eker * bufferPrint.cc (handleFormat): implemented (bufferPrint): clear globalIndent * execute2.cc (reduce): check getFlag(SHOW_COMMAND) (fRewriteCont): check getFlag(SHOW_COMMAND) (fRewrite): check getFlag(SHOW_COMMAND) (rewriteCont): check getFlag(SHOW_COMMAND) (rewrite): check getFlag(SHOW_COMMAND) * search2.cc (showSearchGraph): check getFlag(SHOW_COMMAND) (showSearchPath): check getFlag(SHOW_COMMAND) (search): check getFlag(SHOW_COMMAND) (searchCont): check getFlag(SHOW_COMMAND) * maudemlBuffer.hh (class MaudemlBuffer): added decls for generateShowSearchPath() and generateShowSearchGraph() * maudemlBuffer.cc (generateShowSearchGraph): added (generateShowSearchGraph): added * search2.cc (showSearchPath): call generateSearchPath() (showSearchGraph): use generateSearchGraph() * maudemlBuffer.cc (generate): renamed to generateSearchGraph() * maudemlBuffer.hh (class MaudemlBuffer): added decl for generateSearchPath() * maudemlBuffer.cc (generateSearchResult): handle NONE case (generateSearchPath): added * search2.cc (doSearching): use new generateSearchResult(); * maudemlBuffer.hh (class MaudemlBuffer): added decl for generateStats(), updated decl for generateSearchResult() * maudemlBuffer.cc (generateSubstitution): removed const_cast (generateStats): added (generateResult): use generateStats() (generateSearchResult): use generateStats() * userLevelRewritingContext.cc (printSubstitution): removed const_cast * mixfixParser.cc (parseTerm2): call makeGrammar() to make sure complex parser is set one way or the other (we fixed the same bug in parseTerm() on 2001-05-01) 2002-04-04 Steven Eker * search2.cc (doSearching): call generateSearchResult() * maudemlBuffer.cc (generateSearchResult): added (generateSubstitution): added (generateAssignment): added * maudemlBuffer.hh (class MaudemlBuffer): added decls for generateSearchResult(), generateSubstitution(), generateAssignment() * search2.cc (searchCont): call generateContinue() * execute2.cc (fRewriteCont): call generateContinue() * maudemlBuffer.hh (class MaudemlBuffer): added decl for generateContinue() * maudemlBuffer.cc (generateContinue): added * execute2.cc (rewriteCont): call enerateContinue() * maudemlBuffer.hh (class MaudemlBuffer): added decls for generateReduce(), generateRewrite(), generateFrewrite(), generateSearch() * maudemlBuffer.cc (generateSearch): added (generateFrewrite): added (generateRewrite): added * execute2.cc (fRewrite): call generateFrewrite() (rewrite): call generateRewrite() * search2.cc (search): call generateSearch() * maudemlBuffer.cc (generateReduce): added * execute2.cc (reduce): call generateReduce() * mixfixModule.hh (class MixfixModule): added decl for buffer version of printPrefixName() * bufferPrint.cc (printPrefixName): added buffer version (prettyPrint): use printPrefixName() * mixfixModule.hh (class MixfixModule): updated decls for buffer versions of printTokens() and printTails(); added decl for handleFormat() * bufferPrint.cc (prettyPrint): pass const SymbolInfo& to printTokens() and printTails() (printTokens): handle format attribute (printTails): handle format attribute (handleFormat): added * preModule.hh (Parent): made checkFormatString() public for metalevel use * loopMode2.cc (printBubble): support \s for space plus ANSI stuff * profileModule.hh (class ProfileModule): added decl for showSymbol() * profileModule.cc (showSymbol): added (showProfile): print builtin/memo rewrites 2002-04-03 Steven Eker * interpreter.cc (showProfile): moved here * interact.cc (clearDebug): moved here * userLevelRewritingContext.hh (clearDebug): use getFlag(Interpreter::EXCEPTION_FLAGS) * interact.cc (commandLoop): use getFlag(Interpreter::EXCEPTION_FLAGS) (handleDebug): use getFlag(Interpreter::TRACE) (2 places) (handleDebug): use getFlag(Interpreter::EXCEPTION_FLAGS) (handleDebug): use interpreter.getFlag(Interpreter::BREAK) * userLevelRewritingContext.hh (setTraceFlag): deleted (setBreakFlag): deleted (class UserLevelRewritingContext): deleted static data members traceFlag and breakFlag * commands.y: use setFlag(Interpreter::TRACE, ) in place of setTraceFlag(); use setFlag(Interpreter::BREAK, ) in place of setBreakFlag(); * interpreter.cc (setFlag): moved here, support EXCEPTION_FLAGS * interpreter.hh (Interpreter): added EXCEPTION_FLAGS to enum Flags * execute2.cc (makeDag): simplified normalize() call * importModule.hh (getNrOriginalMembershipAxioms): added (getNrOriginalEquations): added * mixfixParser.cc (parseSentence2): fixed bug where we were testing for r < 1 rather than r < 0 and treating the no-parse case and ambiguous * importModule.hh (getNrOriginalRules): added 2002-04-02 Steven Eker * mixfix.hh: added few decl for class Compiler * interpreter.hh (endif): added AUTO_CLEAR_PROFILE to DEFAULT_FLAGS * profileModule.cc (clearProfileInfo): beocmes clearProfile() * profileModule.hh (class ProfileModule): clearProfileInfo() -> clearProfile() * execute2.cc (startUsingModule): call clearProfile() if AUTO_CLEAR_PROFILE flag is set * trial.cc (traceBeginEqTrial): call profileEqConditionStart() (traceBeginRuleTrial): call profileRlConditionStart() (traceBeginScTrial): call profileMbConditionStart() (traceEndFragment): call profileFragment() * userLevelRewritingContext.cc (tracePreEqRewrite): call profileEqRewrite() (tracePreRuleRewrite): call tracePreRuleRewrite() (tracePreScApplication): call profileMbRewrite() * interpreter.hh (showProfile): added * commands.y: added commands set profile on/off . set clear profile on/off . show profile . * top.y: added token KW_PROFILE * lexer.flex: TRACE -> KW_TRACE added keyword KW_PROFILE * commands.y: TRACE -> KW_TRACE * top.y: TRACE -> KW_TRACE * mixfixModule.cc (MixfixModule): call ProfileModule ctor * mixfixModule.hh (class MixfixModule): derive from ProfileModule * profileModule.hh (class ProfileModule): added decls for showProfile() and showFragmentProfile() * profileModule.cc (showFragmentProfile): added (showProfile): added * profileModule.hh (class ProfileModule): added decls for profileFragment() and updateFragmentInfo() * profileModule.cc (profileFragment): added (updateFragmentInfo): added 2002-04-01 Steven Eker * profileModule.hh: created * profileModule.cc: created * trial.cc (traceEndFragment): use *preEquation rather than variableInfo * userLevelRewritingContext.hh (class UserLevelRewritingContext): updated traceEndFragment() decl * interact.cc (segmentationFaultHandler): call _exit() rather than exit() because machine state could be very screwed up 2002-03-29 Steven Eker * mixfixParser.cc (parseSentence2): patch possible wrap around error in MSCP10 for highly ambiguous sentences; added DebugAdvisoryCheck() to look for this * trial.cc (traceBeginFragment): rewritten using preEquation and fragmentIndex rather than fragment (traceEndFragment): rewritten using preEquation and fragmentIndex rather than fragment * userLevelRewritingContext.hh (class UserLevelRewritingContext): updated traceBeginFragment() and traceEndFragment() decls to take const PreEquation* and an index rather than ConditionFragment* 2002-03-28 Steven Eker * preModule.hh (Parent): deleted static data member defaultImports * commands.y: use ModuleDatabase::setInclude() * moduleDatabase.hh: NameSet -> IntSet for simplicity * preModule.cc (finishModule): use getIncludes() * moduleDatabase.hh (getIncludes): added (getOmodIncludes): added (class ModuleDatabase): added decls for setInclude() and getOmodIncludes() * moduleDatabase.cc (setInclude): moved here from import.hh (setOmodInclude): added * interpreter.hh (Interpreter): removed creduce() friendship hack * preModule.hh (PreModule): deleted decl for parse() * interpreter.hh (Interpreter): added decl for parse() * commands.y: use Interpreter::parse() * interpreter.cc (parse): moved here from command.cc 2002-03-27 Steven Eker * preModule.cc (PreModule): don't clear isCompiled * preModule.hh (PreModule): delete all the decls for the compilation functions; deleted the various flag static data members; deleted data member isCompiled * compiler2.cc (invalidate): added * preModule.cc (regretToInform): call invalidate() * commands.y: use Interpreter::creduce() * interact.cc (commandLoop): removed hack to unlink executable * compiler2.cc (~Compiler): unlink executable * interpreter.hh (Interpreter): derive from Compiler (Interpreter): added decl for creduce() * execute2.cc (creduce): moved here * commands.y: is Interpreter versions of addSelected(), traceSelect(), breakSelect(), traceExclude(), printConceal() * interpreter.hh (class Interpreter): added data member selected; added decls for addSelected(), traceSelect(), breakSelect(), traceExclude(), printConceal() * interpreter.cc (addSelected): moved here from command.cc (traceSelect): moved here from command.cc (breakSelect): moved here from command.cc (traceExclude): moved here from command.cc (printConceal): moved here from command.cc * commands.y: don't call setShowStats(), setShowLoopStats(), setShowTiming(), setShowBreakdown(), setShowLoopTiming(), setShowCmd(), setAutoClearMemo(), setCompileCount() * preModule.hh (setShowStats): deleted (setShowLoopStats): deleted (setShowCmd): deleted (setShowTiming): deleted (setShowLoopTiming): deleted (setCompileCount): deleted (setAutoClearMemo): deleted * command.cc (selectModule): deleted * interpreter.cc (setCurrentModule): (Vector& version) now implement the guts of selectModule() rather than calling it (setCurrentModule): (PreModule* version) check if the new current module is really the same as the old current module * import.cc ((importModule): use getModule() (findModule): use getModule() * preModule.cc (finishModule): use insertModule() * preModule.hh (PreModule): deleted all continuation data members; deleted savedLoopSubject; deleted the decls for functions that were moved to Interpreter * interpreter.hh (class Interpreter): derive from class ModuleDatabase * compiler.cc (creduce): added hacks * command.cc (loseFocus): don't call clearContinueInfo() * moduleDatabase.hh: created * moduleDatabase.cc: created * interpreter.cc (setCurrentModule): call clearContinueInfo(); * interpreter.hh (setFlag): fixed bug where we were ignoring polarity * match2.cc (match): this -> currentModule * search2.cc (search): this -> currentModule * execute2.cc (reduce): fix bug: need to print currentModule and not this (rewrite): this -> currentModule (fRewrite): this -> currentModule * interpreter.hh (class Interpreter): added DEFAULT_FLAGS to enum Flags * interpreter.cc (Interpreter): use DEFAULT_FLAGS 2002-03-26 Steven Eker * commands.y: rewritten using CM and interpreter * bottom.y (cleanUpParser): call makeClean() * modules.y: rewritten using CM and interpreter * top.y: added #defined CM; commented out definition of currentModule * interpreter.hh (class Interpreter): added many decls * interpreter.cc (setCurrentModule): added PreModule* version (makeClean): added * match2.cc: created from PreModule's match.cc * search2.cc: created from PreModule's search.cc * loopMode2.cc: created from PreModule's loopMode.cc * interpreter.cc (setCurrentModule): added * interpreter.hh (getCurrentModule): added (class Interpreter): added decl for setCurrentModule() * execute2.cc: created from PreModule's execute.cc * interpreter.cc (Interpreter): initialize the new data members * interpreter.hh (setFlag): added (getFlag): added (class Interpreter): added enum Flags, together with a bunch of data members that were static data in PreModule * maudemlBuffer.cc (MaudemlBuffer): pass flushLevel = 1 * xmlBuffer.hh (class XmlBuffer): updated ctor decl; added data member flushLevel * xmlBuffer.cc (endElement): support flushLevel (XmlBuffer): set flushLevel ===================================Maude71a================================================== 2002-03-22 Steven Eker * execute.cc (endRewriting): use generateResult() * maudemlBuffer.cc (generate): (DagNode*) fixed bug with visit PointerSet use (generateResult): added * mixfix.hh: MaudeML_Buffer -> MaudemlBuffer, XML_Buffer -> XmlBuffer * search.cc (showSearchGraph): MaudeML_Buffer -> MaudemlBuffer * execute.cc (endRewriting): MaudeML_Buffer -> MaudemlBuffer * interpreter.cc (beginXmlLog): MaudeML_Buffer -> MaudemlBuffer * interpreter.hh (class Interpreter): MaudeML_Buffer -> MaudemlBuffer * maudemlBuffer.cc: was MaudeML_Buffer.cc * maudemlBuffer.hh: was MaudeML_Buffer.hh * xmlBuffer.cc: was XML_Buffer.cc * xmlBuffer.hh: was XML_Buffer.hh * MaudeML_Buffer.hh (class MaudeML_Buffer): added decls for below functions * MaudeML_Buffer.cc (generate): (DagNode* version) fixed opName bug in string case (generate): added Term* version (generate): added Rule* version (generate): added ConditionFragment* version (generateCondition): added * MaudeML_Buffer.hh (class MaudeML_Buffer): added decl for RewriteSequenceSearch* version of generate() * MaudeML_Buffer.cc (generate): added RewriteSequenceSearch* version * execute.cc (endRewriting): use getXmlBuffer() * main.hh: deleted decl for xmlBuffer global variable * main.cc: added def for global variable interpreter; deleted xmlBuffer global variable (main): support -xml-log= flag * main.hh: added global decl for interpreter * mixfix.hh: removed metalevel decls (should have gone long ago); added decls for classes SymbolType, XML_Buffer, MaudeML_Buffer and Interpreter * interpreter.cc: created * interpreter.hh: created 2002-03-20 Steven Eker * execute.cc (endRewriting): use xmlBuffer->generate() * main.hh: added decl for xmlBuffer global variable * main.cc: added xmlBuffer global variable * MaudeML_Buffer.cc: created * MaudeML_Buffer.hh (class MaudeML_Buffer): created * XML_Buffer.cc: const char* -> const string& throughout * XML_Buffer.hh: created const char* -> const string& * XML_Buffer.cc: created 2002-03-11 Steven Eker * preModule.cc: deleted explicit template instantiations * mixfixModule.cc: deleted explicit template instantiations * main.cc: deleted explicit template instantiations ===================================Maude71================================================== 2002-03-08 Steven Eker * autoWrapBuffer.cc: complete rewrite using new representation (breakLine): fix bug where we were always erasing buffer after printing it out * autoWrapBuffer.hh: rewritten using a string as the pendingBuffer; since we now handle escape sequences there is no bound on the growth of the pending buffer; keep pending width to hold the number of buffered chars excluding tabs and escape sequences * autoWrapBuffer.cc (~AutoWrapBuffer): deleted * autoWrapBuffer.hh (streambuf): added decl for handleChar() * autoWrapBuffer.cc (handleChar): added (overflow): don't call breakLine() if we are processing an escape sequence; since the escape sequence will not increase cursorPosition, any decision on inserting a newline can be deferred. Although a \n following an escape sequence is unlikely it is possible with the format attribute (overflow): use handleChar() (3 places) (resetCursor): clear inEscape flag (AutoWrapBuffer): call resetCursor() * prettyPrint.cc (printPrefixName): addded (prettyPrint): (both versions) use printPrefixName(), in prefix case execute 2nd format exstrcut after prefix name rather than after closing paren 2002-02-28 Steven Eker * entry.cc (newFancySymbol): ModelSymbol -> ModelCheckerSymbol; MODEL_SYMBOL -> MODEL_CHECKER_SYMBOL * specialSymbolTypes.cc (MACRO): ModelSymbol -> ModelCheckerSymbol; MODEL_SYMBOL -> MODEL_CHECKER_SYMBOL * symbolType.hh (class SymbolType): MODEL_SYMBOL -> MODEL_CHECKER_SYMBOL 2002-02-22 Steven Eker * specialSymbolTypes.cc: added SatSolverSymbol * entry.cc (newFancySymbol): added SatSolverSymbol * symbolType.hh (class SymbolType): added SAT_SOLVER_SYMBOL 2002-02-20 Steven Eker * main.cc (main): call isatty() on standard output when deciding whether to enable ANSI escape codes in default case 2002-02-14 Steven Eker * symbolType.hh (hasAllFlags): fixed nasty precedence bug * main.cc (main): replaced -no-escape flag with -ansi-color and -no-ansi-color 2002-02-13 Steven Eker * main.cc (main): handle -no-escape flag (main): don't print banner until we've handled flags * autoWrapBuffer.cc (AutoWrapBuffer): initialize inEscape (overflow): handle escape sequences * autoWrapBuffer.hh (streambuf): added data member inEscape * entry.cc (addPolymorph): allow format attribute for non-mixfix polymorphs (addOpDeclaration): allow format attribute for non-mixfix operators * prettyPrint.cc (prettyPrint): (Term and DagNode versions) support format attribute in not mixfix syntax case * mixfixModule.hh (class MixfixModule): added static data member attributeUsed * prettyPrint.cc (operator<<): (Term and DagNode versions) handle attributeUsed flag (fancySpace): set attributeUsed flag when attribute used * banner.cc (printBanner): colorized "Maude" * prettyPrint.cc (fancySpace): support colors, underlining, bold * ops.cc (checkFormatString): added characters for colors, underlining, bold and original 2002-02-12 Steven Eker * prelude.maude: metaMatch now takes a condition; added format attributes 2002-02-11 Steven Eker * prelude.maude: added op nil : -> EqCondition * match.cc (doMatching): call clearCount() 2002-02-07 Steven Eker * prettyPrint.cc (operator<<): (ConditionFragment version) rewritten to handle EqualityConditionFragment, SortTestConditionFragment, AssignmentConditionFragment and RewriteConditionFragment * mixfixModule.cc: added #includes for new classes * mixfixParser.cc (makeConditionFragment): rewritten to classes EqualityConditionFragment, SortTestConditionFragment, AssignmentConditionFragment and RewriteConditionFragment * importModule.cc (deepCopyCondition): rewritten to handle EqualityConditionFragment, SortTestConditionFragment, AssignmentConditionFragment and RewriteConditionFragment 2002-02-05 Steven Eker * quotedIdentifierOpSymbol.hh (class QuotedIdentifierOpSymbol): deleted static data member eagerStrategy * quotedIdentifierOpSymbol.cc (QuotedIdentifierOpSymbol): deleted strategy argument passed to FreeSymbol() * modules.y: fixed bug where we weren't able to parse "format" as an ordinary identifier since it was not in attrKeyword2 2002-02-04 Steven Eker * prettyPrint.cc (printTokens): fix off by 1 error in final fancySpace() call * mixfixModule.hh (class MixfixModule): updated decl for printTails() * prettyPrint.cc (printTails): handle formatted printing (prettyPrint): (both versions) new printTails() calling convention * mixfixModule.hh (class MixfixModule): updated decl for printTokens() * prettyPrint.cc (printTokens): handle formatted printing (prettyPrint): (both versions) new printTokens() calling convention * entry.cc (addPolymorph): check for bad format length; clear gather/prec/format flags if number of underscore is wrong (this may fix an unobserved bug) (addOpDeclaration): check for bad format length; clear gather/prec/format flags if number of underscore is wrong (this may fix an unobserved bug) * process.cc (processOps): pass format arg to addOpDeclaration() and addPolymorph() * mixfixModule.cc (copyPolymorph): copy format info * importModule.cc (donateOps): pass format to addOpDeclaration() * mixfixModule.hh (getFormat): added (class MixfixModule): added decl for getFormat(); udated decls for addOpDeclaration() and addPolymorph() * entry.cc (addOpDeclaration): support format arg (addPolymorph): support format arg 2002-02-01 Steven Eker * mixfixModule.hh (setPrintFormat): added (class MixfixModule): added format field to struct SymbolInfo * commands.y: added syntax for set print format on/off command * mixfixModule.hh (class MixfixModule): added static data member printFormat * preModule.hh: added decl for check FormatString() * ops.cc (checkFormatString): added * preModule.hh: added decl for setFormat(); added format field to struct OpDef * ops.cc (setFormat): added * modules.y: added syntax for format attribute * top.y: added token KW_FORMAT * lexer.flex: added format token * prettyPrint.cc (operator<<): (DagNode* and Term* versions) clear globalIndent * mixfixModule.hh (class MixfixModule): added static data member globalIndent; (class MixfixModule): added decl for fancySpace() * prettyPrint.cc (fancySpace): added * prelude.maude: simplify using ditto attribute * entry.cc (addOpDeclaration): deleted code that checked for redecl of a variable; added Assert() that this function doesn't handle variables anymore (addOpDeclaration): added check for illegal use of ditto with other attributes (addOpDeclaration): allow symbolTypes to differ if new symbolType just DITTO flag; check for use of ditto without previous declaration to refer to * command.cc (printOpDef): handle ditto attribute * symbolType.hh (class SymbolType): added DITTO to enum Flags * modules.y: added syntax for ditto attribute * top.y: added token KW_DITTO * lexer.flex: added ditto token * prettyPrint.cc (graphPrint): fixed bug where we weren't handling variables, floats and strings as special cases (graphPrint): fixed simalr bug for Qids * mixfixModule.cc (makeSpecialProductions): fix fall thru bug where CONTAINS_COLON fell into ENDS_IN_COLON, creating a spurious production 2002-01-31 Steven Eker * modules.y: rewritten using class SymbolType * ops.cc (addVarDecl): use setBasicType() * command.cc (printOpDef): rewritten using class SymbolType (showModule): rewritten using class SymbolType * mixfixModule.cc (specialNameToFlag): becomes specialNameToBasicType() * ops.cc (setFlag): rewritten using class SymbolType (setPrec): rewritten using class SymbolType (setGather): rewritten using class SymbolType (setStrat): rewritten using class SymbolType (addHook): rewritten using class SymbolType * fixUp.cc (fixUpSymbols): rewritten using class SymbolType * process.cc (checkOpTypes): rewritten using class SymbolType (computeOpTypes): rewritten using class SymbolType (processOps): rewritten using class SymbolType * preModule.hh (Parent): flags field in struct OpDef becomes symbolType * preModule.cc (OpDef): don't clear flags * importModule.cc (donateOps): rewritten using class SymbolType (fixUpDonatedOps): rewritten using class SymbolType * bufferPrint.cc (prettyPrint): rewritten using class SymbolType * prettyPrint.cc: rewritten using class SymbolType 2002-01-30 Steven Eker * specialSymbolTypes.cc (MACRO): use class SymbolType * symbolType.cc: created * symbolType.hh: created * entry.cc: rewritten using class SymbolType * mixfixModule.cc (findSymbol): don't take flags arguments (findSymbol): use getBasicType() (instantiateSortTest): use setBasicType() (instantiateVariable): use setBasicType() (instantiatePolymorph): use getBasicType() (copyPolymorph): use getBasicType() (computePrecAndGather): use hasFlag() (makeSymbolProductions): use hasFlag() and getBasicType() * mixfixModule.hh (class MixfixModule): deleted enum SymbolFlags; int flags replaced by SymbolType symbolType throughout * token.hh: ifdef LIBv3 for libstdc++-v3 * autoWrapBuffer.cc (sync): ifdef LIBv3 for libstdc++-v3 ===================================Maude70================================================== 2002-01-24 Steven Eker * top.y: declared KW_VERBOSE * lexer.flex: added KW_VERBOSE * commands.y: added syntax/semantics for set verbose on/off . 2002-01-23 Steven Eker * search.cc (doSearching): print a "No more solutions" message with timing info after last solution found 2002-01-21 Steven Eker * execute.cc (cont): limit == 0 is a no-op * lexer.flex: don't allow 0 in NUMBER_TOK * search.cc (printSearchTiming): use printStats() (doSearching): clear rewrite count stored in RewriteSequenceSearch context * preModule.hh: updated decl for printSearchTiming() * search.cc (printSearchTiming): print number of rewrites (doSearching): pass RewriteSequenceSearch* to printSearchTiming() (2 places) 2002-01-18 Steven Eker * lexer.flex: allo 0 to be recognized as a NUMBER_TOK in allow 0 to be recognized as a NUMBER in * search.cc (doSearching): use getSubstitition() rather than getContext() (showSearchPath): don't call getStateRule() on state 0 2001-12-21 Steven Eker * userLevelRewritingContext.hh (beAdoptedBy): added (class UserLevelRewritingContext): parent is no longer a const 2001-12-10 Steven Eker * autoWrapBuffer.cc (sync): sync() -> pubsync() (breakLine): xsputc() -> sputc() (2 places) (overflow): xsputc() -> sputc() (3 places) * interact.cc (segmentationFaultHandler): (...) -> int (interruptHandler): (...) -> (int) * entry.cc (newFancySymbol): replaced nested ?: with nested if-then-else to avoid problem with distinct pointers * token.hh: #include -> #include ===================================Maude69================================================== 2001-10-23 Steven Eker * prelude.maude: added trueTerm and falseTerm hooks to op _|=_ 2001-08-08 Steven Eker * search.cc (showSearchGraph): added * lexerAux.cc (getInput): fake a \n for files that don't end in \n in order that commands on the last line work properly, and so that we keep line numbers straight * trial.cc (traceBeginRuleTrial): use new handleDebug() convention * userLevelRewritingContext.cc (tracePreRuleRewrite): use new handleDebug() convention * userLevelRewritingContext.hh (class UserLevelRewritingContext): updated decl for handleDebug() * interact.cc (handleDebug): handle breaking on rule labels * userLevelRewritingContext.hh (dontTrace): delete old version * userLevelRewritingContext.cc (tracePreEqRewrite): use new dontTrace() (tracePreRuleRewrite): use new dontTrace(); don't check traceRuleFlag (tracePreScApplication): use new dontTrace() * trial.cc (traceBeginEqTrial): use new dontTrace() (traceBeginScTrial): use new dontTrace() (traceBeginRuleTrial): use new dontTrace(); don't check traceRuleFlag * userLevelRewritingContext.hh (dontTrace): added two new versions of dontTrace() 2001-06-05 Steven Eker * specialSymbolTypes.cc: added macro for ModelSymbol * entry.cc (newFancySymbol): handle ModelSymbol * mixfixModule.hh (class MixfixModule): added MODEL_SYMBOL to enum SymbolFlags 2001-05-14 Steven Eker * loopMode.cc (doLoop): don't call unprotect(); copy module into savedModule instead (loop): call startUsingModule() (doLoop): don't call clearContinueInfo(), clearTrialCount(), clearMemo() or protect() (contLoop): call startUsingModule() when we try to reinitialize 2001-05-11 Steven Eker * search.cc (doSearching): use UserLevelRewritingContext::aborted() * loopMode.cc (doLoop): use UserLevelRewritingContext::aborted() * match.cc (doMatching): use UserLevelRewritingContext::aborted() (match): use UserLevelRewritingContext::aborted() * execute.cc (endRewriting): use UserLevelRewritingContext::aborted() * userLevelRewritingContext.hh (aborted): added so that we can check the abortFlag in otehr classes of mixfix frontend without having a UserLevelRewritingContext object on which to make a virtual function call to traceAbort() * preModule.hh (Parent): updated decl for printStats() * execute.cc (printStats): take timingFlag (endRewriting): pass timing flag to printStats() * loopMode.cc (doLoop): pass timing flag to printStats() * search.cc (printSearchTiming): test showTiming and isRunning() * match.cc (printMatchTiming): test showTiming and isRunning() * execute.cc (printStats): test showTiming flag * timer.cc (Timer): don't test timingOn (start): don't test timingOn (stop): don't test timingOn (getTimes): don't test timingOn * timer.hh (class Timer): deleted timingOn static data member (setTiming): deleted (isRunning): added 2001-05-10 Steven Eker * search.cc (doSearching): always save state and module so that we can run showSearchPath() on it * preModule.hh (Parent): added decl for showSearchPath() * search.cc (showSearchPath): added * commands.y: added syntax for show path command * top.y: added token KW_PATH * lexer.flex: added keyword path * search.cc (doSearching): print state info with soluntions 2001-05-09 Steven Eker * preModule.hh: added decls for doSearching() and searchCont() * search.cc (doSearching): added (search): rewritten using startUsingModule() and doSearching() (searchCont): added * preModule.hh: added decl for data member savedRewriteSequenceSearch * execute.cc (clearContinueInfo): delete savedRewriteSequenceSearch * match.cc (doMatching): call clearContinueInfo(), clearDebug() and okToCollectGarbage() after we're done matching (match): rewritten using doMatching() and startUsingModule() (doMatching): take Timer& arg and call printMatchTiming() (doMatching): code cleaning * commands.y: make static call to cont(); don't use selectModule() * preModule.hh: make cont() static * execute.cc (cont): use continueFunc for simple function call * preModule.hh : updated decl for beginRewriting(); added decl for startUsingModule(); added decl for static data member savedModule; added static data members savedMatchSearchState and savedSolutionCount (Parent): made rewriteCont(), fRewriteCont(), matchCont() static; make ContinueFuncPtr type a simple pointer to functionn type * execute.cc (clearContinueInfo): unprotect savedModule (startUsingModule): added (beginRewriting): don't call clearTrialCount(), clearMemo(), protect() or clearContinueInfo() here (endRewriting): rewritten (reduce): call startUsingModule(); (rewriteCont): rewritten (rewrite): rewritten (fRewrite): rewritten (fRewriteCont): rewritten 2001-05-08 Steven Eker * loopMode.cc (doLoop): store &PreModule::ruleCont in continueFunc * preModule.hh: updated def for ContinueFuncPtr; added decls for rewriteCont() and fRewriteCont() * execute.cc (rewriteCont): added (fRewriteCont): added (fRewrite): pass &fRewriteCont to endRewriting() (rewrite): pass &rewriteCont to endRewriting() (cont): rewritten 2001-05-07 Steven Eker * match.cc (match): pass duty of garbage collecting pattern to MatchSearchState * preModule.hh: added decl for Term* version of makeDag() * mixfixModule.hh (class MixfixModule): added decl for Vector& version of printCondition() * prettyPrint.cc (printCondition): added const Vector& version (printCondition): use Vector& version * match.cc (match): print out condition when printing out command * search.cc (search): print command if showCmd flag set * match.cc (match): handle NONE rather than UNBOUNDED in no limit case * commands.y: pass NONE to match in no limit case * search.cc (search): use makeDag() * match.cc (match): use makeDag() * execute.cc (makeDag): added Term* version (makeDag): use Term* version 2001-05-04 Steven Eker * preModule.hh (Parent): delete static data member init * loopMode.cc (doLoop): use class timer * preModule.hh (Parent): updated decls for printStats() and endRewriting() * execute.cc (beginRewriting): don't call setitimer() (reduce): use class timer (rewrite): use class timer (fRewrite): use class timer (cont): use class timer (endRewriting): take Timer& arg (printStats): rewritten * preModule.hh (Parent): updated decls for printMatchTiming() and printSearchTiming() * search.cc (search): don't call setitimer(); use class Timer (printSearchTiming): use class Timer * match.cc (match): don't call setitimer(); use class Timer (printMatchTiming): use class Timer * interact.cc (setHandlers): don't ignore SIGALRM, SIGVTALRM, SIGPROF since these are handled by class Timer now * timer.cc: created * timer.hh: created 2001-05-03 Steven Eker * mixfixParser.cc (parseMatchCommand): handle such that condition (parseSearchCommand): handle such that condition * mixfixModule.hh (class MixfixModule): added SUCH_THAT to enum NonTerminal * mixfixModule.cc (makeComplexProductions): allow "s.t." and "such that" syntax for attching conditions to match and search commands * top.y: deleted decls for cTokenBarMatchLeq, cTokenBarMatchLeqColon, cTokenBarMatchLeqNumber, cTokenBarMatchLeqRight; delete static variable pattern * commands.y: deleted MATCH_LEQ and UNIFY_EQ from command mode token types; deleted nonterminals mNumberModuleTerm, mNumberModuleTerm1, mNumberModuleTerm2, mModuleAndTerm, mInEnd, cTokensBarMatchLeq, cTokensBarMatchLeqColon, cTokenBarMatchLeq, cTokenBarMatchLeqColon, cTokenBarMatchLeqNumber, cTokenBarMatchLeqRight * top.y: deleted tokens MATCH_LEQ and UNIFY_EQ * lexer.flex: deleted tokens "<=?" and "=?" from * mixfixParser.cc (parseMatchCommand): added * mixfixModule.hh (class MixfixModule): added decl for parseMatchCommand() * commands.y: changed syntax of match/xmatch commands to parse pattern and subject in a single bubble * preModule.hh (Parent): updated decl for match() * match.cc (printMatchTiming): moved here (match): moved here; now take single bubble argument and use parseMatchCommand() 2001-05-02 Steven Eker * preModule.hh: deleted decls for tryMatch() and dagNodeLt() * search.cc (tryMatch): deleted (search): support limit arg * preModule.hh: updated decl for search() * commands.y: support number in search command * userLevelRewritingContext.hh (class UserLevelRewritingContext): updated decl for printSubstitution() * userLevelRewritingContext.cc (printSubstitution): made Substitution arg a const ref * search.cc (search): rewritten using class RewriteSequenceSearch * mixfixParser.cc (parseSearchCommand): pass searchType via int& for simplicity * mixfixModule.cc (makeComplexProductions): use RewriteSequenceSearch::SearchType * mixfixModule.hh (class MixfixModule): deleted enum SearchType (class MixfixModule): updated decl for parseSearchCommand() * preModule.hh: added decl for tryMatch() * search.cc (tryMatch): added (search): rewritten using tryMatch() and supporting searchType 2001-05-01 Steven Eker * mixfixParser.cc (parseSearchCommand): handle SearchType arg * mixfixModule.hh (class MixfixModule): added enum SearchType (class MixfixModule): parseSearchCommand() decl takes searchType arg * search.cc (search): rewritten using parseSearchCommand() (search): check for variables that are bound before they are used in condition * mixfixModule.hh (class MixfixModule): added decl for parseSearchCommand() * mixfixParser.cc (parseSearchCommand): added * mixfixModule.cc (makeComplexProductions): added productions for SEARCH_CONNECTIVE, SEARCH_COMMAND and MATCH_COMMAND * mixfixModule.hh (class MixfixModule): added static data member gatherAnyAnyAny * mixfixModule.cc (makeComponentProductions): add productions for MATCH_PAIR and SEARCH_PAIR in the complexParser case * mixfixParser.cc (parseTerm): call makeGrammar() to make sure complex parser is set one way or the other * mixfixModule.hh (class MixfixModule): makeCommandProductions() decl becomes makeComplexProductions() (class MixfixModule): decl for nonTerminal() is no longer static * mixfixParser.cc (parseSentence2): don't test before calling makeGrammar() (parseCommand): call makeGrammar() to ensure we have a complex parser * prettyPrint.cc (showSummary): don't test before calling makeGrammar() since makeGrammar() now tests for th existence of parser (showSummary): use nonTerminal() to calculate number of nonterminals * mixfixModule.cc (makeGrammar): take complex flag; check for existence of appropriate kind of parser (makeCommandProductions): becomes makeComplexProductions() (nonTerminal): now depend on complexParser flag * mixfixModule.hh (class MixfixModule): split enum NonTerminal into complex and simple parts (class MixfixModule): added data member complexParser (class MixfixModule): makeGrammar() now takes complex flag 2001-04-27 Steven Eker * search.cc (search): rewritten using MatchSearchState and RewriteSearchState inseatd on OneStep 2001-04-26 Steven Eker * search.cc: removed various experimental crud and got old search facility working (doesn't handle new conditions correctly though) * execute.cc (match): use new MatchSearchState() interface; pattern and context are now local objects rather than pointers to objects on the heap that need to be garbage collected 2001-04-17 Steven Eker * mixfixModule.hh (class MixfixModule): printAttributes() made non-static * prettyPrint.cc (printAttributes): handle config, object and msg attributes * mixfixModule.cc (closeSignature): add object and message info to ConfigSymbols * mixfixModule.hh (class MixfixModule): added data members objectSymbols and messageSymbols * entry.cc (addOpDeclaration): handle OBJECT and MESSAGE flags (newFancySymbol): handle ConfigSymbol * mixfixModule.hh (class MixfixModule): added CONFIG, OBJECT and MESSAGE to enum SymbolFlags * modules.y: added syntax for config, obj and msg attributes * top.y: added tokens KW_CONFIG, KW_OBJ, KW_MSG * lexer.flex (id): added keywords obj, msg and config 2001-04-04 Steven Eker * preModule.hh: added decl for breakSelect() * command.cc (breakSelect): added * commands.y: added set break on/off command; added break select/deselect command . * top.y: aded token KW_BREAK * lexer.flex: added keyword break * userLevelRewritingContext.hh (class UserLevelRewritingContext): added decls for selectBreakSymbols(), setBreakFlag() * interact.cc (selectBreakSymbols): added * userLevelRewritingContext.hh (setBreakFlag): added * interact.cc (commandLoop): take breakFlag into account when calling setTraceStatus() (handleDebug): take breakFlag into account when calling setTraceStatus() * userLevelRewritingContext.hh (clearDebug): take breakFlag into account when calling setTraceStatus() (setTraceFlag): take breakFlag into account when calling setTraceStatus() * interact.cc (handleDebug): support breakFlag * userLevelRewritingContext.hh (class UserLevelRewritingContext): updated decl for handleDebug(); added static data members breakFlag and breakSymbols * userLevelRewritingContext.cc (tracePreEqRewrite): pass redex to handleDebug() (tracePreRuleRewrite): pass redex to handleDebug() (tracePreScApplication): pass subject to handleDebug() * trial.cc (traceBeginEqTrial): pass subject to handleDebug() (traceBeginRuleTrial): pass subject to handleDebug() (traceBeginScTrial): pass subject to handleDebug() ===================================Engine65================================================== 2001-03-30 Steven Eker * preModule.hh (Parent): delete decl for eRewrite() * lexer.flex: use yyInt64 and stringToInt64() * top.y: number and number2 now Int64; yyInt becomes yyInt64 * commands.y: use Token::codeToInt64() throughout * execute.cc (eRewrite): deleted * command.cc (printOpDef): handle frozen attribute * prettyPrint.cc (printAttributes): handle frozen attribute 2001-03-29 Steven Eker * prelude.maude: added ops frozen and metaFrewrite 2001-03-28 Steven Eker * loopMode.cc (doLoop): call resetRules() * execute.cc (beginRewriting): call clearContinueInfo() (rewrite): call resetRules() (fRewrite): call resetRules() * loopMode.cc (doLoop): rewritten * preModule.hh (Parent): updated endRewriting() decl * execute.cc (cont): save continueFunc and savedContext on the stack in case they get overwritten in the debugger; only restore them if we did not abort (endRewriting): rewritten; now handle store of savedContext and continueFunc (rewrite): rewritten (fRewrite): rewritten (cont): rewritten (reduce): rewritten 2001-03-27 Steven Eker * entry.cc (addOpDeclaration): call setFrozen() for frozen symbols * mixfixModule.hh (class MixfixModule): added FROZEN flag to enum SymbolFlags * modules.y: added semantics for frozen attribute * execute.cc (cont): limit is now an Int64 * commands.y: use new rewrite(), eRewrite() and cont() conventions * preModule.hh (Parent): updated decls for rewrite(), eRewrite() and cont() * execute.cc (beginRewriting): don't do saved.setNode(0) (rewrite): use NONE (-1) rather than UNBOUNDED for no limit case, limit is now an Int64 (eRewrite): ditto * command.cc (loseFocus): call clearContinueInfo() rather than doing saved.setNode(0) * preModule.hh: deleted static member saved * loopMode.cc (loop): moved here (contLoop2): moved here (contLoop): moved here (doLoop): moved here (printBubble): moved here (contLoop2): rewritten using savedContext rather than saved (doLoop): rewritten using savedContext rather than saved 2001-03-26 Steven Eker * main.cc (main): support interactive flag; call createRootBuffer() after processing flags and pass forceInteractive flag * lexerAux.cc (handleEof): fixed bug: only include a pending file if we have returned to the top level. (cleanUpLexer): use rootInteractive flag rather than isatty() (createRootBuffer): take forceInteractive flag; set rootInteractive flag (includeFile): pass false to setInteractive() rather than using isatty() (handleEof): only call UserLevelRewritingContext::setInteractive() after we have returned to the top level; use rootInteractive flag rather than isatty() 2001-03-23 Steven Eker * execute.cc (endRewriting): call clearContinueInfo() if module disappears after being unprotected; don't save result (reduce): call clearContinueInfo() * preModule.hh (Parent): added decl for clearContinueInfo() * execute.cc (rewrite): rewritten using savedContext and continueFunc (cont): rewritten using savedContext and continueFunc (fRewrite): rewritten using savedContext and continueFunc (cont): call clearCount() (clearContinueInfo): added * preModule.hh: added static data member savedContext, typedef ContinueFuncPtr and static data member continueFunc * execute.cc (cont): support fairContinue() (fRewrite): use savedContext 2001-03-22 Steven Eker * execute.cc (fRewrite): take gas argument * preModule.hh: updated decl for fRewrite() * commands.y: updated all token rules now that "," is a special token; added syntax for [,] in : . updated syntax for frewrite command * lexer.flex: added "," to tokens that are treated as special in command mode * modules.y: support frozen attribute syntax * preModule.hh: updated decl for printStats(); added static data member showBreakdown (setShowBreakdown): added * execute.cc (endRewriting): pass context to printStats() (doLoop): pass context to printStats() (printStats): support showBreakdown flag 2001-03-20 Steven Eker * top.y: added tokens KW_FROZEN and KW_BREAKDOWN * lexer.flex: added keywords frozen and breakdown 2001-03-16 Steven Eker * execute.cc (endRewriting): count() -> getTotalCount() (doLoop): count() -> getTotalCount() * quotedIdentifierOpSymbol.cc (eqRewrite): incrementCount() -> incrementEqCount() (3 places) 2001-03-13 Steven Eker * preModule.hh (Parent): added decl for fRewrite() * execute.cc (fRewrite): added * commands.y: added syntax for frewrite command 2001-03-06 Steven Eker * preModule.hh (Parent): added decl for eRewrite() * execute.cc (eRewrite): added * commands.y: added syntax for erewite command * top.y: added tokens KW_EREWRITE, KW_FREWRITE, KW_OREWRITE * lexer.flex: added keywords erewrite, frewrite and orewrite 2001-02-22 Steven Eker * importModule.cc (ImportModule): removed unneeded #includes * preModule.cc: removed unneeded #includes ===================================Engine65================================================== 2001-02-21 Steven Eker * fixUp.cc (fixUpSymbols): use dynamic_cast to check that symbol we're about to add an identity to is really a BinarySymbol and not a FreeSymbol created to fix up an error detected earlier 2001-02-20 Steven Eker * descentFunctions.cc (dagifySubstitution): fixed nasty bug where we were failing to delete last created DagRoot if the substitution was badly sorted - this leads to dag nodes that are still reachable after their module (and symbols) have been deleted, causing chaos during the mark phase of the next garbage collect (metaXmatch): fixed bug where we we're counting rewrites done during solve phase of matching (metaMatch): symmetric bug fix 2001-02-14 Steven Eker * metaDownOps.cc (downOpDecl): handle polymorphs having arbitrary junk in "Universal" positions of meta op decl (downOpDecls): static_cast -> safeCast (downBubbleSpec): static_cast -> safeCast (3 places) (downOpDecl): static_cast -> safeCast * metaDownFixUps.cc (fixUpPolymorph): implemented * metaDownOps.cc (downOpDecl): don't call setLineNumber() in normal case (addOpDeclaration() does this if needed) (downOpDecl): added IssueAdvisory() * metaDownFixUps.cc: IssueWarning() becomes IssueAdvisory() (downOpHook): added AdvisoryCheck() (fixUpBubble): simplified using downOpHook() * metaDownOps.cc (downAttr): IssueWarning() becomes IssueAdvisory() * mixfixModule.cc (findSymbol): only try to make a sort test operator if trueSymbol and falseSymbol are defined; actually if they're not both defined we won't get the grammar rules for sort tests but that doesn't stop the user from trying to make them at the meta level, causing a seg fault * metaDownOps.cc (downAttrSet): handle identity arg (downAttr): handle identity arg * metaLevel.hh (class MetaLevel): updated many decls * metaDownOps.cc (downOpDecl): rewritten using new addComplexSymbol() calls (downHookList): renamed to checkHookList() (downIdHook): renamed to checkHook() and rewritten using specialNameToFlag() (downAttr): use checkHookList() * mixfixModule.hh (class MixfixModule): added POLYMORPH to enum SymbolFlags * ops.cc (addHook): simplified using specialNameToFlag() * mixfixModule.hh (class MixfixModule): added decl for specialNameToFlag() * mixfixModule.cc (specialNameToFlag): added * metaDownFixUps.cc (downFixUps): meta fixup stuff moved here * metaDownOps.cc (downHook): handle idHookSymbol case (fixUpPolymorph): added (downFixUpBubble): renamed to fixUpBubble() 2001-02-13 Steven Eker * metaDownOps.cc (downDefaultFixUp): renamed to fixUpSpecialSymbol() (downFixUps): rewritten * metaLevel.hh (class MetaLevel): added ComplexSymbolType * metaModule.cc: rewritten * metaModule.hh: rewritten * metaDownOps.cc: move op/attr/special functions here * importModule.cc (fixUpDonatedOps): allow the case where a donated symbol has both an identity and a special * fixUp.cc (fixUpSymbols): allow a symbol to have both an identity and a special 2001-02-12 Steven Eker * metaLevel.hh (class MetaLevel): added decls for downDefaultFixUp(), downHook(), downOpHook() * metaDown.cc (downOpDecl): use HAS_ATTACHMENTS and don't consider originator flag for ops that have identity or HAS_ATTACHMENTS (downDefaultFixUp): added (downHook): added (downOpHook): added (downFixUps): call downDefaultFixUp() * fixUp.cc (fixUpSymbols): no longer treat QUOTED_IDENTIFIER as a special case * mixfixModule.hh (class MixfixModule): added QUOTED_IDENTIFIER to HAS_ATTACHMENTS disjuction * fixUp.cc (fixUpSymbols): no longer consider originator flag for HAS_ATTACHMENTS symbols (fixUpSymbols): qidBaseSymbol -> qidSymbol (fixUpSymbols): no longer consider originator flag identities; check for and issue warning in case of clashing identities * metaLevelOpSymbol.cc (copyAttachments): added test to protect from multiple calls * metaLevel.cc (bind): Term* version: avoid potential memory leak by using BIND_TERM() macro * interact.cc (commandLoop): flush() cout before input in the case we're no going to call displayPrompt() 2001-02-08 Steven Eker * metaDown.cc (downIdHook): rewritten using specialSymbolTypes.cc * ops.cc (addHook): rewritten using specialSymbolTypes.cc * specialSymbolTypes.cc: created * metaDown.cc: qidBaseSymbol -> qidSymbol throughout (downMachineInt): machineIntBaseSymbol -> machineIntSymbol * metaUp.cc: qidBaseSymbol -> qidSymbol throughout (upMachineInt): machineIntBaseSymbol -> machineIntSymbol * loopSymbol.cc: qidBaseSymbol -> qidSymbol throughout * loopSymbol.hh (class LoopSymbol): qidBaseSymbol -> qidSymbol * metaLevelSignature.cc (MACRO): qidBaseSymbol -> qidSymbol, machineIntBaseSymbol -> machineIntSymbol 2001-02-06 Steven Eker * metaLevelOpSymbol.hh (class MetaLevelOpSymbol): added decls for getCachedRewriteSearchState() and getCachedMatchSearchState(); deleted decl for getCachedState() * descentFunctions.cc (getCachedRewriteSearchState): added (getCachedMatchSearchState): added (getCachedMatchSearchState): added (getCachedState): deleted (metaApply): use getCachedRewriteSearchState() and class RewriteSearchState (metaXapply): use getCachedRewriteSearchState() and class RewriteSearchState (metaMatch): use getCachedMatchSearchState() and class MatchSearchState (metaXmatch): use getCachedMatchSearchState() and class MatchSearchState * execute.cc (match): SearchState -> MatchSearchState * descentFunctions.cc (metaApply): don't pass arg to findNextRewrite(); use addInCount() (metaXapply): don't pass arg to findNextRewrite(); use addInCount() 2001-02-05 Steven Eker * descentFunctions.cc (metaMatch): use getPattern(), getContext() instead of getMatch() (metaXmatch): use getPattern(), getContext() instead of getMatch() (metaApply): use getRule(), getReplacement() and getContext() instead of getResult() (metaXapply): use getRule(), getReplacement() and getContext() instead of getResult() * execute.cc (match): use getPattern(), getContext(), getExtensionInfo() instead of getMatch() * descentFunctions.cc (metaXapply): use PositionState::rebuildDag() (metaApply): use PositionState::rebuildDag() (metaXmatch): use PositionState::rebuildDag() 2001-02-02 Steven Eker * descentFunctions.cc (metaXmatch): getTerm() -> getLhs() * mixfixParser.cc (makeStatement): simplified using default last arg of Equation ctor (makeStatement): simplified using default last arg of Rule and SortConstraint ctors 2001-02-01 Steven Eker * preModule.hh: added decl for printSearchTiming() * search.cc (printSearchTiming): added (search): simplified using printSearchTiming() * execute.cc (match): call clearDebug() since the user may have interrupted rewriting and may have set some debug state (match): check context->traceAbort() after calling state.findNextMatch() (two places) since the user may have interrupted rewriting and then issued an abort command (match): check context->traceAbort() after calling computeTrueSort() (match): call clearMemo() if needed; move context->traceAbort() after contruction of state to aviod memory leak 2001-01-29 Steven Eker * execute.cc (match): handle extension info * descentFunctions.cc (metaXmatch): pass dummy 3rd arg to getMatch() (metaMatch): pass dummy 3rd arg to getMatch() * execute.cc (match): reimplemented using classes Pattern and SearchState 2001-01-23 Steven Eker * lexer.flex: fixed extremely minor bug in that the Maude identifiers .*** and .--- were being treated at end-of-command . followed by comment in CMD_MODE * metaLevelSignature.cc (MACRO): deleted existingModuleSymbol * metaDown.cc (downModule): deleted existingModuleSymbol code 2001-01-19 Steven Eker * quotedIdentifierSymbol.hh (class QuotedIdentifierSymbol): deleted declarations for fixUp() and copyFixUp() * quotedIdentifierSymbol.cc (fixUp): deleted (copyFixUp): deleted * importModule.cc (fixUpDonatedOps): use copyAttachments() in QUOTED_IDENTIFIER case * fixUp.cc (fixUpSymbols): use defaultFixUp() in QUOTED_IDENTIFIER case * quotedIdentifierSymbol.hh (class QuotedIdentifierSymbol): added decls for attachData() and copyAttachments() * quotedIdentifierSymbol.cc (attachData): added (attachData): added (COPY_SORT): added (copyAttachments): added * loopSymbol.cc (attachData): call FreeSymbol::attachData() (copyAttachments): simplified using COPY_SYMBOL and COPY_TERM; call FreeSymbol::copyAttachments() * quotedIdentifierOpSymbol.cc (eqRewrite): use CODE() * quotedIdentifierOpSymbol.hh (class QuotedIdentifierOpSymbol): deleted enum OpType * quotedIdentifierOpSymbol.cc (attachData): don't handle name and type operations (eqRewrite): don't handle name and type operations (copyAttachments): simplified using COPY_SYMBOL and COPY_TERM; call FreeSymbol::copyAttachments() (attachData): simplified using BIND_OP; call FreeSymbol::attachData() (attachSymbol): call FreeSymbol::attachSymbol() 2001-01-18 Steven Eker * preModule.cc (getFlatModule): need to call resetImports() after importStatements() regardless of what happens. This fixes a nasty bug where if we imported statements from the same included module twice in a row (to different importers) without an intervening signature importation the second importantion would quietly fail (because the flag indicate that the statemenst have already been imported) and the second importer would not get the statements. 2001-01-17 Steven Eker * prelude.maude: getName() and getType() are now defined in maude rather than being builtin 2001-01-16 Steven Eker * metaLevelOpSymbol.cc (attachSymbol): simplified using bind() return value (attachTerm): simplified using bind() return value * metaLevel.hh (class MetaLevel): updated decls for bind() (both versions) * metaLevel.cc (bind): return bool (both versions) * metaLevelOpSymbol.hh (class MetaLevelOpSymbol): deleted decls for fixUp(), copyFixUp() * metaLevelOpSymbol.cc (attachSymbol): simplified using BIND_SYMBOL() (fixUp): deleted (copyFixUp): deleted 2001-01-15 Steven Eker * loopSymbol.hh (class LoopSymbol): deleted decls for fixUp(), copyFixUp() * loopSymbol.cc (attachSymbol): simplified using BIND_SYMBOL() (fixUp): deleted (copyFixUp): deleted * quotedIdentifierOpSymbol.hh (class QuotedIdentifierOpSymbol): deleted decls for fixUp(), copyFixUp() * quotedIdentifierOpSymbol.cc (fixUp): deleted (copyFixUp): deleted (attachSymbol): simplified using BIND_SYMBOL() 2001-01-12 Steven Eker * importModule.cc (fixUpDonatedOps): removed special handling for LOOP_SYMBOL * fixUp.cc (fixUpSymbols): removed special handling for LOOP_SYMBOL * mixfixModule.hh (class MixfixModule): added LOOP_SYMBOL to HAS_ATTACHMENTS * loopSymbol.cc (LoopSymbol): clear qidBaseSymbol, nilQidListSymbol, qidListSymbol (copyAttachments): added (attachSymbol): added 2001-01-11 Steven Eker * loopSymbol.cc (attachData): added * loopSymbol.hh (class LoopSymbol): added decls for attachData(), attachSymbol(), copyAttachments() * importModule.cc (fixUpDonatedOps): don't handle QUOTED_IDENTIFIER_OP as a special case * fixUp.cc (fixUpSymbols): don't handle QUOTED_IDENTIFIER_OP as a special case * quotedIdentifierOpSymbol.hh (class QuotedIdentifierOpSymbol): added decls for attachData(), attachSymbol(), copyAttachments() (class QuotedIdentifierOpSymbol): make op an int * quotedIdentifierOpSymbol.cc (QuotedIdentifierOpSymbol): initialize op, quotedIdentifierSymbol, stringSymbol (attachData): added (attachSymbol): added (copyAttachments): added * fixUp.cc (fixUpSymbols): don't handle META_LEVEL_OP_SYMBOL as a special case * importModule.cc (fixUpDonatedOps): don't handle META_LEVEL_OP_SYMBOL as a special case * metaLevelOpSymbol.hh (class MetaLevelOpSymbol): added decls for attachSymbol(), attachTerm(), copyAttachments(), okToBind() * metaLevelOpSymbol.cc (postInterSymbolPass): set metaLevel = shareWith->metaLevel here since we no that this pass will only happen after all fix ups have been done (eqRewrite): don't test and set metaLevel here because in the shareWith case it will already have been done in postInterSymbolPass (copyAttachments): added (attachTerm): added (attachSymbol): added (okToBind): added 2001-01-10 Steven Eker * metaLevelOpSymbol.hh (class MetaLevelOpSymbol): added decl for attachData() * metaLevelOpSymbol.cc (attachData): added * fixUp.cc (fixUpSymbols): use defaultFixUp() for MACHINE_INTEGER_OP, MACHINE_FLOAT_OP, STRING_OP cases * preModule.hh (Parent): added decl for defaultFixUp() * fixUp.cc (defaultFixUp): added * importModule.cc (fixUpDonatedOps): use copyAttachments() in MACHINE_INTEGER_OP, MACHINE_FLOAT_OP, STRING_OP cases 2001-01-05 Steven Eker * descentFunctions.cc (metaXmatch): fixed memory leak where if we obtained a state with remove() but didn't use it because of solutionNr we were not deleting it. (metaMatch): fixed symmetric memory leak (getCachedState): added (metaXapply): fixed memory leak using getCachedState() (metaMatch): use getCachedState() (metaApply): use getCachedState() 2001-01-03 Steven Eker * descentFunctions.cc (metaXmatch): implemented * metaLevel.hh (class MetaLevel): added decls for upNoMatchPair() and upMatchPair() * metaUp.cc (upMatchPair): added (upNoMatchPair): added * descentFunctions.cc (metaMatch): implemented * metaLevel.hh (class MetaLevel): added decl for upNoMatchSubst() * metaUp.cc (upNoMatchSubst): added * metaLevel.hh (class MetaLevel): made upSubstition() public 2000-12-22 Steven Eker * descentFunctions.cc (metaXapply): implemented (metaApply): add 1 to rewrite count for apply here (metaXapply): add 1 to rewrite count for apply here (metaXapply): clone the replacement so we have a dagnode that is only pointed to from one place - so context will build correctly (metaXapply): bring minDepth and maxDepth into int range * metaUp.cc (upFailure4Tuple): added * metaLevel.hh (class MetaLevel): added decls for upResult4Tuple(), upFailure4Tuple(), upContext() * metaUp.cc (upContext): added (upResult4Tuple): added * descentFunctions.cc (metaApply): delete state if we fail 2000-12-21 Steven Eker * descentFunctions.cc (metaApply): added 3 loops to destruct stuff we've finishded with * metaOpCache.cc (insert): must clone metaOp to avoid overwriting (remove): fixed bug where we were return incorrect lastSolutionNr 2000-12-20 Steven Eker * metaOpCache.hh: created * descentFunctions.cc (metaApply): rewritten using MetaOpCache * metaLevel.hh (class MetaLevel): updated decl for downModule() * metaDown.cc (downModule): commented out existingModule code; return MetaModule* rather than ImportModule* * metaModule.hh (class MetaModule): derive from MetaOpCache * metaOpCache.cc: created * descentFunctions.cc (metaWellFormedSubstitution): use DagRoot * metaLevelOpSymbol.hh (class MetaLevelOpSymbol): updated decl for dagifySubstitution() * descentFunctions.cc (dagifySubstitution): use DagRoot (metaApply): use DagRoot for substitutions 2000-12-19 Steven Eker * descentFunctions.cc (metaApply): use new SearchState interface; fix bug where we weren't counting objectContext2 rewrites 2000-12-18 Steven Eker * metaUp.cc (upTerm): const correctness (upAssignment): const correctness * metaLevel.hh (class MetaLevel): const correctness for upTerm() and upAssignment() * quotedIdentifierTerm.hh (getIdIndex): made const * descentFunctions.cc (metaApply): pass substitution and variable infor to upResultTriple() * metaLevel.hh (class MetaLevel): added decls for upSubstition(), upAssignment(); updated decl for upResultTriple() * metaUp.cc (upSubstition): added (upAssignment): added (upSubstition): use upSubstition() * descentFunctions.cc (metaApply): call setInitialSubstitution() 2000-12-14 Steven Eker * descentFunctions.cc (metaApply): make sure state goes out of scope and is deleted before we delete objectContext since ~SearchState writes into this context (can we avoid doing this?) * metaLevel.hh (class MetaLevel): added decls for upResultTriple() and upFailureTriple() * metaUp.cc (upResultTriple): added (upFailureTriple): added * metaLevelOpSymbol.hh (class MetaLevelOpSymbol): added dec for term2RewritingContext() 2000-12-06 Steven Eker * descentFunctions.cc (term2RewritingContext): added 2000-12-05 Steven Eker * descentFunctions.cc (metaWellFormedSubstitution): call dagifySubstitution() (dagifySubstitution): added * metaLevelOpSymbol.hh (class MetaLevelOpSymbol): added decl for noDuplicates() * descentFunctions.cc (noDuplicates): added (metaWellFormedSubstitution): use noDuplicates 2000-12-04 Steven Eker * descentFunctions.cc (metaWellFormedTerm): fixed memory leak where we weren't destructed term (metaWellFormedSubstition): added * descentSignature.cc (MACRO): added decl for metaWellFormedSubstitution * metaDown.cc (downSubstitution): rewritten to treat variables as terms (downAssignment): rewritten to treat variables as terms 2000-11-28 Steven Eker * descentSignature.cc (MACRO): increased the number of args for metaXapply and metaXmatch 2000-11-20 Steven Eker * lexerAux.cc (eatComment): `( and `) no longer count for balancing parens in multiline comments * execute.cc (printBubble): rewritten to do the right thing with \`( etc 2000-11-14 Steven Eker * metaLevelSignature.cc (MACRO): delete decls for membPredSymbol and lazyMembPredSymbol * metaDown.cc (downTerm): commented out special case code for SORT_TEST operators * metaUp.cc (upDagNode): commented out special case code for SORT_TEST operators (upTerm): commented out special case code for SORT_TEST operators * mixfixModule.cc (findSymbol): check for sort tests * metaLevelOpSymbol.hh (class MetaLevelOpSymbol): added decls for metaMaximalSorts() and metaMinimalSorts() * descentSignature.cc (MACRO): added decls for metaMaximalSorts and metaMinimalSorts * descentFunctions.cc (metaMinimalSorts): added (metaMaximalSorts): added * metaLevelOpSymbol.hh (class MetaLevelOpSymbol): added decl for metaGetKinds() * descentFunctions.cc (metaGetKinds): added * descentSignature.cc: added decl for metaGetKinds * metaLevel.hh (class MetaLevel): added decl for upKindSet() * metaUp.cc (upKindSet): added * metaLevelSignature.cc (MACRO): added decls for emptyKindSetSymbol and kindSetSymbol * descentSignature.cc (MACRO): added decl for metaGetKind * metaLevelOpSymbol.hh (class MetaLevelOpSymbol): added decl for metaGetKind() * descentFunctions.cc (metaGetKind): added 2000-11-13 Steven Eker * descentSignature.cc (MACRO): added decls for metaWellFormedModule and metaWellFormedTerm * metaLevelOpSymbol.hh (class MetaLevelOpSymbol): added decls for metaWellFormedModule() and metaWellFormedTerm() * descentFunctions.cc (metaWellFormedModule): added (metaWellFormedTerm): added 2000-11-10 Steven Eker * userLevelRewritingContext.hh (class UserLevelRewritingContext): updated decls for traceBeginFragment() and traceEndFragment() * trial.cc (traceEndTrial): check abortFlag before printing message (traceExhausted): check abortFlag before printing message (traceBeginFragment): take trialRef argument and test it and abortFlag before printing message (traceEndFragment): take trialRef argument and test it and abortFlag before printing message ===================================Engine64================================================== 2000-11-08 Steven Eker * execute.cc (printBubble): rewritten to not print spaces arround special characters 2000-11-01 Steven Eker * descentFunctions.cc (metaLeastSort): rewritten to calculate semantic sort 2000-10-24 Steven Eker * descentFunctions.cc (metaParse): use new upAmbiguity() * metaLevel.hh (class MetaLevel): updated decl for upAmbiguity() * metaUp.cc (upAmbiguity): now take Term*s as arguments * descentFunctions.cc (metaParse): use Term* version of upResultPair() * metaLevel.hh (class MetaLevel): added decl for Term* version of upResultPair() * metaUp.cc (upResultPair): added Term* version * metaLevel.hh (class MetaLevel): added decl for upTerm() * metaUp.cc (upTerm): added * descentFunctions.cc (metaParse): rewritten with new semantics (metaSortLeq): don't call FreeSymbol::eqRewrite() (metaSameKind): don't call FreeSymbol::eqRewrite() * metaLevel.hh (class MetaLevel): added decl for downComponent() * metaDown.cc (downComponent): added * descentSignature.cc (MACRO): metaParse now take 3 arguments * metaLevelSignature.cc (MACRO): added decl for anyTypeSymbol * mixfixModule.hh (class MixfixModule): added decl for parseTerm2() (class MixfixModule): added decl for parseSentence2() * mixfixParser.cc (parseSentence2): added (parseSentence): rewritten in terms of parseSentence2() (parseTerm): allow for parseSentence() returning -1 (parseStatement): allow for parseSentence() returning -1 (parseCommand): allow for parseSentence() returning -1 (parseTerm2): added 2000-10-11 Steven Eker * metaUp.cc (upDagNode): fix bug: Vector args(2) cannot be static because of recursion 2000-10-10 Steven Eker * metaLevelOpSymbol.hh (class MetaLevelOpSymbol): deleted data member op; deleted enum OpType * metaLevelOpSymbol.cc (fixUp): use descentSignature.cc to set descentFunction * descentSignature.cc: created * descentFunctions.cc (metaApply): added stub (metaXapply): added stub (metaMatch): added stub (metaXmatch): added stub * metaLevelOpSymbol.hh (class MetaLevelOpSymbol): deleted decls for errorRewrite() and errorRewrite2() (class MetaLevelOpSymbol): added decls for metaXapply(), metaMatch() and metaXmatch() * metaLevelOpSymbol.cc (eqRewrite): call FreeSymbol::eqRewrite() if our descent function fails * metaLevelSignature.cc: updated noParseSymbol, added ambiguitySymbol, deleted all error constructors * metaLevel.hh (class MetaLevel): added decl for upAmbiguity(); deleted decl for upErrorResultPair(); updated decl for upNoParse() * metaUp.cc (upErrorResultPair): deleted (upMachineInt): added (upNoParse): take badTokenIndex arg (upAmbiguity): added * descentFunctions.cc: descent functions moved here (metaReduce): don't rewrite in error case (metaRewrite): don't rewrite in error case (metaParse): don't rewrite in error case * metaLevelOpSymbol.cc (eqRewrite): greatly simplified using descentFunction pointer to memberFunction 2000-10-09 Steven Eker * token.cc (checkForSpecialProperty): handle null strings rather than asserting that they don't arise ===================================Engine63================================================== 2000-09-14 Steven Eker * bufferPrint.cc (prettyPrint): ugly hack to print variables correctly * metaLevel.hh (class MetaLevel): added decl for upQidList() * metaUp.cc (upQidList): added * metaLevelOpSymbol.cc (metaPrettyPrint): rewritten * metaLevel.hh (class MetaLevel): added decl for upNoParse() * metaUp.cc (upNoParse): added * metaLevelOpSymbol.cc (metaParse): rewritten * metaLevel.hh (class MetaLevel): added decl for upSortSet() * metaUp.cc (upSortSet): added * metaLevelOpSymbol.cc (metaCompleteName): added (eqRewrite): call metaCompleteName() (metaGlbSorts): rewritten (metaLesserSorts): rewritten * metaLevel.hh (class MetaLevel): made downSimpleSort() and downType() public * metaLevelOpSymbol.hh (class MetaLevelOpSymbol): META_SAME_COMPONENT -> META_SAME_KIND; metaSameComponent() -> metaSameKind() * metaLevelOpSymbol.cc (metaLeastSort): rewritten (metaSameComponent): becomes metaSameKind() (metaSameKind): use downType() (fixUp): sameComponent -> sameKind (fixUp): deleted sortInKind (eqRewrite): call metaSameKind() * metaLevel.hh (class MetaLevel): make upType() public * metaLevelOpSymbol.cc (metaSortLeq): rewritten (metaSameComponent): rewritten * metaLevel.hh (class MetaLevel): added decl for upBool() * metaUp.cc (upDagNode): handle MACHINE_FLOAT case (upBool): added * metaDown.cc (downTerm): added FLOAT case * mixfixModule.hh (class MixfixModule): added decl for findMachineFloatSymbol() * mixfixModule.cc (findMachineFloatSymbol): added 2000-09-13 Steven Eker * metaDown.cc (downTerm): support Strings; added missing break * mixfixModule.hh (class MixfixModule): added decl for findStringSymbol() * mixfixModule.cc (findStringSymbol): added * metaDown.cc (downTerm): use downType2() (2 places) * metaLevel.hh (class MetaLevel): added decl for downType2() * metaDown.cc (downType2): added (downType): use downType2() * metaLevelOpSymbol.cc (metaRewrite): rewritten * metaDown.cc (downTerm): fixed bug where we were useing id rather than cName * token.cc (doubleToCode): fill in auxProperties (int64ToCode): fill in auxProperties * metaLevelOpSymbol.cc (metaReduce): rewritten * metaUp.cc (upResultPair): added (upType): added (upErrorResultPair): added * metaLevel.hh (class MetaLevel): added decls for upQid(), upJoin(), upConstant(), upVariable(), upDagNode() * metaUp.cc: created 2000-09-12 Steven Eker * metaLevel.hh (class MetaLevel): deleted downVariable() * metaDown.cc (downTerm): rewritten (downVariable): deleted * metaLevel.hh (class MetaLevel): added decls for downCondition(), downConditionFragment() * metaDown.cc (downCondition): added (downConditionFragment): added (downMembAx): use downCondition() (downEquation): use downCondition() (downRule): use downCondition() * token.cc (splitKind): added * token.hh (class Token): added decl for splitKind() * metaLevel.hh (class MetaLevel): added decls for downTypeList() and downType() * metaDown.cc (downMachineIntList): don't recognize empty MachineInt lists (downTypeList): added (downType): added (downOpDecl): use downTypeList() and downType() 2000-09-11 Steven Eker * metaLevel.hh (class MetaLevel): added decl for downSort() (class MetaLevel): deleted decls for downQidSet() downVarDecls(), downVarDecl() * metaDown.cc (downModule): don't call downVarDecls(); vhanged arg number for md, eq and rl parts (downImport): handle protectingSymbol (downQidSet): becomes downSortSet() (downSort): added (downSortSet): becomes donwSorts() (downVarDecls): deleted (downVarDecl): deleted * metaLevelOpSymbol.hh (class MetaLevelOpSymbol): added META_XAPPLY, META_MATCH, META_XMATCH, META_COMPLETE_NAME, META_SORT_IN_KIND to enum OpType * metaLevelOpSymbol.cc (fixUp): added meta-xapply, meta-match, meta-xmatch, completeName, sortInKind * metaLevelSignature.cc (MACRO): deleted nilMachineIntListSymbol (MACRO): complete rewrite 2000-09-08 Steven Eker * quotedIdentifierOpSymbol.hh (class QuotedIdentifierOpSymbol): enum OpType simplified * quotedIdentifierOpSymbol.cc: implemented "constantName", "constantType", "variableName" and "variableType" operations (fixUp): simplified just to "name" and "type" due to subsort polymorphic overloading * quotedIdentifierOpSymbol.hh (class QuotedIdentifierOpSymbol): added new constants to enum OpType * quotedIdentifierOpSymbol.cc (fixUp): added opNames "constantName", "constantType", "variableName" and "variableType" * token.cc (split): split og '.' as well as ':' * quotedIdentifierSymbol.cc (determineSort): use Token::auxProperty() * token.hh (class Token): added decls for computeAuxProperty() and skipSortName() * token.cc (computeAuxProperty): added (skipSortName): added (checkForSpecialProperty): call computeAuxProperty() * token.hh (class Token): removed CONTAINS_DOT, BRACKETED from enum SpecialProperties; (class Token): added enum AuxProperties (class Token): added static data member auxProperties (auxProperty): added (class Token): added decl for auxProperty() * importModule.cc (fixUpDonatedOps): do incremental fixup for symbols with QUOTED_IDENTIFIER flag 2000-09-06 Steven Eker * quotedIdentifierSymbol.cc (copyFixUp): fix bug where we were translating our sorts rather than original sorts * fixUp.cc (fixUpSymbols): call fixUp() on QuotedIdentifierSymbols * importModule.cc (fixUpDonatedOps): call copyFixUp() on QuotedIdentifierSymbols * metaLevelSignature.cc (MACRO): NA_Symbol* -> QuotedIdentifierSymbol* * metaDown.cc (downTerm): NA_Symbol* -> QuotedIdentifierSymbol* (downFixUpBubble): NA_Symbol* -> QuotedIdentifierSymbol* (2 places) * fixUp.cc (fixUpSymbols): cast to QuotedIdentifierSymbol* (3 places) * entry.cc (newFancySymbol): create new QuotedIdentifierSymbol * mixfixParser.cc (makeTerm): cast to QuotedIdentifierSymbol* * mixfixModule.cc (findQuotedIdentifierSymbol): cast to and return QuotedIdentifierSymbol* (copyFixUpBubbleSpec): cast to QuotedIdentifierSymbol* (fixUpBubbleSpec): 2nd arg is now a QuotedIdentifierSymbol* * mixfixModule.hh (class MixfixModule): updated decl for fixUpBubbleSpec() (class MixfixModule): updated decl for findQuotedIdentifierSymbol() (class MixfixModule): qidSymbol in struct BubbleSpec becomes a QuotedIdentifierSymbol* * loopSymbol.cc (fixUp): first arg is now a QuotedIdentifierSymbol* (copyFixUp): cast to QuotedIdentifierSymbol* * loopSymbol.hh (class LoopSymbol): qidBaseSymbol becomes a QuotedIdentifierSymbol (class LoopSymbol): updated fixUp() decl * quotedIdentifierOpSymbol.cc (fixUp): 2nd arg now a QuotedIdentifierSymbol* (copyFixUp): cast to QuotedIdentifierSymbol* * quotedIdentifierOpSymbol.hh (class QuotedIdentifierOpSymbol): updated decl for fixUp(); quotedIdentifierSymbol is now a QuotedIdentifierSymbol* * quotedIdentifierDagNode.cc (QuotedIdentifierDagNode): first arg is now a QuotedIdentifierSymbol* (overwriteWithClone): cast to QuotedIdentifierSymbol* (makeClone): cast to QuotedIdentifierSymbol* * quotedIdentifierDagNode.hh (class QuotedIdentifierDagNode): updated ctor decl * quotedIdentifierTerm.cc (QuotedIdentifierTerm): first arg is now a QuotedIdentifierSymbol* (deepCopy2): cast to QuotedIdentifierSymbol* (overwriteWithDagNode): cast to QuotedIdentifierSymbol* (makeDagNode): cast to QuotedIdentifierSymbol* * quotedIdentifierTerm.hh (class QuotedIdentifierTerm): updated ctor decl * mixfix.hh: added class QuotedIdentifierSymbol * quotedIdentifierSymbol.cc: created * token.hh (class Token): added CONTAINS_DOT and BRACKETED * quotedIdentifierSymbol.hh: created 2000-08-30 Steven Eker * prettyPrint.cc (showAll): don't display kinds (showSorts): use new formula for nrSorts * command.cc (parse): use Term::getSort() rather than ComplexSort() * prettyPrint.cc (showOps): don't use ComplexSort() * compiler.cc (creduce): use DagNode::getSort() rather than ComplexSort() * execute.cc (endRewriting): use DagNode::getSort() rather than ComplexSort() (doLoop): use DagNode::getSort() rather than ComplexSort() * userLevelRewritingContext.cc (tracePreScApplication): use DagNode::getSort() rather than ComplexSort() * prettyPrint.cc (operator<<): treat nil sort pointer as "(SORT UNKNOWN)" * command.cc (operator<<): don't put space after comma in kind name * mixfixParser.cc (makeTerm): allow sortName to be NONE in MAKE_VARIABLE case * token.cc (split): return suffix as NONE for tokens ending in : * mixfixModule.hh (class MixfixModule): added ENDS_IN_COLON_NT to enum NonTerminal; BASE = -22 * mixfixModule.cc (makeComponentProductions): support ( ) . [ ] disambiguation (makeComponentProductions): added syntax for sort lists (makeSpecialProductions): handle ENDS_IN_COLON * mixfixModule.hh (class MixfixModule): added SORT_LIST_TYPE to enum NonTerminalType; NUMBER_OF_TYPES = 5 * prettyPrint.cc (showSummary): fix # user sorts, now that sorts and error sorts (kinds) end up in sort vector (showComponents): don't use ComplexSort (showSorts): don't output information on kinds (showSummary): call makeGrammar if we don't have any productions * fixUp.cc (findHookSymbol): look for ~> rather than -> in op-hooks ===================================Engine62================================================== 2000-08-29 Steven Eker * top.y: added decl for indentifier; added decl for ',' * modules.y: added identifier nonterminal * lexer.flex: ',' now returns ',' rather than IDENTIFIER in ID_MODE * preModule.hh (Parent): added friend decl for operator<< * command.cc (printOpDef): use types rathe than domainAndRangeTokens (operator<<): added for PreModule::Type * preModule.hh (Parent): added decls for checkOpTypes(), checkType(), computeOpTypes(), computeType() * process.cc (checkOpTypes): added (checkType): added (computeOpTypes): added (computeType): added (processSorts): don't look up sorts occuring in op declarations (process): call checkOpTypes() and computeOpTypes() 2000-08-28 Steven Eker * ops.cc (addVarDecl): now just take a token * modules.y: deleted listBarColon; added varNameList * preModule.hh: addSortSpec() -> addType(); struct SortSpec -> struct type * ops.cc (addSortSpec): becomes addType() (addType): rewrittenusing types nomenclature (convertSortsToKinds): rewritten using types nomenclature * modules.y: sortSpec -> type; sortSpecList -> typeList; addSortSpec() -> addType() * top.y: deleted tokenBarArrow; arrow declared type ; sortToken declared type * preModule.hh (Parent): added decls for addSortSpec() and convertSortsToKinds(); deleted decl for setDomainAndRange() * ops.cc (setDomainAndRange): deleted (convertSortsToKinds): added * lexer.flex: added KW_PARTIAL * top.y: added KW_PARTIAL * modules.y: added PARTIAL to most nonterminal that accept ARROW; deleted nonterminal tokenBarArrow 2000-08-25 Steven Eker * modules.y: deleted listBarArrow; added arrow and call to convertSortsToKinds() 2000-08-22 Steven Eker * modules.y: added non-terminals attrKeyword2, sortToken, sortTokens and sortSpec added non-terminal sortSpecList and redefined domainRangeAttr * ops.cc (addSortSpec): added * preModule.hh: added struct SortSpec; domainAndRangeTokens becomes sortSpecs 2000-07-31 Steven Eker * importModule.cc (donateOps): use an ImportTranslation to translate sorts in operator decls so that error sorts are translated correctly * importTranslation.cc (translate): (Sort* version): moved here (translate): (Sort* version): translate error sorts correctly * prettyPrint.cc (operator<<): added Sort* version * metaFastUp.cc (fastUpSort): removed hack for handling union sorts since they should no longer exist ===================================Engine61================================================== 2000-07-28 Steven Eker * trial.cc (traceBeginFragment): handle firstAttempt arg * userLevelRewritingContext.hh (class UserLevelRewritingContext): added firstAttempt arg to traceBeginFragment() decl * prettyPrint.cc (operator<<): (ConditionFragment*) version (printCondition): use ConditionFragment* operator<< * trial.cc (traceBeginFragment): added (traceEndFragment): added * userLevelRewritingContext.hh (class UserLevelRewritingContext): added decls for traceBeginFragment() and traceEndFragment() * execute.cc (match): use getNrProtectedVariables() instead of nrVariables() (2 places) * userLevelRewritingContext.cc (printSubstitution): use getNrRealVariables() instead of nrVariables(); now assert that we're not dealing with an abstraction variable * metaFastUp.cc (fastUpSubstitution): use getNrRealVariables() instead of nrVariables() * metaLevelOpSymbol.cc (metaApply): use getNrRealVariables() instead of nrVariables() (initializeSubstitution): use getNrRealVariables() instead of nrVariables() 2000-07-25 Steven Eker * command.cc (dump): added * preModule.hh (Parent): added decl for dump() * commands.y: added dump command * top.y: added KW_DUMP * lexer.flex: added KW_DUMP 2000-07-21 Steven Eker * userLevelRewritingContext.cc (printSubstitution): handle unbound variables 2000-07-19 Steven Eker * mixfixModule.cc (instantiateSortTest): changed concrete syntax for sort test operators * mixfixModule.hh (class MixfixModule): update friend decl * prettyPrint.cc (printCondition): print /\ bewteen fragments (operator<<): term version now takes const 2nd arg (operator<<): cast away const for the moment * mixfixModule.hh (class MixfixModule): updated makeCondition() decl; added makeConditionFragment() decl * mixfixParser.cc (makeCondition): rewritten (makeConditionFragment): added (makeStatement): use new makeCondition() * mixfixModule.cc (makeStatementProductions): generate productiosn for complex conditions (makeBoolProductions): now we allow condition fragments just to be a bool 2000-07-18 Steven Eker * mixfixModule.cc (MixfixModule): initialize assign, colon3 and wedge (makeBoolProductions): use COLON2_PAIR in place of COLON_PAIR and COLON3_PAIR in place of COLON2_PAIR * mixfixModule.hh (class MixfixModule): added static data members assign, colon3 and wedge (class MixfixModule): added COLON3_PAIR, ASSIGN_PAIR, RULE_CONDITION, CONDITION_FRAGMENT, RULE_CONDITION_FRAGMENT to enum NonTerminal * userLevelRewritingContext.cc (tracePreScApplication): use getSort() * prettyPrint.cc (operator<<): use getLhs(), getSort() (operator<<): use getLhs(), getRhs() (operator<<): use getLhs(), getRhs(), getLabel() * metaLevelOpSymbol.cc (metaApply): use getLabel() * importModule.cc (deepCopyCondition): use Sort* translate() (donateStatements): use Sort* translate() (donateStatements): use deepCopyCondition() (3 places) and new statement ctors (donateStatements): use getLhs(), getRhs() (donateStatements): use getSort() (donateStatements): use getLabel() * importTranslation.cc (translate): simplified using new translate() functions * importTranslation.hh (class ImportTranslation): added decl for Sort* version of translate() (translate): (Sort* version) added (class ImportTranslation): added decl for ConnectedComponent* version of translate() (translate): (ConnectedComponent* version) added 2000-07-17 Steven Eker * importModule.hh (class ImportModule): added decl for deepCopyCondition() * importModule.cc (deepCopyCondition): added * mixfixParser.cc (makeStatement): use new Rule and SortConstraint ctors * mixfixModule.hh (class MixfixModule): added decl for printCondition() * prettyPrint.cc (printCondition): added (operator<<): (Rule, Equation and SortConstraint versions) use printCondition() 2000-07-14 Steven Eker * mixfixParser.cc (makeStatement): use new Equation ctor 2000-06-28 Steven Eker * mixfixModule.hh (class MixfixModule): changed overloadedMachineFloats from set to set * prettyPrint.cc (prettyPrint): handle pseudo variables (both versions) * mixfixParser.cc (parseSentence): use findSort() * mixfixModule.cc (makeSpecialProductions): use findSort() * entry.cc (addSort): rewritten (addOpDeclaration): use findSort() to check for existance of sort * mixfixModule.cc (findSort): rewritten using map * mixfixModule.hh (class MixfixModule): changed sortNames from an IntSet to a map * entry.cc (addOpDeclaration): check for pseudo variables * mixfixModule.hh (class MixfixModule): added PSEUDO_VARIABLE to InternalFlags * entry.cc (newFancySymbol): no longer create variable symbols here * lexerAux.cc (eatComment): use outputLine() * fileTable.hh (class FileTable): added decl for outputLine() * fileTable.cc (beginModule): use outputLine() (outputLine): added * lexerAux.cc (eatComment): handle OBJ3 style pass-through comments * lexer.flex: treat ---> equal to ***> and replace char with yyless(0); treat --- equal to *** * mixfixModule.hh (class MixfixModule): added decl for printVariable() * prettyPrint.cc (printVariable): added (prettyPrint): use printVariable() (both versions) * mixfixModule.hh (class MixfixModule): added decl for setPrintWithAliases() and static data member printWithAliases (setPrintWithAliases): added * lexer.flex: added KW_ALIASES; made paren synonym for parens * top.y: added KW_ALIASES * commands.y: added syntax for print with aliases on/off . * userLevelRewritingContext.cc (printSubstitution): use const_cast<> default pretty printer is used for variable term * mixfixModule.cc (makeSymbolProductions): need to use if-then-continue after all since we can makeGrammar() at any time now that parsers get deleted and reconstructed * mixfixModule.hh (class MixfixModule): deleted INVISIBLE from enum SymbolFlags; deleted decl for findInvisibleVariable() * mixfixModule.cc (makeSymbolProductions): check for VARIABLE rather than INVISIBLE; use Assert() that than if-then-continue since these kind of symbols should not have be created prior to generating the grammar (findSymbol): no need to check for INVISIBLE symbols now (findInvisibleVariable): deleted * entry.cc (addOpDeclaration): removed uses of INVISIBLE flag 2000-06-27 Steven Eker * prettyPrint.cc (showVars): use variableAliases * mixfixModule.cc (instantiateVariable): cannot use variableTokenCode since we may not have made the grammar (nowadays it's only made when we need to parse something); instead we use sort->id() - ugly but it should never be seen by user * importTranslation.cc (translate): use instantiateVariable() * importModule.cc (donateOps): check for variable and sort test symbols; these shound no longer be among user symbols to be donated * mixfixParser.cc (makeTerm): handle MAKE_VARIABLE_FROM_ALIAS * mixfixModule.hh (class MixfixModule): added decl for makeVariableProductions() * mixfixModule.cc (makeVariableProductions): added (makeGrammar): call makeVariableProductions() * mixfixModule.hh (class MixfixModule): added decl for addVariableAlias() * entry.cc (addVariableAlias): added * mixfixModule.hh (class MixfixModule): added variableAliases data member * process.cc (processOps): use addVariableAlias() * prettyPrint.cc (prettyPrint): support variables (both versions) * mixfixModule.cc (instantiateVariable): translate variableTokenCode to actual variable token code * token.cc (checkForSpecialProperty): get CONTAINS_COLON, ENDS_IN_COLON the right way around (extractMixfix): need to do processing on tokens with CONTAINS_COLON and ENDS_IN_COLON otherwise we could lose mixfix syntax for sort test operators 2000-06-26 Steven Eker * mixfixModule.hh (class MixfixModule): added decl for instantiateSortTest() * mixfixModule.cc (instantiateVariable): added * mixfixParser.cc (parseSentence): handle undeclared variables (makeTerm): handle makeVariable * mixfixModule.cc (makeComponentProductions): fill out variableTokenCode and add productions for undeclared variables * mixfixModule.hh (class MixfixModule): added data members variableTokenCode and variableBase * token.hh (class Token): added decl for split * token.cc (split): added * mixfixModule.hh (class MixfixModule): added MAKE_VARIABLE and MAKE_VARIABLE_FROM_ALIAS to enum Actions * mixfixModule.cc (makeSpecialProductions): added code for ::= X:Foo where X:Foo is known token * token.cc (checkForSpecialProperty): check for colons * token.hh (class Token): added special properties CONTAINS_COLON and ENDS_IN_COLON * userLevelRewritingContext.cc (printSubstitution): use VariableTerm* instead of VariableSymbol*; use getSort() (printSubstitution): use safeCast() ===================================Engine57================================================== 2000-06-19 Steven Eker * fixUp.cc (fixUpSymbols): pass decFloatSymbol to string op fixUp() 2000-06-13 Steven Eker * fixUp.cc (fixUpSymbols): pass machineFloatSymbol to string op fixUp() 2000-06-12 Steven Eker * fixUp.cc (fixUpSymbols): pass machineIntegerSymbol to fix up of MachineFloatOpSymbol * importModule.cc (fixUpDonatedOps): handle importation of MACHINE_FLOAT_OPs * fixUp.cc (fixUpSymbols): support MACHINE_FLOAT_OP * mixfixModule.hh (class MixfixModule): added FLOAT_NT to enum NonTerminal * mixfixModule.cc (makeSpecialProductions): support floats * token.hh (class Token): added LAST_PROPERTY to enum SpecialProperties * mixfixModule.cc (makeSymbolProductions): support MACHINE_FLOAT * mixfixModule.hh (class MixfixModule): added MAKE_MACHINE_FLOAT to enum Actions * mixfixParser.cc (makeTerm): support MAKE_MACHINE_INT * bufferPrint.cc (prettyPrint): support machine floats * prettyPrint.cc (prettyPrint): (both versions) support machine floats * token.hh (class Token): added decls for codeToDouble() and doubleToCode() * token.cc (codeToDouble): added (doubleToCode): added * entry.cc (addOpDeclaration): update machineFloatSymbols (newFancySymbol): support MACHINE_FLOAT and MACHINE_FLOAT_OP * mixfixModule.hh (class MixfixModule): added data members overloadedMachineFloats and machineFloatSymbols (class MixfixModule): added PSEUDO_MACHINE_FLOAT to enum InternalFlags * entry.cc (addOpDeclaration): added check for pseudo machine floats * ops.cc (addHook): added MachineFloatSymbol and MachineFloatOpSymbol hooks 2000-06-09 Steven Eker * mixfixModule.hh (class MixfixModule): added MACHINE_FLOAT and MACHINE_FLOAT_OP to enum SymbolFlags * token.cc (checkForSpecialProperty): added identification for Floats * token.hh (class Token): added FLOAT to enum SpecialProperties 2000-05-23 Steven Eker * metaDown.cc (downModule): check for bad module after closing sort set and after downing fixups 2000-05-19 Steven Eker * token.cc (bubbleToPrefixNameCode): fixed nasty bug where we were putting ` at start 2000-05-17 Steven Eker * token.cc (extractMixfix): rewritten to handle strings * token.hh (class Token): deleted decl for prefixNameCode() * token.cc (prefixNameCode): deleted prefixNameCode() * ops.cc (addOpDecl): no longer treat one token as a special case * fixUp.cc (findHookSymbol): use bubbleToPrefixNameCode() * command.cc (addSelected): use bubbleToPrefixNameCode() * token.hh (makePrefixName): use bubbleToPrefixNameCode() (class Token): added decl for bubbleToPrefixNameCode() * token.cc (ropeToPrefixNameCode): handle quoted strings within rope (bubbleToPrefixNameCode): added * lexer.flex: redefined maudeId to allow multiple double quoted strings with in a maudeId * quotedIdentifierOpSymbol.cc (eqRewrite): use ropeToPrefixNameCode() * token.hh (class Token): added decl for ropeToPrefixNameCode() * token.cc (ropeToPrefixNameCode): added 2000-05-16 Steven Eker * fixUp.cc (fixUpSymbols): don't pass machineIntegerSymbol, trueTerm and falseTerm to QuotedIdentifierOpSymbol * quotedIdentifierOpSymbol.cc (postInterSymbolPass): deleted (copyFixUp): don't copy trueTerm and falseTerm * quotedIdentifierOpSymbol.hh (class QuotedIdentifierOpSymbol): deleted decls for reset() and postInterSymbolPass(); updated decl for fixUp() * quotedIdentifierOpSymbol.cc (fixUp): don't set trueTerm and falseTerm (reset): deleted * quotedIdentifierOpSymbol.hh (class QuotedIdentifierOpSymbol): deleted data members trueTerm and falseTerm * quotedIdentifierOpSymbol.cc (fixUp): don't set machineIntegerSymbol; don't handle CONC, INDEX, STRIP, CONVERT and LESS_THAN (copyFixUp): don't copy machineIntegerSymbol (eqRewrite): don't handle CONC, INDEX, STRIP, CONVERT and LESS_THAN * quotedIdentifierOpSymbol.hh (class QuotedIdentifierOpSymbol): deleted data member machineIntegerSymbol; (class QuotedIdentifierOpSymbol): updated fixUp() decl (class QuotedIdentifierOpSymbol): deleted CONC, INDEX, STRIP, CONVERT and LESS_THAN from enum OpType * fixUp.cc (fixUpSymbols): support stringBaseSymbol for QuotedIdentiferOpSymbols * quotedIdentifierOpSymbol.cc (fixUp): hanle stringSymbol arg (copyFixUp): copy stringSymbol (eqRewrite): added QID and STRING operations * quotedIdentifierOpSymbol.hh (class QuotedIdentifierOpSymbol): added data member stringSymbol; (class QuotedIdentifierOpSymbol): updated fixUp() decl * quotedIdentifierOpSymbol.cc (fixUp): added support for STRING and QID * quotedIdentifierOpSymbol.hh (class QuotedIdentifierOpSymbol): added STRING and QID to enum OpType * token.cc (checkForSpecialProperty): use stringToInt64() to decide if a token could represent a MachineInt * quotedIdentifierOpSymbol.cc (eqRewrite): use new int64ToString() * metaFastUp.cc (fastUpTerm): (both versions) use int64ToCode() * bufferPrint.cc: use int64ToCode() * token.hh (class Token): int64ToString() decl becomes int64ToCode() * token.cc (codeToInt64): use stringToInt64() (int64ToString): becomes int64ToCode(); (int64ToCode): use int64ToString() 2000-05-15 Steven Eker * token.cc (ropeToString): support \a (alert/bell) and \v (vertical tab) (codeToRope): support \a (alert/bell) and \v (vertical tab) * lexer.flex: exclude control chars from stringContent; fix \\" bug; exclude control chars from normal token -> maudeId, stringToken -> stringId, regularToken -> regularId; use RETURN(*yytext) in 2 places 2000-05-12 Steven Eker * lexer.flex: reformulated notion of token to make it simpler and to exclude "s except as part of a double quoted identifier (or quoted double quoted identifier (actually token really corresponds to MaudeId in other discussions) 2000-05-08 Steven Eker * modules.y: use setLatexMacro() * preModule.hh (Parent): added decl for setLatexMacro() * ops.cc (setLatexMacro): added * preModule.hh: added latexMacro field to struct OpDef 2000-05-04 Steven Eker * lexerAux.cc (lexerLatexMode): clear latexCode * lexer.flex: use latexCode variable to assemble latex string, to avoid what looks tike a flex bug when we try to assemble it implicitly in yytext 2000-05-03 Steven Eker * top.y: added token decl for LATEX_TOK * modules.y: use lexerLatexMode() * lexerAux.cc (lexerLatexMode): added * lexer.flex: added start condition LATEX_MODE * compiler.cc (fullCompile): changed names for environment variables; don't unlink source files ifdef ANNOTATE 2000-04-25 Steven Eker * entry.cc (newFancySymbol): use class StringSymbol * fixUp.cc (fixUpSymbols): use StringSymbol* * mixfixParser.cc (makeTerm): use StringSymbol* 2000-04-24 Steven Eker * token.cc (ropeToString): alway generate 3 octal digits for numeric escape codes (codeToRope): only look at max 3 octal digits afer \; don't use strtol() * entry.cc (addOpDeclaration): clear any axioms flags if we fail to create a fancy symbol * mixfixModule.hh (class MixfixModule): added AXIOMS to enum SymbolFlags * fixUp.cc (fixUpSymbols): use dynamic_cast() since there is no guarentee that our symbol is not a FreeSymbol (due to an earlier error); this fixes a nasty bug. * autoWrapBuffer.cc (AutoWrapBuffer): initialize seenBackSlash and inString (overflow): update seenBackSlash and inString; only treat space, ",", [, (, and { as special if !inString (resetCursor): clear seenBackQuote, seenBackSlash and inString (overflow): return EOF if our arg is EOF * autoWrapBuffer.hh (class AutoWrapBuffer): added data members seenBackSlash and inString; seenBackQuote made a Bool 2000-04-19 Steven Eker * mixfixModule.cc (findMachineIntegerSymbol): moved here; no longer inline (findQuotedIdentifierSymbol): moved here; no longer inline * bufferPrint.cc (prettyPrint): use machineIntegerSymbols instead of machineIntegerComponents and quotedIdentifierSymbols instead of quotedIdentifierComponents; use new interface to overloadedQuotedIdentifiers * prettyPrint.cc (prettyPrint): (both versions) use machineIntegerSymbols instead of machineIntegerComponents and quotedIdentifierSymbols instead of quotedIdentifierComponents; use new interface to overloadedQuotedIdentifiers * entry.cc (addOpDeclaration): use new machineIntegerSymbols def * mixfixModule.hh (class MixfixModule): quotedIdentifierSymbols and machineIntegerSymbols become map<>s; overloadedQuotedIdentifiers becomes a set<>; machineIntegerComponents and quotedIdentifierComponents deleted (findMachineIntegerSymbol): rewritten using new machineIntegerSymbols def; made const; made arg const ptr (findQuotedIdentifierSymbol): rewritten using new machineIntegerSymbols def; made const; made arg const ptr * bufferPrint.cc (prettyPrint): handle strings and pseudo strings * prettyPrint.cc (prettyPrint): (Term* version) added code for string case (prettyPrint): (DagNode* version) use new ropeToString() interface * token.hh (class Token): updated decl for ropeToString() * token.cc (ropeToString): now built result in string arg for efficiency 2000-04-18 Steven Eker * prettyPrint.cc (prettyPrint): use stringSymbols.size() rather than stringComponents.cardinality * entry.cc (addOpDeclaration): fill out stringSymbols rather than stringComponents * mixfixModule.hh (class MixfixModule): added stringSymbols, commented out stringComponents; * prettyPrint.cc (prettyPrint): (DagNode* version) do string and pseudo-string disambiguation * entry.cc (addOpDeclaration): fill in overloadedStrings; set PSEUDO_STRING flag if needed (addOpDeclaration): add entry to stringComponents when needed * mixfixModule.hh (class MixfixModule): added data members overloadedStrings and stringComponents * token.cc (codeToRope): handle \t and \b (ropeToString): handle \t and \b (ropeToString): cast unprintable chars to to make sure we don't get negative numbers when converting to octal; only generate needed number of octal digits. (ropeToString): now "\0" is handled by default case code * fixUp.cc (fixUpSymbols): fixed bug where we were setting falseterm instead of notFoundTerm * token.cc (codeToRope): initialize seenBackslash 2000-04-17 Steven Eker * prettyPrint.cc (prettyPrint): use Token::ropeToString (DagNode* version) * mixfixParser.cc: use Token::codeToRope() * token.cc (codeToRope): added (ropeToString): added * token.hh (class Token): added decls for codeToRope() and ropeToString() * prettyPrint.cc (prettyPrint): fixed bug where we were check flags rather tha iflags for PSEUDO_QUOTED_IDENTIFIER (prettyPrint): crude handling of strings (DagNode* version) * mixfixParser.cc (makeTerm): added MAKE_STRING case * mixfixModule.hh (class MixfixModule): added MAKE_STRING to enum Actions * mixfixModule.cc (makeSpecialProductions): added production for new "anonymous string" ("[ STRING ]") token (makeSymbolProductions): added productions for string base symbol(s) * mixfixModule.hh (class MixfixModule): added STRING_NT to enum NonTerminal * mixfixModule.cc (makeSpecialProductions): add special productions for identifiers that look like strings * lexer.flex: recognize string tokens properly * token.cc (prefixNameCode): don't process single tokens that are STRINGS * lexer.flex: fixed stringCont def so that we can have spaces in strings * token.cc (extractMixfix): don't try to extract mixfix syntax for tokens with special properties * token.hh (class Token): added STRING to enum SpecialProperties * token.cc (checkForSpecialProperty): added recognition for strings 2000-04-14 Steven Eker * importModule.cc (fixUpDonatedOps): handle StringOpSymbol * fixUp.cc (fixUpSymbols): handle StringOpSymbol 2000-04-12 Steven Eker * ops.cc (addHook): recognize StringSymbol and StringOpSymbol hooks * entry.cc (newFancySymbol): handle STRING and STRING_OP flags * lexer.flex: STRING -> STRING_TOK * top.y: STRING -> STRING_TOK * entry.cc (addOpDeclaration): use iflags thoughout (addPolymorph): clear iflags * mixfixModule.cc (instantiateSortTest): set iflags (copyPolymorph): copy iflags (computePrecAndGather): use iflags thoughout * bufferPrint.cc (prettyPrint): use iflags thoughout * prettyPrint.cc (prettyPrint): (both versions) use iflags thoughout * mixfixModule.hh (class MixfixModule): added enum InternalFlags to take LEFT_BARE, RIGHT_BARE, ADHOC_OVERLOADED, DOMAIN_OVERLOADED, RANGE_OVERLOADED, PSEUDO_MACHINE_INTEGER, PSEUDO_QUOTED_IDENTIFIER; removed these from enum SymbolFlags; renumbered both enums (class MixfixModule): META_LEVEL_OP deleted (class MixfixModule): added PSEUDO_STRING to InternalFlags (class MixfixModule): added STRING and STRING_OP to SymbolFlags (class MixfixModule): rearranged SymbolInfo and added iflags ===================================Maude 1.0.5 finished======================================= 2000-04-05 Steven Eker * main.cc (findFile): look for .fm extension * interact.cc: sunos 4 ifdef 2000-03-30 Steven Eker * mixfixParser.cc (parseCommand): ifdef'd (makeCommand): ifdef'd 2000-03-29 Steven Eker * prettyPrint.cc (graphPrint): fixed delete bug (need to use delete[] for BigNum strings) 2000-03-21 Steven Eker * autoWrapBuffer.cc (sync): don't output pending buffer unless it consists of a single space or tab; this avoids outputing stuff where it turns out we don't have a save point to line break later on. the drawback is that we violate the semnatics of sync() somewhat * fileTable.cc (printLineNumber): fixed bug where we were using "cout" rather than "s" 2000-03-20 Steven Eker * process.cc (process): check for bad module before calling closeSignature() * entry.cc (addOpDeclaration): now call markAsBad() when ther is a clash of symbol attributes; there is a problem that translating of terms assumes that FooSymbol maps to a FooSymbol; bad things happen if this is violated so we don't want to translate terms 2000-03-17 Steven Eker * search.cc (search): if def'd guts 2000-03-16 Steven Eker * process.cc (process): added extra check for bad module before calling closeFixUps() just incase we had a bad identity * metaDown.cc (downFixUpBubble): WarningCheck() -> IssueWarning() (downAttr): WarningCheck() -> IssueWarning() * execute.cc (cont): standardized IssueWarning() * command.cc (selectModule): standardized IssueWarning()s * ops.cc (addVarDecl): standardized IssueWarning() (setPrec): standardized IssueWarning() (setGather): standardized IssueWarning() * process.cc (processSorts): standardized IssueWarning() and WarningCheck() (getSort): standardized IssueWarning() * import.cc (findModule): standardized IssueWarning() (importModule): standardized IssueWarning()s * compiler.cc (fullCompile): standardized IssueAdvisory() (makeExecutable): standardized IssueWarning() * preModule.cc (getFlatSignature): standardized IssueAdvisory() (finishModule): standardized IssueAdvisory() * mixfixParser.cc (parseTerm): standardized IssueWarning() (parseSentence): standardized IssueWarning() * entry.cc (addOpDeclaration): standardized IssueWarning()s * metaDown.cc (downFixUpBubble): standardized IssueAdvisory() (downSorts): standardized IssueAdvisory() (downSimpleSort): standardized IssueAdvisory() (downTerm): standardized IssueAdvisory()s (downVariable): standardized IssueAdvisory() * metaFastUp.cc (fastUpSort): standardized IssueAdvisory() * main.cc (main): standardized IssueWarning() * lexerAux.cc (handleEof): pass lineNr arg to includeFile() * main.cc (main): pass lineNr arg to includeFile() * top.y: pass lineNr arg to includeFile() * lexerAux.hh (eatComment): updated decl for includeFile() * lexerAux.cc (includeFile): take lineNr arg; standardized IssueWarning()s * importTranslation.hh (class ImportTranslation): use NO_COPYING() macro * fileTable.hh (class FileTable): use NO_COPYING() macro * metaDown.cc (downFixUps): check that identity is in the correct component * mixfixModule.cc (~MixfixModule): only self destrcut special terms that actually exist * fixUp.cc (fixUpSymbols): extensive use of FIX_UP_FAILED macro in an attempt to make specials slightly more robust * preModule.cc (PreModule): init isCompiled * ops.cc (makeOpDeclsConsistent): fixed bug where we were trying to delete op decls beyond start be vector * execute.cc (match): print maxNrSolutions if != UNBOUNDED * preModule.hh (Parent): added decl for printMatchTiming() * execute.cc (printMatchTiming): added * preModule.hh (Parent): added decl for printStats(), updated decl for printTiming(), deleted decl for printTiming2() * compiler.cc (creduce): use printTiming() rather than printTiming2() * execute.cc (beginRewriting): always set timers as showStats and showTiming flags could be changed during rewriting (doLoop): always set timers as showStats and showTiming flags could be changed during rewriting (match): reorganized; call printMatchTiming(); (printStats): adapted from old printTiming() (printTiming2): renamed to printTiming() (endRewriting): use printStats() (doLoop): use printStats() 2000-03-15 Steven Eker * importModule.cc (fixUpDonatedOps): use copyFixUpBubbleSpec() * mixfixModule.hh (class MixfixModule): added decls for findBubbleSpec(), copyFixUpBubbleSpec(), copyBubbleSpec() * mixfixModule.cc (findBubbleSpec): added (copyFixUpBubbleSpec): added (copyBubbleSpec): added * importModule.cc (donateOps): use copyBubbleSpec() * mixfixParser.cc (parseTerm): don't print term in "no parse for term" message (original code didn't work anyway because end was usually DEFAULT = -1) * preModule.hh (Parent): added decl for contLoop2() * execute.cc (loop): copy sucesfully parsed subject to savedLoopSubject (contLoop2): added (contLoop): rewritten using contLoop2() and savedLoopSubject * preModule.hh (Parent): added static data member savedLoopSubject * importTranslation.cc (translate): init importerVersion = 0; use flags rather than dynamic_cast<>s * metaFastUp.cc (fastUpSort): HACK to try and find non error sort to up in union sort case; fixes Delias problem 2000-03-14 Steven Eker * main.cc (findPrelude): handle case where executableName contains a full path name * fileTable.hh (class FileTable): added AUTOMATIC to enum SpecialLineNumbers * main.cc (findPrelude): output FileTable::AUTOMATIC as line number of warning * top.y: save line number for findFile() before calling eatComment() (both places) * main.hh: updated findFile() decl * top.y: pass lineNumber to findFile() (both places) * lexerAux.cc (handleEof): pass COMMAND_LINE to findFile() * main.cc (findFile): take line number argument * fileTable.cc (printLineNumber): handle COMMAND_LINE * fileTable.hh (class FileTable): added COMMAND_LINE to enum SpecialLineNumbers * quotedIdentifierOpSymbol.cc (eqRewrite): simplified using C++ strings rather than C strings * token.cc (dotNameCode): simplified using C++ strings rather than C strings * metaFastUp.cc (fastUpTerm): (both versions) simplified using quoteNameCode() * bufferPrint.cc (prettyPrint): use quoteNameCode() * token.hh (class Token): added decl for quoteNameCode() * token.cc (quoteNameCode): added * bufferPrint.cc (prettyPrint): simplified using C++ strings rather than C strings * mixfixModule.cc (instantiateSortTest): simplified using C++ strings rather than C strings * directoryManager.cc (realPath): code cleaning (realPath): get find(value, stratIndex) args around the right way 2000-03-13 Steven Eker * directoryManager.hh (class DirectoryManager): deleted static data member buffer (class DirectoryManager): updated decls for cd() and pushd() * directoryManager.cc (cd): take C++ string (pushd): take C++ string (initialize): use local buffer * top.y: use realPath() for "cd" and "pushd" commands * lexerAux.cc (includeFile): rewritten (handleEof): rewritten * top.y: rewrite "in" and "load" commands in terms of new findFile() and includeFile() * main.cc (findPrelude): rewritten (main): use new findPrelude() and includeFile() conventions * main.hh: added decl for findPrelude() and findFile() * main.cc (findPath): deleted (findFile): rewritten * directoryManager.cc (checkAccess): added hack to deal with missing compare() functions in GNU C++ stdlib * directoryManager.hh (class DirectoryManager): updated decl for realPath(), added decl for checkAccess() and searchPath() * directoryManager.cc (realPath): completely rewritten using C++ strings (checkAccess): added (searchPath): added 2000-03-07 Steven Eker * main.hh: added decl for findFile() * main.cc (findFile): added * execute.cc: change init value for counters to 0us; this might avoid the strange results we see on linux 2000-03-06 Steven Eker * metaDown.cc (downModule): call closeFixUps() * process.cc (process): call closeFixUps() * mixfixParser.cc (makeStatement): fixed bug where we weren't setting line number for conditional equations * execute.cc (beginRewriting): call clearMemo() if autoClearMemo (endRewriting): no longer call clearMemo() * commands.y: call setAutoClearMemo() * preModule.hh (Parent): added static data member autoClearMemo (setAutoClearMemo): added (Parent): added decl for setAutoClearMemo() * execute.cc (endRewriting): call clearMemo() if autoClearMemo flag set (endRewriting): call clearMemo() if autoClearMemo flag set * command.cc (loseFocus): call clearMemo(); 2000-03-03 Steven Eker * mixfixModule.hh (class MixfixModule): added decl for newFancySymbol() * entry.cc (newFancySymbol): added (addOpDeclaration): greatly simplified using newFancySymbol * main.cc (main): deleted old auto wrap code * interact.cc (displayPrompt): call resetCursor(); * mixfix.hh: added class AutoWrapBuffer * userLevelRewritingContext.hh (class UserLevelRewritingContext): added decls for setAutoWrap() and static data members wrapOut and wrapErr * main.cc (main): call setAutoWrap() * interact.cc (setAutoWrap): added * autoWrapBuffer.cc (resetCursor): added * autoWrapBuffer.hh (class AutoWrapBuffer): added decl for resetCursor(); * metaModuleCache.cc (insert): don't economize former LRU module after all; the fragmentation from constantly regenerating parsers seems to be worse than keeping old parsers around (moveToFront): don't economize former LRU module after all * mixfixModule.cc (makeBubbleProductions): fix bubble bug: don't modify original excludedTokens; instead use temporary vector; this is because we need the original values if we have to rebuild the parser, or if we ever allow bubbles to be imported 2000-03-02 Steven Eker * userLevelRewritingContext.hh (class UserLevelRewritingContext): use NO_COPYING() macro * quotedIdentifierOpSymbol.hh (class QuotedIdentifierOpSymbol): use NO_COPYING() macro * quotedIdentifierTerm.hh (class QuotedIdentifierTerm): use NO_COPYING() macro * quotedIdentifierDagNode.hh (class QuotedIdentifierDagNode): use NO_COPYING() macro * metaModule.hh (class MetaModule): use NO_COPYING() macro * metaLevelOpSymbol.hh (class MetaLevelOpSymbol): use NO_COPYING() macro * loopSymbol.hh (class LoopSymbol): use NO_COPYING() macro * metaLevel.hh (class MetaLevel): use NO_COPYING() macro * autoWrapBuffer.hh (class AutoWrapBuffer): use NO_COPYING() macro * lexerAux.cc (handleEof): read pending files in silent mode * fileTable.cc (FileTable): added in order to initialize firstSilent * userLevelRewritingContext.hh (class UserLevelRewritingContext): deleted decl for beginModule() * interact.cc (beginModule): deleted * modules.y: don't call UserLevelRewritingContext::beginModule() (2 places) * fileTable.cc (beginModule): print module name & line of =s here if we are inside an in'd file and no in silent mode * lexerAux.cc: deleted firstSilent global variable (cleanUpLexer): don't use firstSilent (includeFile): don't use firstSilent or call UserLevelRewritingContext::setSilentFlag(true); pass silent arg to openFile() (handleEof): don't use firstSilent or call UserLevelRewritingContext::setSilentFlag(true) (cleanUpLexer): don't call UserLevelRewritingContext::setSilentFlag(false) * fileTable.hh (class FileTable): added data member firstSilent (class FileTable): updated decl for openFile() * fileTable.cc (openFile): take silent argument; set firstSilent if neccessary; don't print "Reading..." message if in silent mode (closeFile): don't print "Done..." message if in silent mode; set firstSilent to NONE if we just close the first silent file (abortEverything): set firstSilent to NONE if we had files to close * userLevelRewritingContext.hh (class UserLevelRewritingContext): deleted static data member silentFlag (setSilentFlag): deleted (class UserLevelRewritingContext): deleted decl for setSilentFlag() * interact.cc: deleted silentFlag (beginModule): don't check silentFlag 2000-03-01 Steven Eker * top.y: added load directive * modules.y: added KW_LOAD to startKeyword * top.y: added decl for KW_LOAD * lexer.flex: added KW_LOAD * lexerAux.cc (handleEof): update use of includeFile() * main.cc (main): update decl and use for includeFile() * lexerAux.hh: update decl of includeFile() * top.y: update decl and use for includeFile() * lexerAux.cc: added global variable firstSilent() (cleanUpLexer): set firstSilent = NONE; (includeFile): take silent arg and call setSilentFlag() and set firstSilent when neccessary (handleEof): handle firstSilent * compiler.cc (makeBaseName): nasty hack because string streams are not yet supported in GNU libstdc++ * quotedIdentifierOpSymbol.cc (eqRewrite): replace sprintf() with ostrstream; should use ostringstream * interact.cc (commandLoop): use new makeBaseName() result * preModule.cc (regretToInform): use new makeBaseName() result * compiler.cc (fullCompile): use new makeBaseName() result (outputGraph): use new makeBaseName() result (inputGraph): use new makeBaseName() result (creduce): use new makeBaseName() result * preModule.hh (Parent): updated decl for makeBaseName() * compiler.cc (makeBaseName): rewritten using C++ strings and string streams * top.y: simplify "ls" command code using C++ strings * lexer.flex: use yyless() in STRING_MODE so that line number will be correct in null string case * top.y: added token decl for KW_LATEX * modules.y: added KW_LATEX to attrKeyword * lexer.flex: added KW_LATEX * modules.y: removed NUMBER_TOK from alternatives for token and tokenBarDot since these should never be generated while lexer in ID_MODE and token/tokenBarDot are never used outside of ID_MODE; Added syntax for latex attribute 2000-02-29 Steven Eker * importModule.hh (class ImportModule): use NO_COPYING() macro * mixfixModule.hh (class MixfixModule): use NO_COPYING() macro * metaModuleCache.cc (moveToFront): economize former LRU module (insert): economize former LRU module * metaModuleCache.hh (Parent): use NO_COPYING() macro * mixfixModule.hh (getGather): rewritten using revertGather(), made inline and moved here (class MixfixModule): updated decl for getGather() * importModule.cc (donateOps): use new getGather() interface * entry.cc (addPolymorph): print line number in new prec/gather warnings (addOpDeclaration): print line number in new prec/gather warnings * mixfixModule.cc (revertGather): added (copyPolymorph): use revertGather(); set symbolInfo.next = NONE * mixfixModule.hh (class MixfixModule): added decl for revertGather() 2000-02-28 Steven Eker * entry.cc (addPolymorph): set symbolInfo.next = NONE * mixfixModule.cc (copyPolymorph): do a deep copy of SymbolInfo rather than copying members * entry.cc (addPolymorph): if PREC or GATHER flags are set for an operator without mixfix syntax, give a warning and clear them * command.cc (parse): fixed memory leak by deleting parsed term * entry.cc (addOpDeclaration): if PREC or GATHER flags are set for an operator without mixfix syntax, give a warning and clear them 2000-02-25 Steven Eker * preModule.hh (Parent): updated decl for printBubble() * execute.cc (printBubble): fixed bug where we weren't passing Vector arg by ref ===================================Engine56================================================== 2000-02-24 Steven Eker * interact.cc (commandLoop): added hack to unlink executable whether or not we made one; rely on OS for now... * compiler.cc (makeExecutable): rewritten using isCompiled flag * preModule.cc (regretToInform): clear isCompiled and unlink executable if it is set * preModule.hh (Parent): added data member isCompiled * compiler.cc (makeExecutable): now return bool to say whether we succeeded (creduce): don't both trying to run executable if makeExecutable() return false (fullCompile): unlink gernrated .hh and .cc files (inputGraph): unlink .in and .out files * preModule.hh (Parent): updated decls for fullCompile() and makeExecutable() * compiler.cc (fullCompile): added code to generate inFileName and outFileName (outputGraph): more here; use makeBaseName() (depthFirstTraversal): moved here (inputGraph): more here; use makeBaseName() (fullCompile): now return bool to say whether we succeeded * preModule.cc (generateEval): deleted * compiler.cc (makeBaseName): added (fullCompile): use makeBaseName() (creduce): use makeBaseName() * preModule.hh (Parent): added decl for makeBaseName() 2000-02-23 Steven Eker * compiler.cc (creduce): use printTiming2() (fullCompile): use STL string class to build compilation command by looking at environment * preModule.hh (Parent): updated decl for inputGraph() * preModule.cc (inputGraph): pass back cpu and real time as microseconds in 64bit ints * compiler.cc (creduce): rewritten using makeDag() and makeExecutable() * preModule.hh (Parent): added decl for printTiming2(), updated decl for printTiming(), added decl for makeExecutable() * execute.cc (printTiming2): added (printTiming): rewritten using printTiming2() and using 64bit ints to hold number of microseconds rather than 32bit ints to hold number of milliseconds (printTiming): take number of rewrites rather than context (doLoop): use new printTiming() convention (endRewriting): use new printTiming() convention * compiler.cc (makeExecutable): added * execute.cc (match): completely rewritten; much simplified; now call protect() and unprotect() since computeTrueSort() and solve() may do rewriting, which if we were incredibly unlucky could end up in the debugger, allowing the user to to enter a module that invalidates the module we are matching in (printTiming): result and result2 no longer static 2000-02-22 Steven Eker * execute.cc (match): moved here (match): use makeDag() to preprocess subject * compiler.cc (creduce): moved here * preModule.hh (Parent): deleted members importSymbol, importPolymorphIndex and importOriginator from struct OpDecl (Parent): NO_DEFAULTS() -> NO_COPYING() * metaLevelOpSymbol.cc (metaReduce): call protect() and unprotect() (metaRewrite): call protect() and unprotect() (metaApply): call protect() and unprotect() * metaLevel.hh (class MetaLevel): updated decl for downModule() * metaDown.cc (downModule): return ImportModule* rather than MixfixModule* * execute.cc (doLoop): call protect() and unportect() (loop): pass module arg to doLoop() (contLoop): pass module arg to doLoop() (printTiming): decl for result and result2 moved here * importModule.cc (unprotect): return true if unprotect() call results in the module being deleted (ImportModule): initialize protectCount to 0 * preModule.hh (Parent): updated decl for beginRewriting() and endRewriting() * execute.cc (endRewriting): take module arg; call unprotect(); clear saved if we had a traceAbort, or unprotect() deleted module (beginRewriting): call protect() (reduce): pass module arg to beginRewriting() and endRewriting() (rewrite): pass module arg to beginRewriting() and endRewriting() (cont): pass module arg to beginRewriting() and endRewriting() * metaDown.cc (downModule): call localStatementsComplete() * importModule.hh (class ImportModule): added decls for protect() and unprotect() * importModule.cc (unprotect): added (deepSelfDestruct): if we have a > 0 protectCount, mark as DOOMED, rather than doing the delete * importModule.hh (class ImportModule): added data member protect count (protect): added 2000-02-21 Steven Eker * commands.y: added set show loop timing and set show loop stats commands * preModule.hh (setShowLoopTiming): added (setShowLoopStats): added (Parent): added decls for setShowLoopTiming() and setShowLoopStats() 2000-02-18 Steven Eker * preModule.hh (Parent): added decl for printTiming() * execute.cc (printTiming): added; use all integer arithmetic for more stable results (endRewriting): use printTiming() (doLoop): use printTiming() * preModule.hh (Parent): added decl for doLoop(); added static data members showLoopStats and showLoopTiming * execute.cc (endLoop): added (contLoop): simplified using endLoop() (loop): simplified using endLoop() (endLoop): use dynamic_cast to figure out if we have a LoopSymbol since out flat module is no longer reliable (if it got replaced during debug) (contLoop): rewritten, use dynamic_cast to figure out if we have a LoopSymbol (startLoop): added (contLoop): simplified using startLoop() (loop): simplified using startLoop() (doLoop): replaces startLoop() and endLoop() (loop): use doLoop() (contLoop): use doLoop() * preModule.hh (Parent): added decls for beginRewriting(), endRewriting() and makeDag() * execute.cc (beginRewriting): added (endRewriting): added (reduce): moved here, rewritten using beginRewriting() and endRewriting() (rewrite): moved here, rewritten using beginRewriting() and endRewriting() (cont): moved here, rewritten using beginRewriting() and endRewriting() (makeDag): added (reduce): simplified using makeDag() (cont): simplified (rewrite): simplified using makeDag() (loop): simplified using makeDag() * importModule.cc (donateStatements): put line numbers into statement copies 2000-02-17 Steven Eker * lexer.flex: added keywords ctor = constructor * top.y: added decl for KW_CTOR * modules.y: added KW_CTOR * metaLevelSignature.cc (MACRO): added macro for ctorSymbol * metaDown.cc (downAttr): ignore ctorSymbol in attribute list * prelude.maude: added ctor constant to META-LEVEL * metaLevelOpSymbol.cc (metaParse): fixed memory leak by calling deepSelfDestruct() on term obtained from parsing * command.cc (loseFocus): moved here (loseFocus): clear saved to fix contLoop bug (selectModule): no need to clear saved here now (loseFocus): call reset() on flatModule (creduce): don't call reset() (reduce): don't call reset() (rewrite): don't call reset() (cont): don't call reset() (loop): don't call reset() (contLoop): don't call reset() (rewrite): fixed memory leak by calling deepSelfDestruct() on subject term (loop): fixed memory leak by calling deepSelfDestruct() on subject term * preModule.hh (Parent): regretToInform() decl made private (Parent): use NO_DEFAULTS() macro * metaModuleCache.hh (Parent): derivation has to be public * metaDown.cc (downModule): pass cache as parent * metaModule.cc (MetaModule): pass parent arg to ImportModule * metaModule.hh (class MetaModule): added parent arg to ctor * metaModuleCache.hh (Parent): added decls for Pair::clear() and regretToInform() * metaModuleCache.cc (clear): added (regretToInform): added (flush): use clear() (insert): use clear() * metaModuleCache.hh (Parent): have private base ImportModule::Parent (Parent): added decl for regretToInform() * preModule.hh (Parent): updated decl for regretToInform() * preModule.cc (regretToInform): use doomedModule arg * importModule.cc (deepSelfDestruct): have regretToInform() pass back pointer to doomed module for the beefit of parents that have multiple children * preModule.hh (loseFocus): use economize() * mixfixModule.hh (class MixfixModule): changed loseFocus() decl to economize() * mixfixModule.cc (loseFocus): renamed to economize() * metaModuleCache.cc (insert): added DebugAdvisoryCheck() 2000-02-16 Steven Eker * metaDown.cc (downModule): use new cache data member * metaLevel.cc (~MetaLevel): no longer delete cacheModule since this data member has been replaced (MetaLevel): no longer initialize cachedModule (reset): flush the cache; don't reset defunct data members * metaLevel.hh (class MetaLevel): use MetaModuleCache * metaModuleCache.hh: created * metaModuleCache.cc: created * fixUp.cc (fixUpSymbols): moved here (findHookSymbol): moved here (findHook): moved here * process.cc (process): moved here * search.cc (search): call getFlatModule() * preModule.cc (generateEval): use getFlatSignature() (inputGraph): use getFlatSignature() * compiler.cc (fullCompile): don't look at flatModule to get name of module for advisory (fullCompile): use getFlatModule() 2000-02-14 Steven Eker * preModule.cc (PreModule): don't pass type arg to NamedEntity * import.cc (importModule): added call to loseFocus() on imported module to make sure any parser we might have made by importing it is deleted; this is a bit of a hack - need a cleaner method * importModule.cc (removeDependent): added DebugAdvisoryCheck() * import.cc (processImports): use autoImports rather than defaultImports (importModule): added (processImports): use importModule() * preModule.cc (finishModule): set autoImports * preModule.hh (class PreModule): added data member autoImports * preModule.cc (getFlatSignature): use this rather than moduleName (finishModule): use id() rather than moduleName; use this rather than moduleName (process): use id() rather than moduleName * command.cc (showModule): use this rather than moduleName * preModule.cc (PreModule): initialize NamedEntity base * preModule.hh (class PreModule): derive from NamedEntity; deleted data member moduleName * import.cc (processImports): check for null flat module and issue recursive import warning (2 places) * preModule.cc (getFlatSignature): don't return pointer to flatten module that is still being processed; this can only happen because of a recursive import 2000-02-11 Steven Eker * importModule.cc (deepSelfDestruct): no longer use DOOMED state; let a module remove itself from all dependent lists but take this into account when traversing dependent lists * preModule.cc (process): need to pass pointer to us to ImportModule ctor! * preModule.hh (loseFocus): check to be sure flatModule != 0 * preModule.cc (process): call localStatementsComplete() * importModule.hh (class ImportModule): added decl for localStatementsComplete() * importModule.cc (localStatementsComplete): added as a nasty hack to overcome initialization problem (importStatements): no longer set nrOriginal* here * preModule.cc (finishModule): set isCompleteFlag * command.cc (parse): use getFlatSignature() (creduce): use getFlatModule() (reduce): use getFlatModule() (loop): use getFlatModule() (cont): use getFlatModule() (contLoop): use getFlatModule() (selectModule): use getFlatSignature() (match): use getFlatSignature() (showModule): use moduleName and moduleType * preModule.cc (PreModule): clear isCompleteFlag * preModule.hh (class PreModule): added decl for isComplete() (class PreModule): added data member isCompleteFlag (isComplete): added * bottom.y (cleanUpParser): use isComplete() * commands.y: use getFlatSignature() in places where we don't need the statements * metaDown.cc (downImport): use getFlatSignature() * import.cc (processImports): rewritten, using closeSignature() * preModule.cc (PreModule): call deepSelfDestruct() (finishModule): added (process): create ImportModule (process): don't import statements or close theory * preModule.hh (class PreModule): derive from ImportModule::Parent * preModule.cc (getFlatModule): moved here (getFlatSignature): created (PreModule): don't create ImportModule, initialize LineNumber, moduleName and moduleType * preModule.hh (class PreModule): derive from LineNumber (class PreModule): added moduleName and moduleType data members (class PreModule): added decl for getFlatSignature(); getFlatModule() no longer const * symbolTranslation.hh: deleted * symbolTranslation.cc: deleted * metaModule.cc: deleted obsolete imporation code 2000-02-10 Steven Eker * preModule.cc (PreModule): delete init of importPhase * importModule.cc (deepSelfDestruct): status -> importPhase * importModule.hh (class ImportModule): DOOMED moved from enum Status to enum Phase; enum Status deleted (class ImportModule): data member status deleted * preModule.hh (class PreModule): deleted tons of old import decls * preModule.cc: deleted old versions of process() and nativeCompile() * import.cc: deleted tons of old import code * metaModule.hh (addImport): deleted * metaDown.cc (downImport): use new importation conventions * preModule.hh (getFlatModule): return ImportModule* (class PreModule): updated decl for getFlatModule() * metaDown.cc (downModule): use new importation conventions * metaModule.cc (MetaModule): init ImportModule * metaModule.hh (class MetaModule): derive from ImportModule; delete out all importation decls; all import functionality purged from file 2000-02-09 Steven Eker * mixfixModule.cc (getGather): move here; now do conversion from internal rep to interface rep * importTranslation.cc (translate): handle sort test symbols * mixfixModule.cc (copyPolymorph): must translate sorts! 2000-02-08 Steven Eker * importTranslation.cc (translate): treat variables specially since we know they will be invisible in importer (translate): fixed bug in domain component traslation * mixfixModule.hh (class MixfixModule): added decl for findInvisibleVariable() * mixfixModule.cc (findInvisibleVariable): added * entry.cc (addOpDeclaration): add invisible symbols to linked list just like normal symbols; don't check for overloading between an invisible symbol an any other symbol * importModule.cc (donateOps): make imported variables invisible * process.cc (processOps): commented out what appears to be a sperfluous call to setLineNumber() * importModule.cc (donateOps): fixed no common ancestor warning bug for ops with > 1 decl (donateOps): set prec correctly * import.cc (processImports): rewritten to use ImportModule * importModule.cc (importStatements): set nrOriginalMembershipAxioms, nrOriginalEquations and nrOriginalRules * importModule.hh (class ImportModule): added decls for resetImports() and resetImportPhase() * importModule.cc (resetImports): added (resetImportPhase): added * preModule.cc (PreModule): use ImportModule (process): rewritten using ImportModule * mixfix.hh: added class ImportModule and class ImportTranslation * importModule.hh (class ImportModule): added decl for addImport() * importModule.cc (fixUpDonatedOps): handle polymorphs (addImport): added * importModule.hh (class ImportModule): added data members nrImportedPolymorphs and firstPolymorphCopy * importModule.cc (donateOps): handle polymorphs 2000-02-07 Steven Eker * mixfixModule.hh (class MixfixModule): added decls for copyPolymorph(), getNrPolymorphs() (getNrPolymorphs): added * mixfixModule.cc (copyPolymorph): added * mixfix.hh: added forward decl for class LoopSymbol * importModule.hh (class ImportModule): added decls for fixUpImportedOps() and fixUpDonatedOps() * importModule.cc (fixUpImportedOps): added (fixUpDonatedOps): added * mixfixModule.hh (getPrec): added (getGather): added (class MixfixModule): made getFlags() const * importModule.hh (class ImportModule): added decls for importOps() and donateOps(); added data member responsibleForFixUp() * importModule.cc (donateOps): rewritten using nrImportedDecls[] and nrUserDecls[] 2000-02-04 Steven Eker * importModule.cc (donateStatements): added (importStatements): added * importTranslation.cc: created * importTranslation.hh: created * importModule.cc (buildTranslationTable): deleted (insertTranslations): deleted 2000-02-03 Steven Eker * importModule.cc: added DEBUG_ADVISORY() 2000-02-02 Steven Eker * preModule.cc (process): fixed missing & bug which cause us to copy sort vector rather than take a reference * importModule.hh: created * importModule.cc: created 2000-02-01 Steven Eker * lexer.flex: make q a synonym for even inside module * top.y: make quit work correctly inside of module * ops.cc (makeOpDeclsConsistent): handle the no defs, no decls case correctly by doing nothing * lexer.flex: added q as a synonym for quit but only on the in command mode 2000-01-31 Steven Eker * preModule.cc (inputGraph): set sort index of top dag node 2000-01-27 Steven Eker * compiler.cc (fullCompile): call generateSortVector() on each sort ===================================Engine55================================================== 1999-12-20 Steven Eker * compiler.cc (fullCompile): handle compileCount flag * command.cc (creduce): handle compileCount flag * preModule.hh (class PreModule): added decl for setCompileCount() (setCompileCount): moved here * command.cc (setCompileCount): added * lexer.flex: added keywords compile and count * top.y: added tokens for compile and count * commands.y: added set compile count on/off command 1999-12-07 Steven Eker * lexer.flex: recognize "." as a "." in command mode if followed by eather "***" or "---" as well as "\n". this enable us to handle commands with comments on their ends correctly * interact.cc (setHandlers): pass bus errors to segmentation fault handler as a stop gap; don't bother setting up an alternative signal stack since there does seem to be a reliable way to distinguish between stack overflows and normal seg faults 1999-12-06 Steven Eker * trial.cc (traceBeginEqTrial): use dontTrace() (traceBeginRuleTrial): use dontTrace() (traceBeginScTrial): use dontTrace() * preModule.hh (class PreModule): added decl for traceExclude() * command.cc (traceExclude): added * top.y: added nonterminal exlcude and toekn KW_EXCLUDE * commands.y: added syntax for trace exclude/include * userLevelRewritingContext.cc (tracePreEqRewrite): use dontTrace() (tracePreRuleRewrite): use dontTrace() (tracePreScApplication): use dontTrace() (excludeModules): added * userLevelRewritingContext.hh (class UserLevelRewritingContext): added static data member excluded (dontTrace): added (class UserLevelRewritingContext): added decl for dontTrace() 1999-12-03 Steven Eker * metaLevelOpSymbol.cc (reset): check to see that metaLevel != 0 since we can rely on our symbol having been fixed up when we're called (say because of deletion of an incompletely built meta module) (MetaLevelOpSymbol): initialize shareWith amd metaLevel so their in safe states for deletion and reset() 1999-11-08 Steven Eker * preModule.hh (class PreModule): added decl for fullCompiler 1999-11-05 Steven Eker * compiler.cc: created 1999-11-04 Steven Eker * interact.cc (setHandlers): HACK for alpha in !defined(_XOPEN_SOURCE_EXTENDED) case * preModule.cc (nativeCompile): added Alpha case; removed absolute paths from other cases 1999-11-02 Steven Eker * main.cc (findPath): added 1999-11-01 Steven Eker * token.cc (int64ToString): added special case for INT64_MIN to ensure we don't rely on the implementation of % and / on negative 64 bit integers 1999-10-29 Steven Eker * metaDown.cc (downAttr): handle Int64 in prec * metaLevelOpSymbol.cc (metaRewrite): almost do Int64 right (metaApply): almost do Int64 right * quotedIdentifierOpSymbol.cc (eqRewrite): use Token::codeToInt64() (eqRewrite): use int64ToString() * metaFastUp.cc (fastUpTerm): (both versions), use Token::int64ToString() * entry.cc (addOpDeclaration): use Token::codeToInt64() * mixfixModule.hh (class MixfixModule): overloadedMachineIntegers is now a set * bufferPrint.cc (prettyPrint): handle 64 bit machine ints correctly * prettyPrint.cc (prettyPrint): (both versions), handle 64 bit machine ints correctly * token.cc (codeToInt64): added (int64ToString): added * token.hh (class Token): added decls for codeToInt64() and int64ToString() * mixfixParser.cc (makeTerm): use Token::codeToInt64() * metaDown.cc (downMachineIntList): cast Int64 to int before making list * metaLevel.hh (class MetaLevel): updated decl for downMachineInt() * metaDown.cc (downMachineInt): int -> Int64 (downTerm): use Token::codeToInt64() * prettyPrint.cc (printAttributes): use dynamic_cast() before checking for strategy; handle memo (printAttributes): removed dynamic_cast() * main.cc (findPrelude): rindex() -> strrchr() * lexerAux.cc (includeFile): rindex() -> strrchr() * directoryManager.cc (realPath): index() -> strchr() (*2) ===================================Engine53================================================== 1999-10-26 Steven Eker * interact.cc (setHandlers): added code to catch segmentation faults * prettyPrint.cc (showOps): VariableSymbol::dynamicCast() -> dynamic_cast (showVars): VariableSymbol::dynamicCast() -> dynamic_cast (printAttributes): use dynamic_casts()s rather than comparisons on theory strings (printAttributes): use variable decls inside of ifs * entry.cc (addOpDeclaration): updated calls to AU_Symbol, ACU_Symbol and CUI_Symbo to pass memo flags 1999-10-25 Steven Eker * userLevelRewritingContext.cc: take extra argument, handle memo table case * userLevelRewritingContext.hh (class UserLevelRewritingContext): updated decl for tracePreEqRewrite() * quotedIdentifierOpSymbol.cc (eqRewrite): updated 3 calls to tracePreEqRewrite() 1999-10-22 Steven Eker * lexer.flex: recognize memo in INITIAL as well as ID_MODE; recognize do and clear * top.y: added tokens KW_DO KW_CLEAR * commands.y: added do clear memo command added syntax for * entry.cc (addOpDeclaration): support memo for free symbols 1999-10-19 Steven Eker * search.cc (struct hashDagNode): added (search): try using hash_set instead of set (struct dagNodeEq): added (search): try using DagNodeSet instead of hash_set * quotedIdentifierDagNode.cc (getHashValue): added * quotedIdentifierDagNode.hh (class QuotedIdentifierDagNode): added decl for getHashValue() 1999-10-14 Steven Eker * prettyPrint.cc (operator<<): (Term* and DagNode* versions); hack removed * bufferPrint.cc (bufferPrint): hack removed * mixfixModule.cc (loseFocus): no longer inline (closeSignature): added in order to compute pretty print info whether or not we generate a parser (makePolymorphProductions): don't call computePrecAndGather() (makeSymbolProductions): don't call computePrecAndGather() * mixfixModule.hh (class MixfixModule): added decl for closeSignature() * prettyPrint.cc (operator<<): (Term* and DagNode* versions); call makeGrammar() as a HACK to set up gather info ===================================Engine52================================================== 1999-10-07 Steven Eker * top.y: added ADVISE as a token * lexer.flex: added advise keyword * commands.y: added syntax for set show advise on/off 1999-10-06 Steven Eker * bufferPrint.cc (bufferPrint): call makeGrammar() as a HACK to set up gather info 1999-10-04 Steven Eker * banner.cc (printBanner): long -> time_t 1999-09-01 Steven Eker * preModule.cc (nativeCompile): #ifdef'd system args to do the best compile for solaris and linux 1999-08-27 Steven Eker * mixfixModule.cc (makeSymbolProductions): don't add productions for any polymorph instances that happen to exists at this moment * modules.y: call loseFocus() for old module when new module is created * command.cc (selectModule): call loseFocus() for old module * mixfixModule.cc (loseFocus): added * mixfixModule.hh (class MixfixModule): added decl for loseFocus() * preModule.hh (class PreModule): added decl for loseFocus() (loseFocus): added 1999-08-26 Steven Eker * mixfixParser.cc (parseSentence): do makeGrammar() first thing so that tokens will be set up * metaDown.cc (downModule): don't call makeGrammar() * mixfixModule.hh (class MixfixModule): added decl for insertLabels() * preModule.cc (process): call insertLabels() rather than makeGrammar() * mixfixModule.cc (makeGrammar): don't pass labels argument to makeLabelProductions() * mixfixModule.hh (class MixfixModule): makeGrammar() becomes private and loses arg; makeLabelProductions() loses arg; * mixfixModule.cc (makeGrammar): no longer take labels arg (makeLabelProductions): no longer take labels arg * mixfixModule.hh (insertLabels): added (class MixfixModule): added data member labels * mixfixParser.cc (parseSentence): call makeGrammar() if parser is null * mixfixModule.cc (makeGrammar): parser = new Parser (MixfixModule): parser = 0 (~MixfixModule): delete parser * mixfixParser.cc (insertProd): deref parser (parseTerm): deref parser (2 places) (makeCommand): deref parser (5 places) (parseSentence): deref parser (3 places) (makeTerm): deref parser (many places) (makeCondition): deref parser (many places) (makeStatement): deref parser (many places) * mixfixModule.cc (makeBubbleProductions): deref parser * mixfixModule.hh (class MixfixModule): paser data member is now a pointer to a parser 1999-08-10 Steven Eker * metaDown.cc (downEquations): handle to handle AU equation sets * metaLevelSignature.cc (MACRO): equationSetSymbol made just a Symbol so it can either be ACU or AU (for MOS!), removed need comm attribute 1999-08-05 Steven Eker * preModule.hh (class PreModule): added decl for dagNodeLt() * search.cc (search): don't make initial UserLevelRewritingContext automatic; allocate it on the heap like all the others (search): delete all the UserLevelRewritingContexts we create (search): use STL set class template (dagNodeLt): added 1999-08-03 Steven Eker * search.cc (search): delete matching subproblem after we're done with it (search): delete patternAutomaton * top.y: for "in" directive we now have a call to eatComment() to swallow the \n and get the line number correct for the included file 1999-07-28 Steven Eker * metaLevel.hh (class MetaLevel): added decl for ~MetaLevel() * metaLevelOpSymbol.hh (class MetaLevelOpSymbol): added decl for ~MetaLevelOpSymbol() ===================================Engine51================================================== 1999-07-21 Steven Eker * preModule.cc (nativeCompile): make functions generated for pure constructors be inline 1999-07-19 Steven Eker * preModule.hh (class PreModule): updated decl for inputGraph() * command.cc (creduce): print number of rewrites and timing * preModule.cc (inputGraph): read in number of rewrites and timing 1999-07-16 Steven Eker * preModule.cc (nativeCompile): compile and link (nativeCompile): destroy ofstream objects before trying to compile to ensure that they are flushed (nativeCompile): issue advisory before compiling * command.cc (creduce): run executable * preModule.cc (generateEval): generate correct index for storing pointer to evaluated copy after last arg of original 1999-07-15 Steven Eker * preModule.cc (generateEval): get value for #define EVAL correct (nativeCompile): output decl for collectGarbage() 1999-07-14 Steven Eker * preModule.hh (class PreModule): added decl for generateEval() * preModule.cc: added (nativeCompile): call generateEval() 1999-06-29 Steven Eker * preModule.hh (class PreModule): added decl for inputGraph() * preModule.cc (nativeCompile): pass hfile to Symbol::generateCode() (inputGraph): added * command.cc (creduce): call outputGraph() * preModule.hh (class PreModule): added decls for outputGraph() and depthFirstTraversal(); * preModule.cc (outputGraph): added (depthFirstTraversal): added 1999-06-28 Steven Eker * preModule.cc (process): don't call compileToC * preModule.hh (class PreModule): added decls for creduce() and nativeCompile() * preModule.cc (nativeCompile): adapted from compileToC() * command.cc (creduce): added * lexer.flex: added creduce keyword * top.y: declared KW_CREDUCE * commands.y: added syntax for creduce * preModule.cc (compileToC): generate arity table (compileToC): generate forward declarations 1999-06-14 Steven Eker * preModule.hh (class PreModule): added decl for compileToC() * preModule.cc (compileToC): added (process): call compileToC() 1999-06-10 Steven Eker * main.cc: added #include in LINUX case ===================================Engine50================================================== 1999-06-09 Steven Eker * prettyPrint.cc (concealSymbols): added (prettyPrint): (DagNode* version) support print conceal added definitions for printConceal and concealed * mixfixModule.hh (class MixfixModule): added decls for setPrintConceal() and concealSymbols() (class MixfixModule): added static data member concealed (class MixfixModule): added static data member printConceal (setPrintConceal): added * preModule.hh (class PreModule): added decl for printConceal() * command.cc (printConceal): added * top.y: added tokens KW_CONCEAL, KW_REVEAL added type for conceal nonterminal * lexer.flex: added conceal, reveal keywords * commands.y: added syntax for print conceal foo . print reveal foo . set print conceal on/off . ===================================Maude 1.0.3 released======================================= * autoWrapBuffer.cc (sync): handle tabs (breakLine): handle tabs (overflow): handle tabs * autoWrapBuffer.hh (nextTabPosition): added 1999-06-04 Steven Eker * lexer.flex: use %option noyywrap and no longer link with lfl * prettyPrint.cc (graphPrint): handle ^C interrupt * command.cc (showModule): handle ^C interrupt * prettyPrint.cc (showRls): handle ^C interrupt (showEqs): handle ^C interrupt (showVars): handle ^C interrupt (showSorts): handle ^C interrupt (showOps): handle ^C interrupt (showAll): handle ^C interrupt * interact.cc (where): handle ^C interrupt * mixfixModule.hh (class MixfixModule): updated printTails() decl * prettyPrint.cc (prettyPrint): (DagNode*) version added checks for ^C interrupt (5 places) (printTails): added checkForInterrupt arg and ^C interrupt handling * autoWrapBuffer.hh (class AutoWrapBuffer): added decl for ~AutoWrapBuffer() * autoWrapBuffer.cc (~AutoWrapBuffer): added * autoWrapBuffer.hh (class AutoWrapBuffer): deleted decl for flushPending(); updated decl for breakLine() * autoWrapBuffer.cc (flushPending): only set nrPending to UNDEFINED if we actually output something more tha a single space in order to preserve the break point (overflow): delete incorrect test in space case; need to do normal thing even after breakLine() since we may not have been able to break the line and therefore we can afford to lose the space char (sync): don't call flushBuffer() (breakLine): now do cursorPosition check here; return true if we inserted a new line (flushPending): deleted (overflow): don't call flushPending() in \n case 1999-06-03 Steven Eker * main.cc (main): handle case where window width is zero by defaulting to 80 * autoWrapBuffer.cc (breakLine): support left margin (AutoWrapBuffer): support right margin (overflow): get break line test correct (2 places) 1999-06-02 Steven Eker * ops.cc (makeOpDeclsConsistent): added to handle clean up after syntax error. Idea is that after an addOpDecl() we either see a setDomainAndRange() or a statement level error which calls makeOpDeclsConsistent() or both (the setDomainAndRange() can never follow the error). * preModule.hh (class PreModule): added decl for makeOpDeclsConsistent() * modules.y: added call to makeOpDeclsConsistent() in error case 1999-05-28 Steven Eker * quotedIdentifierOpSymbol.hh (class QuotedIdentifierOpSymbol): counter made static * quotedIdentifierOpSymbol.cc (eqRewrite): reset counter here if 'RESET is our arg (reset): don't reset count here (QuotedIdentifierOpSymbol): don't zero counter here 1999-05-27 Steven Eker * quotedIdentifierOpSymbol.hh (class QuotedIdentifierOpSymbol): added MOS ORACLE to enum OpType * quotedIdentifierOpSymbol.cc (reset): clear MOS counter (fixUp): added code for MOS oracles (QuotedIdentifierOpSymbol): clear MOS counter (eqRewrite): added semantics for MOS oracles * quotedIdentifierOpSymbol.hh (class QuotedIdentifierOpSymbol): added MOS counter 1999-05-26 Steven Eker * autoWrapBuffer.cc (sync): rewritten (breakLine): added (flushPending): added (overflow): rewritten (flushPending): added 1999-05-25 Steven Eker * autoWrapBuffer.cc (xsputn): added (xsputn): rewritten for first approc at newline inserting 1999-05-20 Steven Eker * autoWrapBuffer.hh: created * autoWrapBuffer.cc: created 1999-05-19 Steven Eker * search.cc (search): print timing and number of states 1999-05-14 Steven Eker * metaDown.cc (downModule): support existingModuleSymbol * metaLevelSignature.cc (MACRO): added existingModuleSymbol * metaLevel.hh (class MetaLevel): updated decls for all functions below: * metaDown.cc (downSorts): MetaModule -> MixfixModule (downSubsort): MetaModule -> MixfixModule (downSubsorts): MetaModule -> MixfixModule (downVarDecls): MetaModule -> MixfixModule (downVarDecl): MetaModule -> MixfixModule (downMembAx): MetaModule -> MixfixModule (downMembAxs): MetaModule -> MixfixModule (downEquations): MetaModule -> MixfixModule (downEquation): MetaModule -> MixfixModule (downRule): MetaModule -> MixfixModule (downRules): MetaModule -> MixfixModule 1999-05-13 Steven Eker * metaLevel.hh (class MetaLevel): updated decl for downModule() * metaDown.cc (downModule): return MixfixModule rather than MetaModule * metaLevelOpSymbol.cc: replaced MetaModule with MixfixModule throughout file * metaLevel.hh (class MetaLevel): updated decl for downTermList() * metaDown.cc (downTermList): MetaModule -> MixfixModule * metaLevel.hh (class MetaLevel): updated decls for downTerm(), downSubstitution(), downAssignment() and downVariable() * metaDown.cc (downTerm): MetaModule -> MixfixModule (downSubstitution): MetaModule -> MixfixModule (downAssignment): MetaModule -> MixfixModule (downVariable): MetaModule -> MixfixModule * metaModule.cc (locateSpecialReps): deleted * metaModule.hh (class MetaModule): deleted data members machineIntegerSymbols, quotedIdentifierSymbols (findMachineIntegerSymbol): deleted (findQuotedIdentifierSymbol): deleted (class MetaModule): deleted decls for findMachineIntegerSymbol(), findQuotedIdentifierSymbol() and locateSpecialReps() * metaDown.cc (downModule): don't call locateSpecialReps() * entry.cc (addOpDeclaration): fill out machineIntegerSymbols and quotedIdentifierSymbols * mixfixModule.hh (class MixfixModule): added data members machineIntegerSymbols and quotedIdentifierSymbols (findMachineIntegerSymbol): added (findQuotedIdentifierSymbol): added (class MixfixModule): added decls for findMachineIntegerSymbol() and findQuotedIdentifierSymbol() * metaLevel.hh (class MetaLevel): updated decls for downSimpleSort(), downSimpleSortList(), downSimpleSortSet(), downSort() * metaDown.cc (downSimpleSort): MetaModule -> MixfixModule (downSimpleSortList): MetaModule -> MixfixModule (downSimpleSortSet): MetaModule -> MixfixModule (downSort): MetaModule -> MixfixModule * metaLevel.hh (class MetaLevel): updated decls for fastUpTerm() (both versions), fastUpSubstitution() and fastUpResultPair() * metaFastUp.cc (fastUpTerm): (DagNode* version) MetaModule -> MixfixModule (fastUpTerm): (Term* version) MetaModule -> MixfixModule (fastUpSubstitution): MetaModule -> MixfixModule (fastUpResultPair): MetaModule -> MixfixModule 1999-05-12 Steven Eker * interact.cc (handleDebug): only call cleanUpLexer() if we weren't interactive; if we do call cleanUpLexer() output a \n to start a new line after the users ^C 1999-05-11 Steven Eker * interact.cc (handleDebug): call cleanUpLexer() after ^C * bufferPrint.cc (prettyPrint): use chooseDisambiguator(); use rangeComponent() rather than getComponent() * prettyPrint.cc (prettyPrint): (Term* version) use chooseDisambiguator() (prettyPrint): (Term* version) use rangeComponent() rather than getComponent() (prettyPrint): (DagNode* version) use chooseDisambiguator() * mixfixModule.hh (class MixfixModule): added decl for chooseDisambiguator() * prettyPrint.cc (chooseDisambiguator): added * entry.cc (addOpDeclaration): use FreeSymbol::newFreeSymbol() (2 places) ===================================Engine49================================================== 1999-04-30 Steven Eker * search.cc (search): rewritten to handle problems of the form search subject => pattern . * mixfixModule.hh (class MixfixModule): added CONDITIONAL_COMMAND to enum Actions (class MixfixModule): added decl for makeCommand() (class MixfixModule): added decl for parseCommand() (class MixfixModule): added decl for makeCommandProductions() * mixfixParser.cc (makeCommand): added * mixfixModule.cc (makeCommandProductions): added (makeGrammar): call makeCommandProductions() * mixfixModule.hh (class MixfixModule): added COMMAND to enum NonTerminal; updated BASE * search.cc (search): don't rely on OneStep::findNextRewrite() to reduce its result 1999-04-29 Steven Eker * search.cc (search): now do naive breadth first search to find all states * preModule.hh (class PreModule): added decl for search() * search.cc: created * top.y: added KW_SEARCH as token * command.cc (search): added * lexer.flex: added search keyword * commands.y: added first approximation at syntax for search command 1999-04-26 Steven Eker * userLevelRewritingContext.cc (tracePreScApplication): changed message to make it more readable 1999-04-22 Steven Eker * preModule.cc (fixUpSymbols): use new QuotedIdentifierOpSymbol::fixUp() * quotedIdentifierOpSymbol.hh (class QuotedIdentifierOpSymbol): added decls for postInterSymbolPass() and reset() * quotedIdentifierOpSymbol.cc (fixUp): handle LESS_THAN case (eqRewrite): handle LESS_THAN case (postInterSymbolPass): added (reset): added (copyFixUp): copy trueTerm and falseTerm (fixUp): handle trueTerm and falseTerm * quotedIdentifierOpSymbol.hh (class QuotedIdentifierOpSymbol): added data members trueTerm and falseTerm (class QuotedIdentifierOpSymbol): updated fixUp decl (class QuotedIdentifierOpSymbol): added LESS_THAN to enum OpType 1999-04-20 Steven Eker * mixfixModule.cc (instantiateSortTest): don't pass boolSort to SortTestSymbol() (instantiatePolymorph): use new EqualitySymbol() conventions (instantiatePolymorph): use new BranchSymbol() conventions * prettyPrint.cc (showOps): remove " : (implemented by C++ code)" case and assert that we alays have declarations * mixfixModule.cc (instantiatePolymorph): call addOpDeclaration() for each polymorph symbol created (instantiateSortTest): call addOpDeclaration() for each sort test symbol created * prettyPrint.cc (operator<<): (DagNode* version) changed convention for calling graphPrint() (showOps): use ComplexSort since some built in ops will get error sorts in their domain and range in the near future * mixfixModule.hh (class MixfixModule): graphPrint() decl no longer static * prettyPrint.cc (prettyPrint): use instance-free version of rangeComponent() * quotedIdentifierDagNode.cc (specialPrint): deleted * quotedIdentifierDagNode.hh (class QuotedIdentifierDagNode): deleted specialPrint() decl * quotedIdentifierTerm.cc (specialPrint): deleted * quotedIdentifierTerm.hh (class QuotedIdentifierTerm): deleted specialPrint() decl * prettyPrint.cc (graphPrint): eliminate use of DagNode::specialPrint() 1999-04-19 Steven Eker * quotedIdentifierOpSymbol.hh (class QuotedIdentifierOpSymbol): added CONVERT to enum OpType * quotedIdentifierOpSymbol.cc (eqRewrite): added semantics for CONVERT (fixUp): added CONVERT case * lexerAux.cc (eatComment): last change should have corrected problem; the bug is now in flex 2.5.3 which is fixed in 2.5.4 1999-04-18 Steven Eker * lexerAux.cc (eatComment): try to handle the EOF in comment case ===================================Engine48================================================== ===================================Maude 1.0.2 released======================================= 1999-03-12 Steven Eker * prettyPrint.cc (prettyPrint): (Term* and DagNode* versions) fixed bug: ` instead of ' for quoted identifier ===================================Maude 1.0.1 released======================================= 1999-03-03 Steven Eker * bufferPrint.cc (prettyPrint): ignore printMixfix flag for SORT_TESTs * prettyPrint.cc (prettyPrint): ignore printMixfix flag for SORT_TESTs (both versions) * metaLevelSignature.cc (MACRO): unmade last change; to difficult to implement with existing meta level structure; wait until new meta level * metaDown.cc: use downQid() on 1st arg * metaLevelSignature.cc (MACRO): added MACRO for existingModuleSymbol * mixfixModule.cc (instantiateSortTest): set gather, no longer RIGHT_BARE, set prefix name correctly (instantiateSortTest): fillout mixfixSyntax 1999-03-02 Steven Eker * bufferPrint.cc (prettyPrint): made symmetric * prettyPrint.cc (prettyPrint): (DagNode* version) use flags local var (prettyPrint): (Term* version) symmetric changes with DagNode* version * entry.cc (addOpDeclaration): only worry about pseudo stuff when nrArgs == 0 * prettyPrint.cc (prettyPrint): (DagNode* version) handle disambiguation of machine integers, pseudo machine integers, quoted identifiers and pseudo quoted identifiers correctly * mixfixModule.hh (class MixfixModule): added PSEUDO_MACHINE_INTEGER and PSEUDO_QUOTED_IDENTIFIER to enum SymbolFlags (class MixfixModule): added data members machineIntegerComponents, quotedIdentifierComponents, overloadedMachineIntegers, overloadedQuotedIdentifiers * entry.cc (addOpDeclaration): fill out machineIntegerComponents and quotedIdentifierComponents; set PSEUDO_MACHINE_INTEGER and PSEUDO_QUOTED_IDENTIFIER flags; fill out overloadedMachineIntegers and overloadedQuotedIdentifiers 1999-02-26 Steven Eker * entry.cc (addOpDeclaration): make underscore warning more informative (addPolymorph): make underscore warning more informative 1999-02-16 Steven Eker * directoryManager.cc (pushd): temporary hack to fix possible compiler bug: we store directoryStack[oldLength - 1] in a local variable (pushd): Actually it's not a compiler bug but a subtle reference bug; added comment in code to this effect ===================================VectorExperiment========================================== 1999-02-09 Steven Eker * mixfixModule.cc (makeComponentProductions): only have parens for non-bubble components (makePolymorphProductions): only put polymorphic ops in non-bubble components 1999-02-05 Steven Eker * main.cc: added template for Vector 1999-02-03 Steven Eker * command.cc (parse): replaced Symbol::parse() with Symbol::fillInSortInfo() (match): replaced Symbol::parse() with Symbol::fillInSortInfo(); deleted Assert() * metaLevelOpSymbol.cc (metaLeastSort): replaced Symbol::parse() with Symbol::fillInSortInfo(); assume that there won't be any component errors in down'd term (metaParse): replaced Symbol::parse() with Symbol::fillInSortInfo() * mixfixParser.cc (parseTerm): replaced Symbol::parse() with Symbol::fillInSortInfo() (2 places) * bufferPrint.cc (prettyPrint): replaced Symbol::parse() with Symbol::fillInSortInfo() * prettyPrint.cc (prettyPrint): replaced Symbol::parse() with Symbol::fillInSortInfo() 1999-01-29 Steven Eker * directoryManager.cc (cd): use realPath() (pushd): use realPath() (realPath): remember to move cursor forward after we copy in a home directory path name (realPath): fix off-by-one error in .. handling loop (realPath): delete null case and resolve empty path to that of the current directory (pushd): optimization for "." to avoid chdir (popd): optimization for the case where the directory doesn't change * directoryManager.hh (class DirectoryManager): added decl for realPath() * directoryManager.cc (realPath): tidied up 1999-01-28 Steven Eker * directoryManager.cc (realPath): added ===================================Engine47================================================== ===================================Maude 1.00 released======================================= 1999-01-22 Steven Eker * import.cc (processImports): added check for us/using importation mode * mixfixModule.hh (class MixfixModule): added decl for ~MixfixModule() * mixfixModule.cc (~MixfixModule): added in order to deepSelfDestruct special terms within polymorphs 1999-01-21 Steven Eker * metaLevelOpSymbol.cc (~MetaLevelOpSymbol): added, to delete metaLevel * metaLevel.cc (reset): clear cachedMetaModule to fix nasty bug where we were keep a dag whose symbols had been deleted; delete cached module as well (~MetaLevel): added, to delete cachedModule; probably not really necessary since metalevel will be reset 2 GCs before it is deleted 1999-01-20 Steven Eker * directoryManager.cc (popd): fixed another bug where we were not using directoryStack * lexerAux.cc (cleanUpLexer): restore directory stack after closing files (includeFile): handle directories in a relative way; keep track of directory stack markers (handleEof): restore directory stack after end of file * top.y: use new pushd() return value * directoryManager.hh (class DirectoryManager): updated decls for pushd() and popd() * directoryManager.cc (popd): fixed off-by-one error (popd): take arg to allow poping to an arbitrary previous context (pushd): now return index to old context on successful pushd and UNDEFINED owise * preModule.cc (process): check for bad module after closing sort set * metaFastUp.cc (fastUpSort): turned ErrorCheck() for union sorts into an IssueAdvisory() * metaDown.cc (downImport): don't import bad modules * command.cc (selectModule): don't allow bad modules to be used * preModule.cc (process): don't call closeTheory() on bad modules (fixUpSymbols): mark module as bad if we couldn't parse an identity * import.cc (processImports): don't allow importation of bad modules 1999-01-19 Steven Eker * preModule.hh (class PreModule): updated decls for addSelected(), parse(), reduce(), rewrite(), loop(), contLoop(), selectModule() and match() * command.cc (addSelected): don't clear opName (parse): don't waste time swapping subject (reduce): don't waste time swapping subject (rewrite): don't waste time swapping subject (loop): don't waste time swapping subject (contLoop): don't clear input (2 places) (selectModule): don't clear moduleExpr (2 places) (match): made patternBubble and subjectBubble const * preModule.hh (class PreModule): updated decls for addImport(), addSortDecl(), addSubsortDecl(), addStatement() and addRule() * preModule.cc (addRule): rule is now const * preModule.hh (class PreModule): updated decls for addOpDecl(), setDomainAndRange(), setIdentity(), addVarDecl(), setGather(), setStrat(), addHook() (addImport): use copy ctor rather than swap on import (addSortDecl): use copy ctor rather than swap on sortDecl (addSubsortDecl): use copy ctor rather than swap on subsortDecl (addStatement): use copy ctor rather than swap on statement * ops.cc (addOpDecl): don't clear opName (setDomainAndRange): copy rather than swap domainAndRange (setIdentity): copy rather than swap identity (addVarDecl): don't clear varDecl (setGather): don't clear gather (2 places) (setStrat): don't clear strategy (2 places) (addHook): don't clear details * bottom.y (cleanUpParser): don't clear bubble, moduleExpr and pattern * commands.y: heavily rewritten to clear bubble & moduleExp before they are used rather than after * top.y (clear): added * modules.y: major rewrite to simplify grammar and clear bubble before it is used rather than relying on function that bubble is passed to clearing it afterwards; introduced new non-terminals domainRangeAttr and idKeyword to factor grammar * metaDown.cc (downSorts): handle redeclaration of a sort gracefully 1999-01-18 Steven Eker * metaDown.cc (downModule): try deleting cached module * metaLevel.hh (class MetaLevel): added decl for downVariable() * metaDown.cc (downVariable): added (downAssignment): simplified using downVariable() (downTerm): simplified using downVariable() (downTerm): check that operator actually exists before we use it (downTerm): reorganized and simplified; now check for existance of constants in appropriate sort 1999-01-17 Steven Eker * metaDown.cc (downSimpleSortSet): fixed non-negated condition bug (downSimpleSortList): fixed non-negated condition bug * entry.cc (addOpDeclaration): removed ErrorCheck()s and added error recovery code for the cases where assoc/com/id/idem ops have domain length != 2 * metaLevelOpSymbol.cc (metaPrettyPrint): return false rather than errorRewrite() if module or term cannot be brought down (metaPrettyPrint): deepSelfDestruct() term after we are finished with it 1999-01-16 Steven Eker * metaLevel.hh (class MetaLevel): added decl for downSimpleSortSet() * metaDown.cc (downSimpleSortSet): added downSimpleSortSet() * metaLevel.hh (class MetaLevel): added decls for downSimpleSortList() and downSimpleSort() * metaDown.cc (downSimpleSort): added (downSubsort): use downSimpleSort() (2 places) (downSimpleSort): issue advisory when can't find a named sort (downSimpleSortList): added (downFixUpBubble): use downSimpleSortList() (downOpDecl): use downSimpleSortList() and downSimpleSort() (downVarDecl): use downSimpleSort() (downMembAx): use downSimpleSort() (downTerm): use downSimpleSort() (2 places) (downSort): use downSimpleSortSet() and downSimpleSort() 1999-01-14 Steven Eker * interact.cc (commandLoop): unmade yesterdays change since we need to display prompt after ^C in most cases (commandLoop): clear ctrlC_Flag after calling cleanUpLexer() * command.cc (match): term ErrorCheck() into Assert() (match): check for ^C interrupts (match): reorganized to ensure that garbage is collected under error conditions (match): call DagNode::okToCollectGarbage() * lexerAux.cc (cleanUpLexer): use setSilentFlag() (handleEof): use setSilentFlag() * main.cc (main): use setSilentFlag() * userLevelRewritingContext.hh (class UserLevelRewritingContext): added static data member silentFlag (setSilentFlag): added * interact.cc: added silentFlag (beginModule): check silentFlag 1999-01-13 Steven Eker * command.cc (reduce): call UserLevelRewritingContext::beginCommand() (rewrite): call UserLevelRewritingContext::beginCommand() (match): call UserLevelRewritingContext::beginCommand() * modules.y: use UserLevelRewritingContext::beginModule() (2 places) * fileTable.cc (beginModule): no longer print ====== and module name here * userLevelRewritingContext.hh (class UserLevelRewritingContext): added decls for beginModule() and beginCommand() * interact.cc (beginModule): added (beginCommand): added * lexerAux.cc (cleanUpLexer): use fileTable.abortEverything() instead of multiple calls to fileTable.closeFile() (cleanUpLexer): rewritten to switch to each active buffer in turn so we can close its file. * fileTable.hh (class FileTable): added decl for abortEverything() * fileTable.cc (abortEverything): added * lexerAux.cc (cleanUpLexer): call IssueAdvisory() before setInteractive() so we get prompt after Advisory * interact.cc (commandLoop): when recovering from a control-C, don't call displayPrompt() since setInteractive() will doe this if needed when called from cleanUpLexer(); ===================================Engine46================================================== 1999-01-11 Steven Eker * mixfixParser.cc (parseSentence): added ifdef HACK so that we can still link to Earley parser to make comparisons * preModule.hh (class PreModule): modules becomes a reference rather than a vector so avoid automatic deletion at exit which causes purify to report spurious memory leaks * preModule.cc (PreModule): use new to initialize PreModule::modules * directoryManager.hh (class DirectoryManager): added decl for initialize() * directoryManager.cc (DirectoryManager): becomes initialize; to avoid a race condition between directoryStack, directoryNames and a static instance of ourself 1999-01-07 Steven Eker * main.cc (main): fixed bug where we were incrementing argv and then usng as if we had not. 1999-01-06 Steven Eker * top.y: added syntax to allow ls to take flags implemented semantics for ls with flags * lexerAux.cc (lexerFileNameMode): use to be lexerInMode() (lexerStringMode): added * lexer.flex: IN_MODE become FILE_NAME_MODE yyFileName becomes yyString added STRING_MODE * top.y (union): yyFileName becomes yyString 1998-12-24 Steven Eker * mixfixParser.cc (parseTerm): use printTokenVector() (parseStatement): tidied error messages (parseSentence): use printTokenVector() * token.hh (class Token): added decl for printTokenVector() * token.cc (printTokenVector): added (operator<<): implemented using printTokenVector() * main.cc (main): added -no-prelude option 1998-12-23 Steven Eker * mixfixParser.cc (parseSentence): added code to show use where first offending token is in the event of a syntax error * import.cc (donateStatements): don't import bad rule, sort constraints or equations 1998-12-22 Steven Eker * token.cc (operator<<): (Vector& version) handle spacing around special chars * bufferPrint.cc (prettyPrint): handle QIDs and MACHINE-INTs * metaFastUp.cc (fastUpQid): use Token::backQuoteSpecials() (fastUpQidSet): use Token::backQuoteSpecials() (2 places) (fastUpQidList): use Token::backQuoteSpecials() (2 places) * metaLevelOpSymbol.cc (metaParse): don't bother with unbackquoting here as it is down in downQid() * metaDown.cc (downQid): do unbackquoting here; use unBackQuoteSpecials() * loopSymbol.cc (extractQid): use unBackQuoteSpecials() * token.hh (unBackQuoteSpecials): created from unBackQuote(); basically its dangerous to strip backquotes from anything except lone special chars * loopSymbol.cc (extractQid): simplified using Token::unBackQuote() (createQidList): greatly simplified using Token::backQuoteSpecials() * token.hh (backQuoteSpecials): added (unBackQuote): added * metaLevelOpSymbol.hh (class MetaLevelOpSymbol): added META_PRETTY_PRINT to enum OpType (class MetaLevelOpSymbol): added decl for metaPrettyPrint() * metaLevelOpSymbol.cc (metaPrettyPrint): added (eqRewrite): added meta-pretty-print case * metaLevel.hh (class MetaLevel): added decl for fastUpQidList() * metaFastUp.cc (fastUpQidList): added * mixfixModule.hh (class MixfixModule): added decls for bufferPrint() and buffer versions of prettyPrint(), printTokens(), printTails() * bufferPrint.cc: created 1998-12-21 Steven Eker * commands.y: don't use moduleExp in select command * top.y: deleted tokens '*', '+', TO and KW_LABEL * modules.y: added KW_LS to startKeyword use endTokens rather than moduleExp in import decl syntax deleted moduleExp nonterminal deleted renamingList and renamingItem non terminals * top.y: added decl for token KW_LS added syntax and symnatics for ls command simplified top level syntax, deleting loop and item nonterminals * lexer.flex: added token for ls deleted old prompt stuff * top.y: check for failure and give warning for cd/pushd/popd directives * token.cc (extractMixfix): fixed nasty bug where we were mishandling ` * top.y: added syntax and symnatics for pushd and popd * directoryManager.cc (cd): greatly simplified, making use of realpath()s ability to resolve relative names. (popd): implemented (pushd): implemented * top.y (union): added const char* yyFileName to parser union added token FILE_NAME added syntax and semantics for cd directive * lexer.flex: IN_MODE now returns file name rather than calling includeFile() - should really be renamed 1998-12-20 Steven Eker * directoryManager.cc (DirectoryManager): use getenv() (cd): implemented using realpath() * lexer.flex: added keywords pwd, pushd, popd, cd * main.hh: added fwd decl for directoryManager * top.y: added token decls for PWD, CD, PUSHD and POPD added syntax and semantics for PWD * modules.y: added PWD, CD, PUSHD and POPD to startKeyword * main.cc: added global directoryManager object * directoryManager.cc: created * directoryManager.hh (class DirectoryManager): created * command.cc (printOpDef): handle assoc, comm, left/right id, idem, strat, memo, prec, gather * mixfixModule.hh (class MixfixModule): deleted MAY_NOT_LEFT_ASSOC and MAY_NOT_RIGHT_ASSOC from enum SymbolFlags (class MixfixModule): updated decls for mayAssoc() and computePrecAndGather() (class MixfixModule): added ATTRIBUTES to enum SymbolFlags * mixfixModule.cc (mayAssoc): now return UNDEFINED if diff components or no sort info (computePrecAndGather): handle special default gathering case in a cleaner more efficient way; and avoid using these special case unless leftmost arg, rightmost arg and range are all in the same component. (computePrecAndGather): take symbol arg (makeSymbolProductions): don't call mayAssoc(); pass symbol to computePrecAndGather() in op case 1998-12-19 Steven Eker * entry.cc (addOpDeclaration): detect and recover from the case where the number of underscores is not equal to the number of arguments (addPolymorph): detect and recover from the case where the number of underscores is not equal to the number of arguments * token.hh (class Token): updated decl for extractMixfix() * token.cc (extractMixfix): now return number of underscores 1998-12-18 Steven Eker * preModule.hh (class PreModule): added decl for printOpDef() * command.cc (showModule): rewritten (printOpDef): added * mixfixModule.hh (getModuleType): added * command.cc (showModule): deleted old stub Fri Dec 18 18:50:43 1998 Steven Eker * preModule.hh (class PreModule): added decl for showModule() Fri Dec 18 18:49:01 1998 Steven Eker * preModule.hh (class PreModule): deleted decl for dump() Fri Dec 18 18:48:08 1998 Steven Eker * command.cc (showModule): added Fri Dec 18 18:46:44 1998 Steven Eker * preModule.cc (dump): deleted Thu Dec 17 15:31:00 1998 Steven Eker * mixfixParser.cc (parseSentence): removed previous cq handling code Thu Dec 17 15:29:09 1998 Steven Eker * mixfixModule.cc (makeStatementProductions): added rule for cq conditional equations Thu Dec 17 15:16:50 1998 Steven Eker * mixfixModule.cc (mayAssoc): put leq() test arround the correct way ===================================Engine45================================================== Wed Dec 16 10:26:10 1998 Steven Eker * mixfixModule.cc (computePrecAndGather): use MAY_NOT_LEFT_ASSOC and MAY_NOT_RIGHT_ASSOC to do a smarter computation of default gathering (makeSymbolProductions): fix bug where we weren't calling computePrecAndGather() for unary symbols * mixfixModule.hh (class MixfixModule): added decl for mayAssoc() * mixfixModule.cc (makeSymbolProductions): call mayAssoc() and set MAY_NOT_LEFT_ASSOC / MAY_NOT_RIGHT_ASSOC as appropriate for mixfix symbols (mayAssoc): added * mixfixModule.hh (class MixfixModule): added MAY_NOT_LEFT_ASSOC and MAY_NOT_RIGHT_ASSOC to enum SymbolFlags * mixfixParser.cc (parseSentence): change cq to ceq just before giving statement to CFG parser * import.cc (donateOps): fixed bug where in a var was declared twice in an imported module we would import it twice since first importing is invisible. * lexerAux.cc (handleEof): need to restore old buffer from stack, even if we're about to read a pending file so that inputFile() has something to stack * lexerAux.hh (eatComment): updated includeFile() decl * main.cc (main): support pending files * lexerAux.cc (handleEof): support pending file idea (includeFile): return a bool to say if we included file ok (cleanUpLexer): avoid reading anymore pending files after we're called * main.cc (main): use setHandlers() * userLevelRewritingContext.hh (class UserLevelRewritingContext): replace decl for initialize() with that for setHandlers() * interact.cc (initialize): now take handleCtrlC flag instead of interactive flag; assume interactive flag is correctly set before entry (initialize): changed to setHandlers() * main.cc (main): handle command line file as an inclusion (main): changed calculation of whether to handle ctrl-C * lexerAux.cc (createRootBuffer): call UserLevelRewritingContext::setInteractive() Tue Dec 15 11:08:08 1998 Steven Eker * lexerAux.hh: includeFile() decl * lexerAux.cc (includeFile): arg is now const char* * main.cc (findPrelude): added (main): use find prelude * mixfixModule.cc (findSymbol): support assoc symbols with args > 2 (i.e. in flattened form) * metaFastUp.cc (fastUpTerm): (Term* version) added hack to handle metaDisambigSymbol for MACHINE_INTEGERs (fastUpTerm): (DagNode* version) added hacks to handle metaDisambigSymbol for MACHINE_INTEGERs and QUOTED_IDENTIFIERs Mon Dec 14 10:27:18 1998 Steven Eker * metaDown.cc (downModule): call locateSpecialReps() (downTerm): rearranged so we look for machine ints and qid first * metaModule.hh (class MetaModule): added decl for locateSpecialReps() * metaModule.cc (locateSpecialReps): added (addComplexSymbol): (non-polymorph version) don't keep track of machine int and quoted identifiers anymore; this is now the job of locateSpecialReps() * metaModule.hh (class MetaModule): data members machineIntegerSymbols and quotedIdentifierSymbols become PointerMaps (findMachineIntegerSymbol): moved here; made inline; rewritten using pointer map (findQuotedIdentifierSymbol): moved here; made inline; rewritten using pointer map Sun Dec 13 16:47:11 1998 Steven Eker * mixfixModule.cc (findSymbol): can't use range component to generate polymorph since at metalevel we won't know this; use domainComponents[1] in BRANCH_SYMBOL case * metaDown.cc (downModule): rewritten to handle imports * metaModule.hh (addImport): added * preModule.hh (class PreModule): made importation functions public; the whole area of module classes needs to be cleaned up when we have the time. * metaModule.cc (importStatements): added (fixUpImportedOps): added (importOps): added (importSorts): added (resetImports): added * metaModule.hh (class MetaModule): added data member importedModules (should really combine common parts of this class with PreModule sometime/somehow) * preModule.hh (class PreModule): added decl for findModule() * import.cc (findModule): added * metaDown.cc (downImports): handle lists of imports (downImport): added * metaLevelSignature.cc (MACRO): added call for includingSymbol (MACRO): added call for importListSymbol * metaLevel.cc (MetaLevel): clear all symbol pointers on creation Fri Dec 11 10:08:33 1998 Steven Eker * preModule.hh (class PreModule): added decl for setInclude() * import.cc (setInclude): added * lexer.flex: deleted BOOL/bool keywords * top.y: deleted decl for KW_BOOL * commands.y: generalize set include BOOL on/off syntax to set include on/off syntax * import.cc (processImports): handle default imports * preModule.hh (class PreModule): added static data member defaultImports * metaLevel.cc (MetaLevel): fixed bug where we setting trueTerm twice rather than setting falseTerm * mixfixModule.cc (createSortTest): deleted * mixfixModule.hh (class MixfixModule): CREATE_SORT_TEST -> MAKE_SORT_TEST in enum Actions (class MixfixModule): deleted decl for * mixfixModule.cc (makeBoolProductions): CREATE_SORT_TEST -> MAKE_SORT_TEST (2 places) * mixfixParser.cc (makeTerm): use instantiateSortTest() rather than createSortTest() (makeTerm): CREATE_SORT_TEST -> MAKE_SORT_TEST * metaDown.cc (downTerm): use instantiateSortTest() rather than createSortTest() * mixfixModule.hh (class MixfixModule): deleted decls for insertPolymorph() and makePolymorph() * mixfixModule.cc (makePolymorph): deleted * mixfixParser.cc (makeTerm): use instantiatePolymorph() instead of makePolymorph() (makeTerm): reorganized the polymorph case code * entry.cc (addOpDeclaration): changed test for different flags so we ignore overloaded flags * import.cc (fixUpDonatedOps): remember to translate sort as well as sort test symbol! * mixfixModule.hh (class MixfixModule): added decl for instantiateSortTest() * entry.cc (addOpDeclaration): added more detailed error meesage for incompatable overloading * mixfixModule.cc (instantiateSortTest): added * import.cc (fixUpDonatedOps): first crude attempt at creating sort test ops that will be needed for importing equations etc (fixUpDonatedOps): pass flags to findSymbol() * main.cc (main): check for multiple files on command line * lexerAux.cc (includeFile): removed yesterdays hack * main.cc (main): use createRootBuffer(); don't access yyin * lexerAux.cc (createRootBuffer): added Thu Dec 10 13:17:41 1998 Steven Eker * lexerAux.cc (includeFile): added hack so that we can call this before calling yylex() * main.cc (main): read in preamble before processing users commands * mixfixModule.hh (class MixfixModule): added decl for instantiatePolymorph() * mixfixModule.cc (instantiatePolymorph): added (findSymbol): handle polymorphs using instantiatePolymorph() * import.cc (fixUpDonatedOps): make instatiations of polymorphs in importer for those taht already exist in our flat module so that our equations etc that use those instantiations can be translated * mixfixModule.cc (makePolymorph): pass extra component arg to ctors for BranchSymbol() and EqualitySymbol() * preModule.cc (process): set firstOnTheFlySymbol * preModule.hh (class PreModule): added data member firstOnTheFlySymbol * symbolTranslation.hh (translationExists): added Wed Dec 9 09:53:59 1998 Steven Eker * mixfixModule.hh (class MixfixModule): added decl for copyFixUpPolymorph() * mixfixModule.cc (copyFixUpPolymorph): added * import.cc (fixUpDonatedOps): use copyFixUpPolymorph() to fixup imported polymorphs * mixfixModule.hh (class MixfixModule): updated decl for addPolymorph() * metaDown.cc (downOpDecl): pass Token as first arg of addPolymorph() * entry.cc (addPolymorph): take Token as first arg * process.cc (processOps): pass Token as fisrt arg of addPolymorph() * import.cc (donateOps): first crude attempt at handling polymorphs * metaDown.cc (downOpDecl): use new tokenize() (downVarDecl): use new tokenize() * token.hh (tokenize): added 2nd version * mixfixModule.hh (class MixfixModule): update decl for addOpDeclaration() * entry.cc (addOpDeclaration): set line number for created symbol; take first arg as a Token rather than as an int * token.hh (makePrefixName): added * preModule.cc (dump): use prefixName rather than prefixNameCode (two places) * import.cc (donateOps): use prefixName rather than prefixNameCode (two places) * process.cc (processOps): use prefixName rather than prefixNameCode (two places) * ops.cc (addVarDecl): set prefixName rather than prefixNameCode (addOpDecl): set prefixName rather than prefixNameCode; use makePrefixName() * preModule.hh (class PreModule): Token prefixName replaces int prefixNameCode in struct OpDecl * preModule.cc (fixUpSymbols): (LOOP_SYMBOL section) updated cast on qidListSymbol; fixed bad cast on nilQidListSymbol * loopSymbol.cc (fixUp): 3 arg now AU_Symbol* * loopSymbol.hh (class LoopSymbol): data member qidListSymbol becomes an AU_Symbol*; added decl for copyFixUp() (class LoopSymbol): updated decl for fixUp() * loopSymbol.cc (copyFixUp): added * import.cc (fixUpDonatedOps): handle LOOP_SYMBOLs using LoopSymbol::copyFixUp() Tue Dec 8 10:35:21 1998 Steven Eker * import.cc (fixUpDonatedOps): handle META_LEVEL_OP_SYMBOLs using MetaLevelOpSymbol::copyFixUp() * metaLevelOpSymbol.hh (class MetaLevelOpSymbol): added decl for copyFixUp() * metaLevelOpSymbol.cc (copyFixUp): added, using new MetaLevel ctor * metaLevel.hh (class MetaLevel): added decl for new ctor * metaLevel.cc (bind): rewritten using macro expansion to generate the huge branching code fragment (MetaLevel): new ctor, using macro expansion to copy and translate an original MetaLevel object * metaLevelSignature.cc: created * metaLevel.hh (class MetaLevel): replace long list of data member decls with macro expansion version * mixfixModule.hh (class MixfixModule): added SYMBOL_TYPE to enum SymbolFlags * import.cc (fixUpDonatedOps): use OPS_FIXED_UP (fixUpDonatedOps): simplified using MachineIntegerOpSymbol::copyFixUp() (fixUpDonatedOps): simplified QuotedIdentifierOpSymbol case * preModule.hh (class PreModule): added OPS_FIXED_UP to enum Phase Mon Dec 7 10:31:50 1998 Steven Eker * quotedIdentifierOpSymbol.hh (class QuotedIdentifierOpSymbol): added decl for copyFixUp() * quotedIdentifierOpSymbol.cc (copyFixUp): added * import.cc (fixUpDonatedOps): handle MACHINE_INTEGER_OPs (fixUpDonatedOps): handle QUOTED_IDENTIFIER_OPs * mixfixParser.cc (parseTerm): put \n before -versus- * entry.cc (addOpDeclaration): check for variable overloading and overloading with incompatable flags Sun Dec 6 18:52:51 1998 Steven Eker * preModule.cc (process): call fixUpImportedOps() * preModule.hh (class PreModule): added op decls for fixUpImportedOps() and fixUpDonatedOps() * import.cc (donateOps): set opDecl.importSymbol if we are the importOriginator; could try setting this to zero if not and avoid the need for the importOriginator flag; but this might cause a problem with polymorphs later on (fixUpImportedOps): added (fixUpDonatedOps): added * preModule.hh (class PreModule): added importOriginator field to struct OpDecl; the idea is we set this during an import of this PreModule to know if we have responsibility for fixing up this particular symbol (class PreModule): added fields importSymbol and importPolymorphIndex to struct OpDecl Sat Dec 5 17:23:31 1998 Steven Eker * metaLevelOpSymbol.cc (metaApply): added hack to make sure all dagNodes in substitution have sorts (they might be identities or pulled out from under lazy function symbols). Fri Dec 4 11:07:21 1998 Steven Eker * preModule.cc (dump): use MixfixModule:: qualification on enums * mixfixModule.hh (class MixfixModule): enum Precedence made public * preModule.cc (fixUpSymbols): use MixfixModule:: qualification on enums (fixUpSymbols): use flatModule 11 (dump): use flatModule * ops.cc (addVarDecl): use MixfixModule:: qualification on enums (setPrec): use MixfixModule:: qualification on enums (setGather): use MixfixModule:: qualification on enums (setStrat): use MixfixModule:: qualification on enums (addHook): use MixfixModule:: qualification on enums * command.cc (parse): use flatModule (reduce): use flatModule (3 places) (rewrite): use flatModule (3 places) (cont): use flatModule (loop): use flatModule (3 places) (contLoop): qualify LOOP_SYMBOL (contLoop): use flatModule (3 places) (match): use flatModule (3 places) (loop): qualify LOOP_SYMBOL * preModule.cc (findHookSymbol): use flatModule (2 more places) * process.cc (processSorts): use flatModule (2 places) (processSorts): use MixfixModule:: qualification on enums (getSort): use flatModule (2 places) (processOps): use MixfixModule:: qualification on enums (processOps): use flatModule (3 places) (processStatements): use flatModule * import.cc (importOps): use flatModule (importStatements): use flatModule (donateStatements): use flatModule (3 places) (donateOps): use flatModule (2 places) (donateSorts): use flatModule (donateOps): use MixfixModule:: qualification on enums (importSorts): use flatModule * preModule.cc (PreModule): set flatModule = new MixfixModule; this is a temporary hack; once we have lazy updating we should do something else (~PreModule): delete flatModule (PreModule): don't initialize our now non-existant base (findHookSymbol): use flatModule (process): use flatModule (11 places) * modules.y: qualify attribute enums with MixfixModule rather than PreModule * bottom.y (cleanUpParser): use getFlatModule() * commands.y: use getFlatModule() in all show commands that are actually implemented in class MixfixModule * preModule.hh (class PreModule): no longer derived from MixfixModule (class PreModule): added data member flat module (getFlatModule): added Thu Dec 3 17:09:15 1998 Steven Eker * interact.cc (initialize): ignore interval timer signals in order to allow for very long runs * main.hh: deleted currentModule decl * top.y: currentModule var def moved here * main.cc (main): recognize -batch flag; issue warning rather than error for unrecognized flag; get interactive flag correct Wed Dec 2 10:32:38 1998 Steven Eker * top.y: added decls for cTokenBarMatchLeqNumber and cTokenBarMatchLeqRight * commands.y: moduleAndTerm2 -> mModuleAndTerm inEnd2 -> mInEnd added mNumberModuleTerm, mNumberModuleTerm1 and mNumberModuleTerm2 added cTokenBarMatchLeqNumber and cTokenBarMatchLeqRight modified match syntax to handle [] * preModule.hh (class PreModule): added decl for match() * command.cc (match): added * commands.y: deleted inExp and nonInTerm use moduleAndTerm2 in match command syntax added match; use in place of MATCH * top.y: added decl for cTokenBarMatchLeqColon * commands.y: added moduleAndTerm2 and inEnd2 added cTokenBarMatchLeqColon and cTokensBarMatchLeqColon Tue Dec 1 12:07:34 1998 Steven Eker * commands.y: use cTokens rather than tokens in "(" ")"; parse this in command mode * top.y: added decl for cSimpleTokenBarDot * commands.y: added cSimpleTokenBarDot, use this in place of tokenBarDot in cSimpleOpName * top.y: ctoken -> cToken cTokenBarNumber -> cTokenBarDotNumber cTokenBarRight -> cTokenBarDotRight * commands.y: allow cTokenBarIn to take '.' hacked inEnd to disallow empty term in the "in module" case (for consistancy) revert to using moduleAndTerm for parse and reduce commands allow cTokenBarLeftIn to take '.' cTokenBarNumber -> cTokenBarDotNumber cTokenBarRight -> cTokenBarDotRight nrModuleTerm* replaced by numberModuleTerm* which handle things like rew [ . and rew [42 . in a consistant way use ctokens rather than tokens in cSimpleOpName ctokens -> cTokens ctoken -> cToken * top.y: cTokenBarColon -> cTokenBarDotColon * commands.y: cTokenBarColon -> cTokenBarDotColon cTokensBarColon -> cTokensBarDotColon * top.y: added decls for select, optDebug and optNumber * commands.y: debug -> optDebug fused both continue productions added optNumber fused trace select and trace deselect commands added select non-terminal opNamesList2 -> cOpNameList simpleNameList2 -> cSimpleNameList ===================================Engine44================================================== Mon Nov 30 16:52:02 1998 Steven Eker * command.cc (rewrite): don't print result or set saved dag if aborting * lexerAux.cc (includeFile): use IssueWarning() rather than ErrorCheck() to handle errors Wed Nov 25 08:58:32 1998 Steven Eker * mixfixModule.cc (makeComponentProductions): nasty little hack for Paco - we don't add production ::= if Foo is a bubble component * quotedIdentifierOpSymbol.cc (eqRewrite): use traceAbort() * metaLevelOpSymbol.cc (metaSortLeq): return the value of builtInReplace() since we now have to deal with abort (metaSameComponent): ditto (metaLeastSort): ditto (metaLesserSorts): ditto (metaGlbSorts): ditto (metaParse): ditto (errorRewrite): ditto (errorRewrite2): ditto (metaReduce): reorg to handle abort correctly; use UserLevelRewritingContext::META_EVAL (metaRewrite): ditto (metaApply): ditto, but much more complicated - may want to simplify at some point * command.cc (reduce): only print result if we didn't abort * userLevelRewritingContext.hh (class UserLevelRewritingContext): added decl for traceAbort() * userLevelRewritingContext.cc (tracePostEqRewrite): stripped abortFlag handling code since this should now no longer be called if abortFlag set; added Assert() to check this property; not quit true; may be called after tracePreEqRewrite() thats sets abort flag; Assert moved inside if stmt * interact.cc (traceAbort): added * userLevelRewritingContext.hh (clearDebug): clear abortFlag * interact.cc (handleDebug): handle abortFlag; decremeted debugLevel before going into abort mode * userLevelRewritingContext.cc (tracePostEqRewrite): first attempt at recognizing abortFlag * trial.cc: created to hold all trial code from userLevelRewritingContext.cc * preModule.hh (class PreModule): updated cont() decl * commands.y: added syntax and semantics for debug cont command * command.cc (cont): call UserLevelRewritingContext::setDebug() if debug arg true and UserLevelRewritingContext::clearDebug() at the end anyway Tue Nov 24 14:57:44 1998 Steven Eker * command.cc (rewrite): call UserLevelRewritingContext::setDebug() if debug arg true and UserLevelRewritingContext::clearDebug() at the end anyway * preModule.hh (class PreModule): updated rewrite() decl * commands.y: added syntax and semantics for debug rewrite * userLevelRewritingContext.hh (setTraceFlag): added * commands.y: use UserLevelRewritingContext::setTraceFlag() instead of RewritingContext::setTraceStatus() * top.y: move empty case from item to top added loop nonterminal so we can treat the empty case specially * userLevelRewritingContext.hh (class UserLevelRewritingContext): added decl for displayPrompt() * interact.cc (setInteractive): call display prompt if we changed from non-interactive to interactive and we didn't see a ctrl-C (displayPrompt): added (commandLoop): use displayPrompt() * userLevelRewritingContext.hh (setInteractive): moved to interact.cc * top.y: now have recursive top def; do YYACCEPT more selectively; in particular do not do an YYACCEPT immediatly after recognizing "in" since we don't want a spurious prompt; or after we successfully handle an "eof" Mon Nov 23 11:08:39 1998 Steven Eker * mixfixModule.cc (findSymbol): temp hack to find bug * userLevelRewritingContext.hh (setDebug): added (clearDebug): added (class UserLevelRewritingContext): added decls for setDebug() and clearDebug() * preModule.hh (class PreModule): updated decl for reduce() * command.cc (reduce): call UserLevelRewritingContext::setDebug() if debug arg true and UserLevelRewritingContext::clearDebug() at the end anyway * lexer.flex: added keyword debug * top.y: added debug non terminal decl and token KW_DEBUG * commands.y: added debug non terminal; added "debug reduce" command * interact.cc (commandLoop): restore trace status after handling ctrl-C interrupt * userLevelRewritingContext.hh (class UserLevelRewritingContext): added static data members stepFlag and abortFlag; deleted static data member parseResult * interact.cc (handleDebug): rewritten using stepFlag and abortFlag Sat Nov 21 12:29:23 1998 Steven Eker * top.y: set parseResult to QUIT for empty command * main.cc (main): update call to commandLoop() * userLevelRewritingContext.hh (class UserLevelRewritingContext): updated commandLoop() decl * interact.cc (commandLoop): use new yyparse() convention; return parseResult (handleDebug): use new commandLoop() convention * userLevelRewritingContext.hh (setParseResult): deleted (class UserLevelRewritingContext): deleted static data member parseResult * commands.y: use PARSER_RESULT macro rather than UserLevelRewritingContext::setParseResult() to avoid reentrancy problem * top.y: added back non-terminal "item"; now do a YYACCEPT; after each item to avoid hanging on look-a-head use YYPARSE_PARAM to avoid reentrancy problem Fri Nov 20 11:44:35 1998 Steven Eker * main.cc (main): use MixfixModule::setPrintMixfix(false) * lexer.flex: use UserLevelRewritingContext::interrupted(), QUIT -> KW_QUIT * bottom.y (yyerror): use UserLevelRewritingContext::interrupted() * commands.y (command): debugging commands rewritten using UserLevelRewritingContext::setParseResult() * top.y (directive): rewritten using UserLevelRewritingContext::setParseResult() * userLevelRewritingContext.hh (setParseResult): added * top.y: don't touch prompt global variable; top is no longer a recursive list of items deleted non-terminal "item" token QUIT -> KW_QUIT * main.hh: deleted decls for ctrlC_Interrupt and prompt global variables * main.cc (main): call UserLevelRewritingContext::initialize() (interruptHandler): deleted (setSignalHandlers): deleted deleted ctrlC_Interrupt global variable (main): don't call setSignalHandlers() * userLevelRewritingContext.hh (setInteractive): added * lexerAux.cc (getInput): use UserLevelRewritingContext::interrupted() (cleanUpLexer): call UserLevelRewritingContext::setInteractive() (includeFile): call UserLevelRewritingContext::setInteractive() (handleEof): call UserLevelRewritingContext::setInteractive() deleted global variable "interactive" * userLevelRewritingContext.hh (class UserLevelRewritingContext): deleted static data members debugMode, savedTraceStatus, debugStatus (class UserLevelRewritingContext): added static data members interactiveFlag, traceFlag, debugLevel and parseResult (class UserLevelRewritingContext): enum ParseResult replaces enum DebugCommand (class UserLevelRewritingContext): deleted decls for handleCtrlC(), clearCtrlC(), debugCommand(), printPrompt() (class UserLevelRewritingContext): added decls for interruptHandler(), initialize() (interrupted): added Thu Nov 19 15:42:33 1998 Steven Eker * interact.cc: created by splitting off user interaction code from userLevelRewritingContext.cc (clearCtrlC): deleted (handleCtrlC): deleted (commandLoop): rewritten (handleDebug): rewritten (printPrompt): deleted (debugCommand): deleted (initialize): added (interruptHandler): added Wed Nov 18 11:47:25 1998 Steven Eker * userLevelRewritingContext.hh (class UserLevelRewritingContext): added WHERE to enum DebugCommand * lexer.flex: added keyword where * commands.y: added syntax for where command * top.y: added token KW_WHERE * userLevelRewritingContext.hh (class UserLevelRewritingContext): added decl for where() * userLevelRewritingContext.cc (where): added * lexerAux.cc (getInput): call printPrompt() * userLevelRewritingContext.hh (class UserLevelRewritingContext): added decl for printPrompt() * userLevelRewritingContext.cc (debugCommand): added (printPrompt): added * userLevelRewritingContext.hh (class UserLevelRewritingContext): added DebugCommand (class UserLevelRewritingContext): added decl for debugCommand() and static data member debugStatus * lexer.flex: added keyword resume, abort and step * commands.y: added syntax and actions for resume, abort and step * top.y: added tokens for resume, abort and step Mon Nov 16 10:39:06 1998 Steven Eker * lexerAux.cc (cleanUpLexer): need to goto INITIAL mode, not ID_MODE * userLevelRewritingContext.hh (class UserLevelRewritingContext): added decls for commandLoop(), handleCtrlC(), clearCtrlC() (class UserLevelRewritingContext): added decl for handleDebug() * userLevelRewritingContext.cc (traceBeginEqTrial): call handleDebug() (traceBeginRuleTrial): call handleDebug() (traceBeginScTrial): call handleDebug() (tracePreEqRewrite): call handleDebug() (tracePreRuleRewrite): call handleDebug() (tracePreScApplication): call handleDebug() (commandLoop): added (handleDebug): added * userLevelRewritingContext.hh (class UserLevelRewritingContext): added static data members ctrlC_Flag, debugMode, savedTraceStatus * userLevelRewritingContext.cc (clearCtrlC): added (handleCtrlC): added * userLevelRewritingContext.hh (class UserLevelRewritingContext): updated makeSubcontext() decl * metaLevelOpSymbol.cc (metaSortLeq): use RewritingContext::builtInReplace() (metaSameComponent): use RewritingContext::builtInReplace() (metaLeastSort): use RewritingContext::builtInReplace() (metaLesserSorts): use RewritingContext::builtInReplace() (metaGlbSorts): use RewritingContext::builtInReplace() (metaReduce): use RewritingContext::builtInReplace() (metaParse): use RewritingContext::builtInReplace() (metaRewrite): use RewritingContext::builtInReplace() (metaApply): use RewritingContext::builtInReplace() (errorRewrite): use RewritingContext::builtInReplace() (errorRewrite2): use RewritingContext::builtInReplace() * quotedIdentifierOpSymbol.cc (eqRewrite): traceStatus() -> getTraceStatus() * userLevelRewritingContext.hh (class UserLevelRewritingContext): updated complex ctor decl * commands.y: setTraceFlag() -> setTraceStatus() * userLevelRewritingContext.hh (setTraceFlag): deleted (class UserLevelRewritingContext): deleted static data member traceFlag * userLevelRewritingContext.cc (UserLevelRewritingContext): (simple version): init parent, purpose and localTraceFlag (UserLevelRewritingContext): (complex version): take extra args parent and purpose; init parent, purpose and localTraceFlag (makeSubcontext): purpose is now an int, pass parent and purpose to ctor; use localTraceFlag (traceBeginEqTrial): check localTraceFlag (traceBeginRuleTrial): check localTraceFlag (traceBeginScTrial): check localTraceFlag (tracePreScApplication): check localTraceFlag (tracePreRuleRewrite): check localTraceFlag (tracePreEqRewrite): check localTraceFlag * userLevelRewritingContext.hh (class UserLevelRewritingContext): added enum OtherPurpose; data members parent, purpose, localTraceFlag Sat Nov 14 21:17:50 1998 Steven Eker * main.cc (interruptHandler): take arg list (...) for ANSI compliance No longer need decl for sigvec() Fri Nov 13 11:39:46 1998 Steven Eker * main.cc (main): call cleanUpLexer() rather than returnToTopLevel() and lexerInitialMode() * lexerAux.cc (returnToTopLevel): becomes cleanUpLexer(), now restore initial lexer mode * main.cc (main): call returnToTopLevel() when recovering from an interrrupt * lexer.flex: don't call handleEof() in start of yylex() code; clean up will be handled by outside caller via returnToTopLevel() (<>): call yyterminate() if ctrlC_Interrupt; handleEof() will now only handle real eofs and eof directives; not eofs generated by ctrl-C handling; maybe we should use yywrap()? * lexerAux.cc (getInput): rewritten using read() system call to avoid slow system call restart problem in linux stdio lib (returnToTopLevel): added * lexer.flex: MAUDE_EOF -> KW_EOF * top.y: MAUDE_EOF -> KW_EOF * lexer.flex: define YY_DECL; use pure parser calling convention instead of yylval * top.y: added %pure_parser directive Thu Nov 12 11:19:29 1998 Steven Eker * lexer.flex: added code to check for ctrlC_Interrupt and call yyterminate() if true; the reason for this is that if we are reading from a file we may grab a huge chunk of the file with a single call to YY_INPUT and then end up ignore ctrl-C while we processs it; * fileTable.cc (beginModule): only print module name type and name if file stack is non-empty; this is a temporary hack we really need some consistant way of check for an interactive file and quiet reading mode (closeFile): print message about being down with file (openFile): print message about reading file * lexerAux.cc (handleEof): deleted prompt code * fileTable.cc (beginModule): print module name type and name * lexer.flex: deleted promptSave * lexerAux.cc (eatComment): don't increment line number for \r (includeFile): set interactive (handleEof): set interactive * main.cc (setSignalHandlers): use sigaction mechanism rather than sigvec mechanism for compatibility with non-bsd 4.2 based unixes Wed Nov 11 14:01:33 1998 Steven Eker * main.cc: made ctrlC_Interrupt volatile * main.hh (yylex): made ctrlC_Interrupt volatile Tue Nov 10 11:53:24 1998 Steven Eker * bottom.y (cleanUpParser): handle case where there is no currentModule * lexerAux.cc (getInput): now return void * bottom.y (cleanUpParser): if currentModule is incomplete, print an advisory and delete it (yyerror): be quiet if handling a ctrl-C * lexer.flex: don't handle prompting anymore * lexerAux.cc (handleEof): don't allow inStackPtr to go -ve during ctrl-C handling (getInput): call clearerr() if we get an EOF due to ctrl-C (getInput): handle prompting * main.cc (main): use cleanUpParser() after ctrl-C * bottom.y (cleanUpParser): added * main.cc (main): reset lexer and recall parser after ctrl-C * bottom.y (yyerror): issue advisory in ctrl-C case * main.cc (main): use sigvec() * main.hh (yylex): added decl for ctrlC_Interrupt * main.cc: added global variable ctrlC_Interrupt * lexer.flex: redefine YY_INPUT to use getInput() * lexerAux.hh (handleEof): added decl for getInput() * lexerAux.cc (getInput): added Mon Nov 9 11:40:20 1998 Steven Eker * modules.y: opNameList2 and simpleOpName2 moved to command.y * parser.bison: split into top.y, modules.y, commands.y, bottom.y Fri Nov 6 16:34:11 1998 Steven Eker * lexer.flex: added tokens MATCH_LEQ and UNIFY_EQ to command mode * parser.bison (command): added syntax for match command; have select command use moduleExp (ctokens): added (ctoken): added (cTokenBarDot): accept MATCH_LEQ, UNIFY_EQ; use ctokens (cTokenBarColon): accept MATCH_LEQ, UNIFY_EQ; use ctokens (cTokenBarMatchLeq): accept UNIFY_EQ; use ctokens (cTokenBarIn): accept MATCH_LEQ, UNIFY_EQ; use ctokens (cTokenBarLeftIn): accept MATCH_LEQ, UNIFY_EQ; use ctokens (cTokenBarNumber): accept MATCH_LEQ, UNIFY_EQ; use ctokens (cTokenBarRight): accept MATCH_LEQ, UNIFY_EQ; use ctokens * quotedIdentifierTerm.cc (deepCopy): -> deepCopy2() * quotedIdentifierTerm.hh (class QuotedIdentifierTerm): deepCopy() -> deepCopy2() Thu Nov 5 16:11:48 1998 Steven Eker * parser.bison (renamingItem): made syntax consistant with OBJ3 (renamingList): made syntax consistant with OBJ3 (command): modified red and parse command to use inExp and nonInTerm nonterminals; this means that (at least for the moment - some flex hacking may be possible) we will no longer accept command like "red in(0) .", but we can now use the bison parser to directly parse complex module expressions occuring in commands * lexer.flex: added keywords include and BOOL * parser.bison (command): added syntax for set include BOOL on/off command Wed Nov 4 11:24:34 1998 Steven Eker * metaDown.cc (downOpDecl): set line number of symbol to FileTable::META_LEVEL_CREATED (downVarDecl): set line number of symbol to FileTable::META_LEVEL_CREATED * process.cc (processOps): set line number of symbol if we are the originator * import.cc (donateOps): set line number of symbol if we are the original; check for symbol clash and give informative message * preModule.cc (PreModule): set our line number * import.cc (donateSorts): set line number of added sorts to that of original sort (donateSorts): have very detailed sort clash message incorporating line numbers and modules of clashing sorts. * metaDown.cc (downSorts): set line number of added sorts to FileTable::META_LEVEL_CREATED * process.cc (processSorts): set line number of added sorts (getSort): set line number of added sort to FileTable::SYSTEM_CREATED; don't need findSort() hack any more * mixfixModule.hh (class MixfixModule): updated addSort() decl * entry.cc (addSort): return ptr to new sort * metaLevelOpSymbol.cc (metaParse): pass line number as FileTable::META_LEVEL_CREATED when turning Qids into tokens * mixfixParser.cc (makeStatement): use LineNumber::setLineNumber() in 6 places to store a line number in each mb/eq/rl (makeTerm): restructured; store line number of first token of parse in each term ===================================Engine43================================================== Sat Oct 31 13:06:55 1998 Steven Eker * mixfixModule.hh (class MixfixModule): updated decl for prettyPrint() (Term* version) * prettyPrint.cc (showAll): get fmod/mod endfm/endm correct (prettyPrint): (Term* version) modified algorithm to take capture components into account - now symmetric with DagNode* version Fri Oct 30 17:25:08 1998 Steven Eker * lexer.flex: added kinds and components keywords * parser.bison (command): added syntax for show kinds command * mixfixModule.hh (class MixfixModule): added decl for showComponents() * prettyPrint.cc: added * lexer.flex: added summary keyword * parser.bison (command): added syntax for show summary command * mixfixModule.hh (class MixfixModule): added decl for showSummary() * prettyPrint.cc (showSummary): added * parser.bison (moduleExp): temporary hack to allow simple imports to work again Thu Oct 29 11:46:18 1998 Steven Eker * parser.bison (endfm): added (endm): added (module): use endfm and endm to handle incorrect end of module keyword (moduleExp): added (renamingList): added (renamingItem): added * prettyPrint.cc (operator<<): (Rule* version) print labels as "[foo]:" rather than "[foo] :" * import.cc (donateStatements): handle rules (donateStatements): handle membership axioms * preModule.cc (process): insert module into module database here (PreModule): don't do it here Tue Oct 27 10:56:35 1998 Steven Eker * prettyPrint.cc (showVars): don't print invisible variables * import.cc (donateOps): add translations for symbols we imported into importers symbols so that our equations can be correctly imported in the next phase (donateOps): need to translate sort components! do this by finding name of 1st user sort of component, looking up the corresponding sort in the importer, and taking its component * preModule.hh (class PreModule): added data member nrImportedOps * import.cc (donateStatements): onlt import native equations * preModule.cc (process): set nrImportedMembershipAxioms, nrImportedEquations, nrImportedRules * symbolTranslation.cc (translate): added assert to catch no translation case Mon Oct 26 09:27:19 1998 Steven Eker * preModule.cc (process): call importStatements() * preModule.hh (class PreModule): added decls for importStatements() and donateStatements() * import.cc (donateStatements): added (importStatements): added * mixfixModule.cc (makeSymbolProductions): don't make productions for invisible symbols * import.cc (donateOps): make imported variables invisible * entry.cc (addOpDeclaration): support INVISIBLE flag * mixfixModule.hh (class MixfixModule): added INVISIBLE to enum SymbolFlags * preModule.hh (class PreModule): added decls for importOps() and donateOps() * import.cc (donateOps): added (importOps): added * symbolTranslation.hh (class SymbolTranslation): created * symbolTranslation.cc: created Fri Oct 23 11:28:35 1998 Steven Eker * preModule.cc (process): fill out nrImportedSubsorts vector * import.cc (donateSorts): handle subsorts * preModule.hh (class PreModule): added decl for resetImportPhase() (class PreModule): added data member nrImportedSubsorts; * import.cc (donateSorts): import from flatten sort vector rather than from sort declarations; this is simpler and does the right thing for automatically created sorts (resetImportPhase): added * preModule.cc (process): set nrImportedSorts and nrUserSorts * preModule.hh (class PreModule): added data members nrUserSorts, nrImportedSorts, nrImportedMembershipAxioms, nrImportedEquations, nrImportedRules * preModule.cc (process): call resetImports() * import.cc (donateSorts): need to update importPhase (resetImports): added Thu Oct 22 11:01:05 1998 Steven Eker * import.cc (processImports): prohibit recursive importation * preModule.cc (process): call importSorts() * preModule.hh (class PreModule): added decls for processImports(), importSorts(), donateSorts() * import.cc: created (donateSorts): added * preModule.cc (PreModule): set importPhase = UNVISITED (process): call processImports() * preModule.hh (class PreModule): added data member importedModules (class PreModule): added data member importPhase; (class PreModule): added enum Phase * process.cc (processSorts): use LineNumber ctor (processSorts): use IssueWarning() and LineNumber ctor (getSort): use IssueWarning() and LineNumber ctor * ops.cc (addVarDecl): use IssueWarning() and LineNumber ctor (setPrec): use IssueWarning() and LineNumber ctor (setGather): use IssueWarning() and LineNumber ctor (2 places) (setStrat): use IssueWarning() and LineNumber ctor * mixfixParser.cc (parseTerm): use IssueWarning() and LineNumber ctor (2 places) (parseStatement): use IssueWarning() and LineNumber ctor (2 places) (parseSentence): use IssueWarning() and LineNumber ctor * parser.bison (attrKeyword): use IssueWarning() and LineNumber ctor * lexer.flex: use IssueWarning() and LineNumber ctor thoughout * fileTable.cc (printLineNumber): don't bother printing (command) when we're not in a module * lexer.flex: have FMOD and MOD return Token * parser.bison: have FMOD and MOD return Token (module): call FileTable::beginModule() and FileTable::endModule() * fileTable.cc (printLineNumber): print file name correctly * lexerAux.cc (includeFile): added call to FileTable::openFile() (handleEof): added call to FileTable::closeFile() * main.cc: added global variable fileTable * fileTable.cc (closeFile): rewritten using new scheme (endModule): implemented Wed Oct 21 11:27:03 1998 Steven Eker * fileTable.cc (closeFile): created * fileTable.hh (class FileTable): created Fri Oct 16 16:03:13 1998 Steven Eker * mixfixModule.cc (findSort): added AdvisoryCheck() for the case where we couldn't find sort (findSymbol): added AdvisoryCheck() for the case where we couldn't find symbol (findSort): removed AdvisoryCheck() since we often look for non-existant sorts at object level Thu Oct 15 15:14:01 1998 Steven Eker * metaLevelOpSymbol.hh (class MetaLevelOpSymbol): dded decls for postInterSymbolPass() and reset() * metaLevelOpSymbol.cc (postInterSymbolPass): added (reset): added * metaLevel.hh (class MetaLevel): added decls for postInterSymbolPass() and reset() * metaLevel.cc (postInterSymbolPass): added (reset): added Wed Oct 14 15:49:11 1998 Steven Eker * metaLevelOpSymbol.cc (eqRewrite): get META_SORT_LEQ and META_SAME_COMPONENT cases arround the correct way * metaDown.cc (downFixUps): fix up identities * metaFastUp.cc (fastUpBool): implemented using CachedDag::getDag() * metaLevel.cc (bind): Term* version added * metaLevel.hh (class MetaLevel): added data members trueTerm and falseTerm (class MetaLevel): added decl for Term* version of bind() * preModule.cc (fixUpSymbols): handle TERM_HOOK in MetaLevel Tue Oct 13 18:52:07 1998 Steven Eker * metaLevelOpSymbol.cc (metaSameComponent): added (eqRewrite): added META_SAME_COMPONENT case (fixUp): added META_SAME_COMPONENT case * metaLevelOpSymbol.hh (class MetaLevelOpSymbol): added META_SAME_COMPONENT to OpType (class MetaLevelOpSymbol): added decl for metaSameComponent() ===================================Engine42================================================== Fri Oct 9 15:29:00 1998 Steven Eker * quotedIdentifierDagNode.hh (getIdIndex): made const (class QuotedIdentifierDagNode): updated decl of getIdIndex() Thu Oct 8 14:49:12 1998 Steven Eker * quotedIdentifierDagNode.cc (compareArguments): simplified * quotedIdentifierTerm.cc (compareArguments): (DagNode* version) added const and simplified (compareArguments): (Term* version) added const and simplified * quotedIdentifierDagNode.cc (compareArguments): added const * metaFastUp.cc (fastUpQid): added const_cast Wed Sep 30 15:50:48 1998 Steven Eker * mixfixModule.hh (class MixfixModule): updated decl for prettyPrint() (DagNode* version) * prettyPrint.cc (prettyPrint): (DagNode* version) added idea of leftCaptureComponent and rightCaptureComponent to avoid introducing unnecessary parens to avoid captures that can't happen anyway because of component clashes (operator<<): (DagNode* version) use new prettyPrint() conventions ===================================Engine41================================================== Mon Sep 21 10:32:40 1998 Steven Eker * metaLevel.hh (class MetaLevel): updated decls for downSort() and fastUpSort() * metaFastUp.cc (fastUpSort): deleted SortCode arg * metaDown.cc (downSort): deleted SortCode arg * metaLevelOpSymbol.cc (metaSortLeq): use new sort mechanisms (metaLeastSort): use new sort mechanisms (metaLesserSorts): use new sort mechanisms (metaGlbSorts): use new sort mechanisms * prettyPrint.cc (showSorts): use leq(Sort*, int) (showSorts): use leq(int, Sort*) (showSorts): use leq(Sort*, Sort*) (2 places) ===================================Engine40================================================== Thu Aug 27 13:47:16 1998 Steven Eker * prettyPrint.cc (prettyPrint): (term version) modified needParen condition and capture calcs to ensure we get capture values correct in the case that we insert parens or sort disambiguation (prettyPrint): (prettyPrint): (dagnode version) symmetric changes made * preModule.hh (class PreModule): added decl for printBubble() * command.cc (printBubble): added (contLoop): use printBubble() (loop): use printBubble() Wed Aug 26 16:54:11 1998 Steven Eker * prettyPrint.cc (prettyPrint): updated rangeKnown propagation calc to take into account once we decide to insert sort disambiguation then we will know range (both versions). * mixfixModule.hh (class MixfixModule): updated decl for prettyPrint() (dagnode version) * prettyPrint.cc (operator<<): (dagnode version) pass rangeKnown = false (prettyPrint): (dagnode version) added rangeKnown and code for sort disambiguation * loopSymbol.cc (createQidList): backquote ( ) [ ] { } , (extractQid): remove backquote if backquoted thing is a single char NOTE: need to come up with global policy and functions for backquoted and unbackquoting * token.hh (class Token): made specialChar public Mon Aug 24 11:12:03 1998 Steven Eker * mixfixModule.hh (class MixfixModule): updated decl for prettyPrint() (term version) * prettyPrint.cc (operator<<): (term version) pass rangeKnown = false (prettyPrint): (term version) added rangeKnown and code for sort disambiguation Fri Aug 21 10:24:05 1998 Steven Eker * process.cc (processSorts): handle "Universal" sort slots of polymorphs correctly * preModule.cc (findSymbol): deleted (extractSpecialSymbol): deleted (extractSpecialTerms): deleted * command.cc (loop): implemented (contLoop): implemented * loopSymbol.hh (class LoopSymbol): added decls for createQidList(), extractQid(), extractQidList() * loopSymbol.cc (injectInput): added (extractOutput): added (extractQid): added (extractQidList): added (createQidList): added * loopSymbol.hh (class LoopSymbol): added decls for extractOutput() and injectInput() Thu Aug 20 10:48:49 1998 Steven Eker * preModule.hh (class PreModule): added decls for loop() and contLoop() * command.cc (loop): added stub (contLoop): added stub * parser.bison (command): added "( tokens )" command * lexer.flex: added loop keyword now recognize ( and ) in initial mode * parser.bison (command): added loop command * preModule.cc (fixUpSymbols): hand LoopSymbols * entry.cc (addOpDeclaration): handle LOOP_SYMBOL flag * loopSymbol.cc: added * loopSymbol.hh (class LoopSymbol): created * preModule.cc (fixUpSymbols): rewritten using new functions and data structure and supporting new notation notation * process.cc (processOps): use findHook() * preModule.hh (class PreModule): added decls for findHook() and findHookSymbol() * preModule.cc (findHook): added (findHookSymbol): added * process.cc (processOps): handle new Bubble special format Wed Aug 19 11:18:48 1998 Steven Eker * ops.cc (addHook): check for LoopSymbol * mixfixModule.hh (class MixfixModule): added LOOP_SYMBOL to enum SymbolFlags * ops.cc (setSpecial): deleted (addHook): created * preModule.hh (class PreModule): deleted decl for setSpecial(); added decl for addHook() (class PreModule): added struct Hook; OpDef.special is now Vector * lexer.flex: added id-hook, op-hook, term-hook * parser.bison (attrKeyword): added KW_ID_HOOK, KW_OP_HOOK, KW_TERM_HOOK (attribute): special now takes hook list (hookList): added (hook): added * token.cc (prefixNameCode): simplified using specialChar() (prefixNameCode): added fast case for 1 token without leading special char (extractMixfix): use bufferExpandTo() and specialChar() (extractMixfix): simplified removing all backQuote warnings under the assumption that prefix code will always be legal * token.hh (specialChar): added (class Token): added decl for specialChar() * token.cc (prefixNameCode): simplified using new semantics of bufferExpandTo() * token.hh (bufferExpandTo): use reallocateBuffer() (class Token): added decl for reallocateBuffer() * token.cc (reallocateBuffer): added Tue Aug 18 10:39:19 1998 Steven Eker * token.cc (prefixNameCode): rewritten and greatly simpified; handle difficult cases correctly * lexer.flex: completely rewrote definition of tokens: no longer worry about starting with *** or ---> We now have strict idea about where ` can appear in a token - only between normal characters or in front of ( ) [ ] { } , Amount matched by comments increased so that will prevail * metaLevel.cc (MetaLevel): remove UMR bug by setting cachedModule = 0 * metaLevel.hh (class MetaLevel): added ctor decl * lexer.flex: don't allow stray backquotes in tokens ` becomes an unexpected token in initial mode detect stray ` in id mode unmade these chnange since ` is allowed in id's to indicate a space Mon Aug 10 16:16:46 1998 Steven Eker * lexer.flex: prevent tokens from containing the string *** so that comments do not have to have a space after *** Now only rule out *** at the begining of a token Fri Jul 31 12:29:13 1998 Steven Eker * metaDown.cc (downBubbleSpec): handle excluded tokens * process.cc (processOps): pass dummy vector to addBubbleSpec() * mixfixModule.hh (class MixfixModule): updated addBubbleSpec() decl * entry.cc (addBubbleSpec): take excludedTokens arg * mixfixParser.cc (makeTerm): need to resize rather than contract to deal with 0 length bubbles * metaDown.cc (downBubbleSpec): strip back quotes from parens * metaLevel.hh (class MetaLevel): added decls for downFixUps() and downFixUpBubble() * metaDown.cc (downFixUpBubble): added (downFixUps): added * metaModule.hh (class MetaModule): make MetaLevel into a friend for a really nasty hack * metaFastUp.cc (fastUpTerm): nasty hack to get qids to go up right - need to fix many other cases * metaDown.cc (downOpDecl): handle bubbles specially (downBubbleSpec): added * metaLevel.hh (class MetaLevel): added decls for downHookList() and downIdHook() * metaDown.cc (downAttr): handle special list (downHookList): added (downIdHook): added * preModule.cc (fixUpSymbols): hack for call to fixUpBubbleSpec() * mixfixModule.hh (class MixfixModule): updated fixUpBubbleSpec() decl * mixfixModule.cc (makeBubbleProductions): handle excluded tokens (fixUpBubbleSpec): handle nilQidListSymbol * metaLevel.cc (bind): handle hookListSymbol, idHookSymbol, opHookSymbol, termHookSymbol * metaLevel.hh (class MetaLevel): added hookListSymbol, idHookSymbol, opHookSymbol, termHookSymbol data members * metaDown.cc (downAttr): handle prec and gather * metaLevelOpSymbol.cc (metaParse): use new fastUpTerm() (errorRewrite): cast first arg in call to fastUpTerm() to disambiguate (old one should really be renamed to fastUpDag() * quotedIdentifierTerm.hh (getIdIndex): added; together with decl * metaFastUp.cc (fastUpTerm): Term* version added * metaDown.cc (downModule): rewritten to inter leave down calls with module processing calls in proper order * metaLevelOpSymbol.cc (fixUp): link in META_PARSE (eqRewrite): call metaParse() * metaLevel.hh (class MetaLevel): made downQidList() public * metaLevelOpSymbol.cc (metaParse): implemented is a really hacky way * metaLevelOpSymbol.hh (class MetaLevelOpSymbol): added decl for metaParse(); added META_PARSE to enum OpType * metaLevel.cc (bind): opDeclListSymbol and nilOpDeclListSymbol goto opDeclSetSymbol * metaDown.cc (downOpDecls): opDeclListSymbol and nilOpDeclListSymbol goto opDeclSetSymbol; set ctor is now ACU * metaLevel.hh (class MetaLevel): opDeclSetSymbol and emptyOpDeclSetSymbol replace opDeclListSymbol and nilOpDeclListSymbol Thu Jul 30 12:38:46 1998 Steven Eker * preModule.cc (fixUpSymbols): implemented shareWith feature for MetaLevelOpSymbols * metaLevel.cc (bind): support data memebrs just added * metaLevel.hh (class MetaLevel): added data members memoSymbol, precSymbol, gatherSymbol, specialSymbol * mixfixModule.hh (class MixfixModule): added nilQidListSymbol to struct BubbleSpec * mixfixParser.cc (makeTerm): backquote ()[]{}, before turning them into qids (makeTerm): deal with empty bubble case * metaLevel.hh (class MetaLevel): updated decls for downAttrSet() and downAttr() * metaDown.cc (downAttrSet): rewritten (downAttr): rewritten * mixfixModule.cc (findSymbol): fixed nasty bug where we were using index rather than firstSymbols[index] to start our search * metaFastUp.cc (fastUpQid): added (fastUpTerm): use fastUpQid * mixfixModule.cc (createSortTest): set SORT_TEST flag * mixfixModule.hh (getFlags): added (class MixfixModule): added SORT_TEST to enum SymbolFlags Wed Jul 29 11:13:54 1998 Steven Eker * preModule.cc (extractSpecialSymbol): added (fixUpSymbols): fix up MetaLevelOpSymbols * metaFastUp.cc: adapted from old version * mixfix.hh: created * entry.cc (addOpDeclaration): create MetaLevelOpSymbols * ops.cc (setSpecial): recognize MetaLevelOpSymbol * process.cc (processOps): don't call MachineIntegerSymbol::fixUp() * metaLevelOpSymbol.cc: adapted from old version (fixUp): added * metaLevelOpSymbol.hh: adapted from old version * metaDown.cc (downOpDecl): rewritten Tue Jul 28 16:39:20 1998 Steven Eker * metaDown.cc: MixfixModule -> MetaModule (downTerm): rewritten * metaLevel.hh (class MetaLevel): added data member metaDisambigSymbol; MixfixModule -> MetaModule * metaModule.cc: created * metaModule.hh: created * mixfixModule.cc (findSymbol): added * entry.cc (addOpDeclaration): only compare domains if arities are the same! * mixfixModule.hh (class MixfixModule): added decl for findSymbol.cc * metaDown.cc (downQidSet): deal with repeated elements correctly (downMembAx): rewritten (downVarDecl): rewritten (downSubsort): rewritten (downEquation): rewritten Mon Jul 27 10:37:17 1998 Steven Eker * command.cc (showModule): added stub * preModule.hh (class PreModule): added decl for showModule() * parser.bison (command): use selectModule() in cont and many of the show commands * command.cc (rewrite): print number of rewrites limit in showCmd case (if not UNBOUNDED) * parser.bison (command): pass start = 1 to selectModule() in parse, red and rew commands to skip over "in" * preModule.hh (class PreModule): updated decl for selectModule() * command.cc (selectModule): added start arg * preModule.hh (class PreModule): added decl for selectModule(); deleted decl for findModule() * preModule.cc (findModule): deleted * command.cc (selectModule): added * parser.bison (command): use selectModule() in select, parse, red and rew commands * preModule.cc (findModule): added * preModule.hh (class PreModule): added decl for findModule * preModule.cc: added moduleNames and modules static data (PreModule): save pointer to new module together with name in modules and moduleNames * preModule.hh (class PreModule): added static data members moduleNames and modules; * preModule.cc (PreModule): don't initialize moduleName, pass moduleType (dump): don't use moduleName * mixfixModule.hh (class MixfixModule): added moduleType arg to ctor (class MixfixModule): added data member moduleType * preModule.hh (class PreModule): added moduleType arg to ctor (class PreModule): delete data member moduleName; * mixfixModule.cc (MixfixModule): now take module type arg Sat Jul 25 12:56:50 1998 Steven Eker * parser.bison (tokenBarDot): added NUMBER_TOK since we use this in command mode in "trace select" (maybe we should have a complete split between cmd mode and id mode?) * lexer.flex: added keyword select * parser.bison: bubble2 -> moduleExpr (command): added syntax for select command * command.cc (rewrite): removed hack to recognize limit within bubble since we can now resolve this in the bison parser * lexer.flex: need to distinguish NUMBER from NUMBER_TOK because of return types * parser.bison (cTokensBarColon): need to distinguish NUMBER from NUMBER_TOK because of return types * lexer.flex: have command mode recognize [ ] and numbers * parser.bison (cTokenBarRight): added (cTokenBarNumber): added (cTokenBarLeftIn): added (nrModuleTerm): added (nrModuleTerm1): added (nrModuleTerm2): added (token): added NUMBER since we may use this is command mode where numbers are now recognized * metaDown.cc: created from old front end metaDown.cc Fri Jul 24 15:02:37 1998 Steven Eker * metaLevel.hh: created from old maudeModule.hh * mixfixModule.cc (makeBubbleProductions): hacked to new parser-bubble conventions Thu Jul 23 11:31:15 1998 Steven Eker * mixfixModule.hh (class MixfixModule): added MAKE_BUBBLE action * mixfixParser.cc (parseSentence): handle previously unseen tokens if we have bubble specs present (makeTerm): added code to MAKE_BUBBLE * mixfixModule.hh (class MixfixModule): added decl for makeBubbleProductions() * mixfixModule.cc (makeBubbleProductions): added (makeGrammar): call makeBubbleProductions(); * preModule.cc (fixUpSymbols): call fixUpBubbleSpec() if op is a bubble * mixfixModule.hh (class MixfixModule): added decls for addBubbleSpec() and fixUpBubbleSpec() * mixfixModule.cc (fixUpBubbleSpec): added * entry.cc (addBubbleSpec): added * ops.cc (setSpecial): recognize Bubble * process.cc (processOps): call addBubbleSpec() if op is a bubble * mixfixParser.cc (parseTerm): use ROOT_NODE (2 places) (parseStatement): use ROOT_NODE * mixfixModule.hh (class MixfixModule): added BUBBLE flag (class MixfixModule): added data member bubble components Wed Jul 22 10:55:16 1998 Steven Eker * mixfixModule.hh (class MixfixModule): deleted INSTANTIATE_POLYMORPH, PREVIOUS, CREATE_ITEF, CREATE_EQUALITY actions (class MixfixModule): deleted instantiatePolymorph() and fixupPolymorphs() decls * mixfixModule.cc (MixfixModule): deleted gatherAnyAnyAny * mixfixModule.hh (class MixfixModule): deleted decls for insertSymbol() (both versions), insertSort(), createItef(), createEquality(); deleted EQUALITY_PREC; deleted gatherAnyAnyAny * mixfixModule.cc (makePolymorph): get condition for expanding instantiations vector correct (makeGrammar): don't call fixupPolymorphs() * mixfixParser.cc (makeTerm): get polymorphIndex, componentIndex around the right way * mixfixModule.cc (makePolymorphProductions): compute nrArgs correctly * ops.cc (setSpecial): recognize BranchSymbol and EqualitySymbol * process.cc (getSort): hack to make sure we return the correct sort * preModule.hh (class PreModule): added polymorphIndex to struct OpDecl (actually a union with symbol) * mixfixModule.hh (class MixfixModule): added decls for makePolymorph() and fixUpPolymorph() (class MixfixModule): added MAKE_POLYMORPH to enum Actions * mixfixModule.cc (createItef): deleted (createEquality): deleted * mixfixParser.cc (makeTerm): don't handle PREVIOUS, CREATE_EQUALITY, CREATE_ITEF, INSTANTIATE_POLYMORPH (makeTerm): handle MAKE_POLYMORPH * process.cc (processOps): add polymorphs * preModule.cc (fixUpSymbols): fix up polymorphs as well * mixfixModule.cc (makePolymorphProductions): heavily rewritten (insertSort): deleted (insertSymbol): deleted (both versions) (insertPolymorph): deleted (makePolymorph): added (instantiatePolymorph): deleted (fixupPolymorph): added (fixupPolymorphs): deleted * mixfixModule.hh (class MixfixModule): reorganized struct Polymorph * entry.cc (addPolymorph): added Tue Jul 21 11:34:36 1998 Steven Eker * mixfixModule.hh (class MixfixModule): added decl for makeBoolProductions(); deleted decl for protectingBool() * mixfixModule.cc (protectingBool): deleted (makeBoolProductions): added (makeGrammar): call makeBoolProductions(); * entry.cc (addOpDeclaration): set trueSymbol, falseSymbol, boolSort * preModule.cc (fixUpSymbols): fix up QuotedIdentifierOpSymbols * quotedIdentifierOpSymbol.hh (class QuotedIdentifierOpSymbol): updated fixUp() decl * quotedIdentifierOpSymbol.cc (fixUp): take op arg as a string; this will avoid having to do this translation in several places in the future * quotedIdentifierOpSymbol.hh (class QuotedIdentifierOpSymbol): added decl for fixUp(), deleted decl for setSymbols(), updated decl for ctor * quotedIdentifierOpSymbol.cc (fixUp): added (setSymbols): deleted (QuotedIdentifierOpSymbol): now just take id and nrArgs * entry.cc (addOpDeclaration): can't use domainComponent(0 and rangeComponent() here since the symbols have yet to be compiled; take a look at the first op decl instead * mixfixModule.hh (class MixfixModule): made findMatchingParen() protected * preModule.hh (class PreModule): added decl for extractSpecialTerms() * preModule.cc: added (fixUpSymbols): fix up MachineIntegerOpSymbols * process.cc (processOps): added code to fixUp() MachineIntegerSymbols * quotedIdentifierTerm.hh (class QuotedIdentifierTerm): added decl for deepCopy() * quotedIdentifierTerm.cc (deepCopy): added * preModule.hh (class PreModule): tidying up of old decls Mon Jul 20 10:43:11 1998 Steven Eker * preModule.hh (class PreModule): fixUpIdentities() -> fixUpSymbols() * preModule.cc (fixUpIdentities): -> fixUpSymbols() (process): call fixUpSymbols() * process.cc (getSort): use addSort() * preModule.cc (makeSymbol): deleted (process): don't call protectingBool() * lexer.flex (id): BUILTIN -> SPECIAL * parser.bison (attribute): BUILTIN -> SPECIAL (attribute): use setSpecial() * preModule.hh (class PreModule): deleted connectedOpDefs(), protectingBoolSort() and protectingBoolOps() decls * process.cc (processOps): rewritten using MixfixModule::addOpDeclaration() * production.cc (connectedOpDefs): deleted (processOps): moved to process.cc * preModule.cc (getSort): moved to process.cc (processStatements): moved to process.cc (processSorts): moved to process.cc * process.cc (processSorts): updated to use new struct OpDef * ops.cc (addVarDecl): updated to use new struct OpDef (setGather): updated to use new struct OpDef (setStrat): updated to use new struct OpDef * preModule.hh (class PreModule): setBuiltIn() ->setSpecial(), setDomain() -> setDomainAndRange(),setRange() deleted * ops.cc (setSpecial): replaces setBuiltIn() * preModule.hh (class PreModule): struct OpDef completely reorganized * ops.cc (setDomainAndRange): replaces setDomain() (setRange): deleted * parser.bison (declaration): use setDomainAndRange * entry.cc (addOpDecl): -> addOpDeclaration() * mixfixModule.hh (class MixfixModule): updated insertSort() decl (class MixfixModule): addOpDecl() -> addOpDeclaration() * entry.cc (addSort): reverted to previous version * preModule.hh (class PreModule): added originator field to struct OpDecl * lexer.flex (id): added KW_ prefixes to COMM, IDEM, PREC, GATHER, STRAT and MEMO * parser.bison (attribute): removed OP_ prefixes to flags added KW_ prefixes to COMM, IDEM, PREC, GATHER, STRAT and MEMO * preModule.cc (dump): OP_VARIABLE -> VARIABLE * ops.cc (addVarDecl): OP_VARIABLE -> VARIABLE (setPrec): OP_PREC -> PREC (setGather): OP_GATHER -> GATHER (setStrat): OP_STRAT -> STRAT * preModule.hh (class PreModule): deleted enum Flags * mixfixModule.hh (class MixfixModule): data member sorts deleted * mixfixModule.cc (insertSymbol): MACHINE_INT -> MACHINE_INTEGER (makeSymbolProductions): MACHINE_INT -> MACHINE_INTEGER (findSort): sorts -> sortNames (insertSort): sorts -> sortNames * mixfixModule.hh (class MixfixModule): updated addSort() and addOpDecl() decls * entry.cc (addOpDecl): major rewrite; removed special arg since how this will be generated will be very different between object level and metalevel; pass domain and range as vector of sorts (addSort): major rewrite; now return sort and have firstDecl flag * mixfixModule.hh (class MixfixModule): added data members sortNames, symbolNames, firstSymbols (class MixfixModule): added decls for addOpDecl() and addSort() * entry.cc (addOpDecl): added special arg; handle parts of builtins that don't rely on other symbols Sun Jul 19 18:35:29 1998 Steven Eker * mixfixModule.hh (class MixfixModule): enum SyntaxFlags changed to enum SymbolFlags; added many new values * entry.cc (addSort): added (addOpDecl): added Fri Jul 17 18:27:03 1998 Steven Eker * mixfixModule.cc (createEquality): use new ctor convention for EqualitySymbol (instantiatePolymorph): use new ctor convention for EqualitySymbol ===================================Engine39================================================== Thu Jul 16 10:34:26 1998 Steven Eker * mixfixModule.cc (makePolymorphProductions): fixed precedence bug (<< vs +) * mixfixModule.hh (class MixfixModule): added data member currentOffset * mixfixParser.cc (parseStatement): set currentOffset = 0 (parseTerm): set currentOffset = begin (makeTerm): use currentOffset (2 places) * mixfixModule.hh (class MixfixModule): added decl for fixupPolymorphs() * mixfixModule.cc (fixupPolymorphs): added (instantiatePolymorph): use specialTerms (makeGrammar): call fixupPolymorphs() * mixfixModule.hh (class MixfixModule): added specialTerms to struct Polymorph * token.cc (extractMixfix): fixed nasty memory bug where we were freeing mismatched memory; delete rather than delete [] Wed Jul 15 11:52:09 1998 Steven Eker * production.cc (processOps): horrible hack to recognize polymorphic symbols. * mixfixModule.cc (makeGrammar): call makePolymorphProductions() (instantiatePolymorph): added handling for BranchSymbol * production.cc (processOps): horrible hack to insert polymorphs * mixfixModule.hh (class MixfixModule): added decl for findMatchingParen() * mixfixModule.cc (findMatchingParen): added * mixfixModule.hh (class MixfixModule): updated insertPolymorph() decl * mixfixModule.cc (insertPolymorph): domainSorts and special becomes Vectors, rangeSort becomes a Token Tue Jul 14 11:21:46 1998 Steven Eker * lexer.flex: added NUMBER tokens * preModule.hh (class PreModule): added decl for cont() * lexer.flex: added continue/cont keyword * parser.bison (command): added syntax and action for cont command * command.cc (rewrite): hack to recognize limit within bubble; probably need better solution (cont): added * lexerAux.cc (lexerInMode): use yy_push_state() rather tha BEGIN() * lexer.flex (IN_MODE): use yy_pop_state() to restore original state rather than just going to initial state * mixfixModule.hh (class MixfixModule): added decl for instantiatePolymorph() Mon Jul 13 11:02:57 1998 Steven Eker * mixfixModule.hh (class MixfixModule): updated decls for parseTerm() and parseSentence() * mixfixParser.cc (makeTerm): handle PREVIOUS and INSTANTIATE_POLYMORPH actions (parseSentence): handle begin and end arguments (parseTerm): take and pass on begin and end arguments Sat Jul 11 15:21:25 1998 Steven Eker * userLevelRewritingContext.cc (tracePreRuleRewrite): added \n's to make big rewrites more readable (tracePreEqRewrite): added \n's to make big rewrites more readable Fri Jul 10 17:34:01 1998 Steven Eker * mixfixModule.hh (class MixfixModule): added decl for makePolymorphProductions() (class MixfixModule): added INSTANTIATE_POLYMORPH and PREVIOUS to enum Actions * mixfixModule.cc (makePolymorphProductions): added * mixfixModule.hh (class MixfixModule): added decl for insertPolymorph() and data member polymorphs * mixfixModule.cc (insertPolymorph): added * bool.cc (protectingBoolSort): don't use non-existant data member sorts * mixfixModule.hh (class MixfixModule): added decl for findSort() * mixfixModule.cc (findSort): added * preModule.cc (getSort): rewritten using MixfixModule::findSort() (processSorts): rewritten using MixfixModule::findSort() * preModule.hh (class PreModule): deleted data member sorts * mixfixModule.hh (class MixfixModule): added decl for insertSort() and data member sorts * mixfixModule.cc (insertSort): added * mixfixModule.hh (class MixfixModule): updated computePrecAndGather() decl * mixfixModule.cc (computePrecAndGather): first arg is now nrArgs; do computation of LEFT_BARE/RIGHT_BARE here (insertSymbol): no longer do computation of LEFT_BARE/RIGHT_BARE here (makeSymbolProductions): pass nrArgs to computePrecAndGather() * mixfixModule.hh (class MixfixModule): added struct Polymorph Thu Jul 9 10:32:27 1998 Steven Eker * token.cc (checkForSpecialProperty): avoid mistaking "-" for a SMALL_NEG and "" for a SMALL_NAT * production.cc (processOps): ugly hack to prevent adding op decl for symbol derived from NA_Symbol since class ctor automatically adds and op decl (should it? - probably want to change this later) * mixfixModule.cc (makeSpecialProductions): handle QUOTED_IDENTIFIERs * mixfixModule.hh (class MixfixModule): MAKE_QUOTED_IDENTIFIER added to enum Actions * production.cc (processOps): hack to pass quotedIdentifier flag to insertSymbol() * mixfixModule.hh (class MixfixModule): added QUOTED_ID to enum NonTerminal (class MixfixModule): added QUOTED_IDENTIFIER to enum SyntaxFlags (class MixfixModule): updated insertSymbol() decl * mixfixParser.cc (makeTerm): handle MAKE_QUOTED_IDENTIFIER case * mixfixModule.cc (insertSymbol): handle quotedIdentifier flag (makeSymbolProductions): handle quoted id case * preModule.cc (fixUpIdentities): fix up QuotedIdentifierOpSymbols here for want of a better place * quotedIdentifierOpSymbol.cc (setSymbols): added * quotedIdentifierOpSymbol.hh (class QuotedIdentifierOpSymbol): machineIntegerSymbol no longer a constant; added decl for setSymbols() * quotedIdentifierOpSymbol.cc (QuotedIdentifierOpSymbol): quotedIdentifierSymbol and machineIntegerSymbol are no longer initialized as constants * preModule.cc (makeSymbol): handle QuotedIdentifierSymbol and QuotedIdentifierOpSymbol special cases * quotedIdentifierOpSymbol.cc: adapted from old frontend; removed all refs to idTable; use class Token * quotedIdentifierOpSymbol.hh: copied from old frontend * quotedIdentifierTerm.cc: adapted from old frontend; removed all refs to idTable; use class Token * quotedIdentifierTerm.hh: adapted from old frontend; removed internal StringTable reference * quotedIdentifierDagNode.cc: adapted from old frontend; removed all refs to idTable; use class Token * quotedIdentifierDagNode.hh: adapted from old frontend; removed internal StringTable reference * token.cc (checkForSpecialProperty): detect quoted identifiers * token.hh (class Token): added QUOTED_IDENTIFIER to enum SpecialProperties * preModule.hh (class PreModule): added decl for findSymbol() * preModule.cc (fixUpIdentities): fix up MachineIntegerOpSymbols here for want of a better place (findSymbol): added Wed Jul 8 10:41:24 1998 Steven Eker * production.cc (processOps): quick hack to handle machine ints; need to do something less ugly once other things crystalize * mixfixModule.cc (insertSymbol): handle machineInt flag (makeSymbolProductions): handle machine ints * mixfixModule.hh (class MixfixModule): added data member current sentence (class MixfixModule): added syntax flag MACHINE_INT (class MixfixModule): updated insertSymbol() decl * mixfixParser.cc (makeTerm): handle MAKE_MACHINE_INT case (parseStatement): set currentSentence (parseTerm): set currentSentence * mixfixModule.hh (class MixfixModule): added MAKE_MACHINE_INT to enum Actions * mixfixParser.cc (parseSentence): check for specialProperties of previously unseen tokens and use special terminals * mixfixModule.hh (class MixfixModule): added data member specialTerminals and decl for makeSpecialProductions() * mixfixModule.cc (makeSpecialProductions): added (makeGrammar): call makeSpecialProductions() * token.hh (class Token): added enum SpecialProperties, and decls for static and non-static versions of specialProperty() (specialProperty): added non-static version (specialProperty): added static version * token.cc (dotNameCode): use our encode() rather than StringTable::encode() (prefixNameCode): use our encode() rather than StringTable::encode() (extractMixfix): use our encode() rather than StringTable::encode() (*6) (checkForSpecialProperty): added * token.hh (encode): if it is the first time we've seen this string, check to see if it has a special property. (tokenize): use our encode() rather than StringTable::encode() * mixfixModule.hh (class MixfixModule): added SMALL_NAT and SMALL_NEG to enum NonTerminal Tue Jul 7 10:56:56 1998 Steven Eker * preModule.hh (class PreModule): updated decl for makeSymbol() * production.cc (processOps): pass this pointer to makeSymbol() * preModule.cc (makeSymbol): added module arg and handling for MachineIntegerSymbol and MachineIntegerOpSymbol * preModule.hh (class PreModule): added builtIn field to struct OpDef; added decl for setBuiltIn(); * ops.cc (setBuiltIn): added * lexer.flex (id): added builtin * parser.bison (attribute): added builtin attribute syntax and action (attrKeyword): added BUILTIN as attribute * lexer.flex (OP_MODE): deleted * lexerAux.cc (lexerOpMode): deleted * preModule.hh (class PreModule): added decls for addSelected() and traceSelect() and static data member selected * userLevelRewritingContext.hh (class UserLevelRewritingContext): updated decl for selectSymbols() * userLevelRewritingContext.cc (selectSymbols): made first arg const * command.cc (traceSelect): added * parser.bison (command): added actions for trace select/deselect. * command.cc (addSelected): added * parser.bison (simpleOpName2): adde (opNameList2): made symmetric with opNameList Mon Jul 6 09:27:26 1998 Steven Eker * preModule.hh (class PreModule): removed name member from struct OpDecl * preModule.cc (dump): use prefix name code rather than full mixfix name * ops.cc (addOpDecl): don't store full op name * parser.bison (opName): removed lexer mode changes (opNameList): removed lexer mode changes (opName2): deleted since we no longer need to flip lexer state (opNameList2): eleted since we no longer need to flip lexer state (command): added new opNameList2 and syntax for trace select/deselect * mixfixModule.hh (class MixfixModule): 1 arg version of insertSymbol(0 is private * mixfixModule.cc (insertSymbol): had to put in 1 arg version for protectingBool; want to remove this eventually * production.cc (processOps): only use the one remaining insertSymbol() * mixfixModule.hh (class MixfixModule): updated one insertSymbol() decl and deleted other * mixfixModule.cc (insertSymbol): make use of extractMixfix() to get mixfix syntax from prefix name rather than mixfixSyntax arg (insertSymbol): deleted mixfixSyntax arg (insertSymbol): deleted 2 arg version * token.hh (class Token): added decl for extractMixfix() * token.cc (extractMixfix): heavily rewritten Sat Jul 4 13:59:41 1998 Steven Eker * token.cc (extractMixfix): first attempt at an implementation for this function Thu Jul 2 11:43:16 1998 Steven Eker * mixfixParser.cc (parseTerm): print out first two parses in ambiguous case * preModule.hh (class PreModule): updated parse() decl * parser.bison (command): use new parse() * command.cc (parse): added * preModule.cc (reduce): deleted (parse): deleted * preModule.hh (setShowStats): added (setShowCmd): added (setShowTiming): added (class PreModule): added decls for above * parser.bison (command): added PreModule calls for set show ... commands * preModule.hh (class PreModule): added decls for reduce() and rewrite() * parser.bison (command): use rewrite() and new reduce() * command.cc (rewrite): added * preModule.hh (class PreModule): added static data members showCmd, showStats, showTiming, saved Wed Jul 1 11:14:10 1998 Steven Eker * command.cc: created * mixfixParser.cc (makeStatement): handle labels correctly * mixfixModule.cc (makeLabelProductions): pass MAKE_LABEL as action and label token number as data to insertProd() * mixfixParser.cc (makeStatement): added mb, cmb, rl, crl cases * mixfixModule.cc (makeStatementProductions): added actions to several productions * mixfixModule.hh (class MixfixModule): added actions MAKE_RL, MAKE_CRL, MAKE_LABEL, MAKE_MB, MAKE_CMB * mixfixParser.cc (makeStatement): added (makeCondition): added (makeTerm): removed MAKE_EQ and MAKE_CEQ code (parseStatement): call makeStatement() rather than makeTerm() * preModule.cc (fixUpIdentities): use parseTerm() rather than parseSentence() (processStatements): use parseStatement() rather than parseTerm() (parse): use parseTerm() rather than parseSentence() (reduce): use parseTerm() rather than parseSentence() * mixfixParser.cc (parseSentence): now just do first part of pass; don't call makeTerm() * mixfixModule.hh (class MixfixModule): parseSentence() now returns int and is private, makeTerm() is private; adde decls for parseTerm() and parseStatement() * mixfixParser.cc (parseTerm): added (parseStatement): added * mixfixModule.hh (domainComponentIndex): moved to mixfixModule.cc * mixfixModule.cc (protectingBool): don't call setBool() * mixfixParser.cc: now becomes another implementation file for class MixfixModule (setBool): deleted (insertProd): use data member parser (parseSentence): use data member parser (makeTerm): no need to reference module. * mixfixModule.hh (class MixfixModule): no longer derived from MixfixParser (class MixfixModule): added enum Actions and data members tokens, parser, actions, data. Tue Jun 30 10:24:27 1998 Steven Eker * userLevelRewritingContext.cc: copied from old front end; selected becomes an IntSet (selectSymbols): symbols becomes an IntSet (traceBeginEqTrial): selected becomes an IntSet so check symbols id() (traceBeginRuleTrial): selected becomes an IntSet so check symbols id() (traceBeginScTrial): selected becomes an IntSet so check symbols id() (tracePreEqRewrite): selected becomes an IntSet so check symbols id() (tracePreRuleRewrite): selected becomes an IntSet so check symbols id() (tracePreScApplication): selected becomes an IntSet so check symbols id() * userLevelRewritingContext.hh: copied from old front end (class UserLevelRewritingContext): make selected an IntSet rather than a PointerSet * parser.bison: added semantic actions for set trace ... commands * prettyPrint.cc (showOps): use printAttributes(); print symbols attributes even when sort calcs are implemented by C++ (no op decls for symbol) * mixfixModule.hh (class MixfixModule): added decls for printAttributes() and showAll() * prettyPrint.cc (printAttributes): added (showAll): added * mixfixModule.hh (class MixfixModule): added enum ModuleType * prettyPrint.cc (showEquations): becomes showEqs() (showRls): added (showMbs): added (showVars): added (showSorts): added (showOps): added * parser.bison (command): call calls to showSorts(), showOps(), showVars(), showMbs(), showRls(); showEquations() becomes showEqs() * mixfixModule.hh (class MixfixModule): added decls for showSorts(), showOps(), showVars(), showMbs(), showRls(); showEquations() becomes showEqs() Mon Jun 29 10:36:29 1998 Steven Eker * mixfixModule.hh (class MixfixModule): added decl for showEquations() * prettyPrint.cc (operator<<): added operator<<() for const NamedEntity*, const SortConstraint*, const Equation* and const Rule* (showEquations): added * lexer.flex: added sorts, ops, vars, mbs, eqs, rls keyword in INITIAL mode * parser.bison (command): added syntax for show sorts, show ops, show vars, show mbs, show eqs, show rls * lexer.flex: added "all" and "module" keywords * parser.bison: added syntax for show mod, show module and show all * ops.cc (setStrat): allow -ve strat arg positions * preModule.cc (makeSymbol): pass users strategy to symbol ctors * preModule.hh (class PreModule): added strategy member to struct OpDef (class PreModule): added decl for setStrat() * ops.cc (setGather): clear opDef.gather and gather in error case (setStrat): added * parser.bison (attribute): call setStrat() Sat Jun 27 16:54:43 1998 Steven Eker * prettyPrint.cc (graphCount): added (graphPrint): added Fri Jun 26 10:58:51 1998 Steven Eker * prettyPrint.cc (prettyPrint): created Term* version * mixfixModule.hh (class MixfixModule): make prettyPrint() private, remove default args; make printTokens() and printTails() static (class MixfixModule): make operator<<() for Term* and DagNode* friends * prettyPrint.cc (prettyPrint): set needAssocParen if symbol is associative and printWithParens is true Move operator<< for DagNode* here Move operator<< for Term* here * mixfixModule.hh (setPrintMixfix): added (setPrintWithParens): added (setPrintFlat): added (setPrintGraph): added * parser.bison (command): added actions for set print ... commmands * prettyPrint.cc: created to hold all pretty printer code (prettyPrint): simplified use of arg (printTails): set noSpace if pos == 0 so that multi token constants don't get an extra leading space (prettyPrint): handle printFlat flag * mixfixModule.cc (prettyPrint): mixfixFlag -> printMixfix, maxParenFlag -> printWithParens * mixfixModule.hh (class MixfixModule): added static data members printFlat and printGraph; mixfixFlag -> printMixfix, maxParenFlag -> printWithParens * lexer.flex (id): ASSOC -> KW_ASSOC, CONDITION -> KW_CONDITION * parser.bison (attrKeyword): ASSOC -> KW_ASSOC, CONDITION -> KW_CONDITION to prevent defines clashing with enums in included header files * mixfixModule.hh (nonTerminal): moved to mixfixModule.cc * lexer.flex: added extra keywords needed for set commands * parser.bison (command): added syntax for set commands Thu Jun 25 15:18:18 1998 Steven Eker * mixfixModule.cc (computePrecAndGather): don't let gather values go -ve by prec 0 and gather e (computePrecAndGather): give assoc infix operator with prec > 0 the gather pattern (e E) (printTails): handle needAssocParen flag (prettyPrint): take into account the possible need for parens inside the right associative unflattening of a flatten assoc term (printTails): don't set noSpace = true when we print an assoc paren because if we were really unflatten first before printing then thisparen can have no effect on a tail that is really above it in the unfattened term (printTails): set noSpace = false at the start of each out loop iteration based on similar reasoning * mixfixParser.hh (class MixfixParser): MAKE_TRUE replaces MAKE_CEQ2 * mixfixParser.cc (makeTerm): fuse CEQ and CEQ2 cases to handle CONDITION nonterminal * mixfixModule.cc (protectingBool): simplified now that we have a non-terminal for condition (makeStatementProductions): use CONDITION and give its (initial) definition * mixfixModule.hh (class MixfixModule): added CONDITION to enum NonTerminal * mixfixModule.cc (createEquality): use EQUALITY_PREC * mixfixModule.hh (class MixfixModule): added static member gatherPrefix * mixfixModule.cc (MixfixModule): initialize gatherPrefix (makeSymbolProductions): use gatherPrefix for assoc case Wed Jun 24 15:55:23 1998 Steven Eker * mixfixModule.cc (makeSymbolProductions): use PREFIX_GATHER rather than any (MixfixModule): initialize gatherPrefixPrefix (makeComponentProductions): use gatherPrefixPrefix and PREFIX_GATHER for assoc lists * preModule.cc (OpDef): set prec to default * ops.cc (setGather): use enum GatherSymbols constants * production.cc (processOps): don't process opdefs here since default prec depends on exact syntax of operator, and computation of default gather might even depend on sort info (processOps): all syntax processing removed * mixfixModule.hh (class MixfixModule): added enum GatherSymbols; added decl for computePrecAndGather() * mixfixModule.cc (computePrecAndGather): added (makeSymbolProductions): call computePrecAndGather() * mixfixModule.hh (class MixfixModule): added EQUALITY_PREC to enum Precedence Tue Jun 23 17:45:34 1998 Steven Eker * mixfixModule.cc (printTokens): try to get spacing correct (printTails): try to get spacing correct * mixfixModule.hh (class MixfixModule): updated prettyPrint() decl * main.cc (operator<<): updated call to prettyPrint() * mixfixModule.cc (insertSymbol): set flags field (insertSymbol): set flags field (createItef): set flags field (createEquality): set flags field (createSortTest): set flags field (makeSymbolProductions): use si.flags (prettyPrint): rewritten to handle left and right capture and new flags * mixfixModule.hh (class MixfixModule): added static data members mixfixFlag and maxParenFlag (class MixfixModule): added PREFIX_PREC, PREFIX_GATHER, UNARY_PREC, INFIX_PREC to enum Precedence (class MixfixModule): SymbolInfo assoc field changes to flags; added enum SyntaxFlags Wed Jun 17 10:50:22 1998 Steven Eker * mixfixParser.cc (makeTerm): updated to use new createSortTest() conventions (makeTerm): fixed really nasty bug where we were using node number rather than production number to find data (sort index) for CREATE_SORT_TEST (insertProd): print action and data numbers * mixfixModule.hh (class MixfixModule): updated createSortTest(); added data members eagerSortTests and lazySortTests * mixfixModule.cc (createEquality): added (protectingBool): insert productions for mixfix version of equalities (createSortTest): added (makeComponentProductions): pass sort index as data field in sort production (createSortTest): changed so we return Term* and store pointers to created sort test symbols in MinfixModule rather than MixfixParser * mixfixModule.hh (class MixfixModule): added decls for createEquality() and createSortTest() * mixfixParser.cc (makeTerm): added CREATE_EQUALITY and CREATE_SORT_TEST cases * mixfixModule.cc (protectingBool): use class boolSort, trueSymbol and falseSymbol variables * mixfixParser.cc (makeTerm): use createItef() * mixfixModule.hh (class MixfixModule): added decl for createItef and data members boolSort, trueSymbol and falseSymbol * mixfixModule.cc (createItef): added Tue Jun 16 14:59:22 1998 Steven Eker * mixfixModule.hh (class MixfixModule): added static data member getAnyAnyAny * mixfixModule.cc (MixfixModule): initialize gatherAnyAnyAny; * mixfixParser.cc (makeTerm): handle CREATE_ITEF * mixfixModule.cc (protectingBool): add syntax for if_then_else_fi in each component * mixfixParser.cc (setBool): added; replaces setTrueSymbol() * mixfixParser.hh (class MixfixParser): added data members falseSymbol and boolSort (class MixfixParser): added decl for setBool(), deleted decl for setTrueSymbol() * mixfixParser.cc (insertProd): take datum arg (makeTerm): make use of data vec * mixfixParser.hh (class MixfixParser): added data member data (class MixfixParser): module now a pointer to MixfixModule (class MixfixParser): actions are no longer -ve; added MAKE_TERM (class MixfixParser): updated insertProd() decl Mon Jun 15 17:16:49 1998 Steven Eker * preModule.cc (process): call protectingBool(); don't pass 2nd arg to makeGrammar() * mixfixModule.hh (class MixfixModule): make protectingBool() public (class MixfixModule): reverted makeGrammar() decl * mixfixModule.cc (makeGrammar): removed protectingBool() stuff * production.cc (processOps): don't call protectingBoolOps() * mixfixModule.hh (class MixfixModule): updated makeGrammar() decl * preModule.cc (process): pass 0 as 2nd arg to makeGrammar() * mixfixModule.cc (protectingBool): added (makeGrammar): take boolSortIndex arg; call protectingBool if necessary * mixfixModule.hh (class MixfixModule): added decl for protectingBool() * preModule.cc (getSort): compare index to NONE rather than 0 Fri Jun 12 09:57:02 1998 Steven Eker * bool.cc (protectingBoolSort): use insert() instead of int2Index() * preModule.cc (processSorts): use insert() instead of int2Index() (getSort): use insert() instead of int2Index(); no need to use contains * production.cc (makeLabelProductions): use cardinality() instead of nrElements() * preModule.cc (addRule): use insert() instead of int2Index() Thu Jun 11 18:26:40 1998 Steven Eker * mixfixParser.cc (insertProd): use insert() instead of int2Index() (parseSentence): no need to use contains * preModule.hh (class PreModule): IntTable -> IntSet ===================================Engine38================================================== Mon Jun 8 18:21:46 1998 Steven Eker * parser.bison (opNameList): added; old opNameList becomes opNameList2 inorder to switch lex mode (opName2): changed paren case to allow _(_); also allows completely empty syntax which we must now check for elsewhere (simpleOpName): changed paren case to allow _(_); also allows completely empty syntax which we must now check for elsewhere Fri Jun 5 09:32:11 1998 Steven Eker * preModule.cc (insertSymbol): added (prettyPrint): added (printTokens): added (printTails): added * production.cc (processOps): call new insertSymbol() with syntax info * preModule.cc (process): call makeLabelProductions() * preModule.hh (class PreModule): added struct SymbolInfo to maintain info for pretty printing and eventually symbol production rule generation (want to do it after signature closed so we can attempt automagic gather generation for say list ctors based on complete sort info; also we may want to deal with imported symbols) (class PreModule): added data member symbolInfo * production.cc (makeLabelProductions): added * preModule.hh (class PreModule): added LABEL and RULE_BODY to enum NonTerminal * intTable.hh (nrElements): added * preModule.cc (addRule): added * preModule.hh (class PreModule): added labels data member * parser.bison (declaration): use addRule() for rules so that we can identify any possible labels. Thu Jun 4 10:34:19 1998 Steven Eker * production.cc (makeStatementProductions): added productions for RULE_BODY, but not sure this is a good idea. * preModule.cc (fixUpIdentities): added (fixUpIdentities): parse identity starting with root determined by approriate domain connected component. (makeSymbol): must create variables! * production.cc (processOps): set opDecl.symbol in the case its a polymorphic overloading of an existing symbol Wed Jun 3 17:56:27 1998 Steven Eker * ops.cc (setFlag): take int so we can set several flags at once * production.cc (processOps): use makeSymbol() * preModule.cc (makeSymbol): added * parser.bison (attribute): call setIdentity() where needed * ops.cc (setIdentity): added * preModule.hh (class PreModule): added identity to OpDef() * Mixfix2 stable enough to start ChangeLog * parser.bison (attribute): call setFlag() where needed