/* * Copyright 1993, 1995 Christopher Seiwald. * * This file is part of Jam - see jam.c for Copyright information. */ /* * command.c - maintain lists of commands */ #include "Command.hpp" #include "Variable.hpp" namespace Jam { /* * cmd_new() - return a new CMD or 0 if too many args */ Command* Command::CreateInstance( RULE *rule, List *targets, List *sources, List *shell ) { Command* pInstance = new Command; pInstance->rule = rule; pInstance->shell = shell; pInstance->next = 0; lol_init( &pInstance->args ); lol_add( &pInstance->args, targets ); lol_add( &pInstance->args, sources ); /* Bail if the result won't fit in MAXLINE */ /* We don't free targets/sources/shell if bailing. */ if( var_string( rule->actions, pInstance->buf, MAXLINE, &pInstance->args ) < 0 ) { delete pInstance; return 0; } return pInstance; } /* * cmd_free() - free a CMD */ void Command::DeleteInstance(Command* pInstance) { lol_free( &pInstance->args ); List::list_free( pInstance->shell ); delete pInstance; } Command* Command::GetNext(void) const { return this->next; } }
# | Change | User | Description | Committed | |
---|---|---|---|---|---|
#7 | 1162 | bob_summerwill | Converted LIST into a List class, with all static methods. | ||
#6 | 1154 | bob_summerwill | Converted Command into a class. | ||
#5 | 1138 | bob_summerwill | Removed all extern "C" wrappers, so the program now has C++ linkage throughout, ready for refactoring. | ||
#4 | 1132 | bob_summerwill | All of the non-generated, non-platform-specific files are now mixed-case C++ source files. | ||
#3 | 1126 | bob_summerwill | #include dependencies between headers are now modelled explicitly, with #includes as required in header files, rather than it being a client-code responsibility. | ||
#2 | 1125 | bob_summerwill | Renamed Command.h as Command.hpp. | ||
#1 | 1116 | bob_summerwill |
command.c replaced with Command.cpp. Batch file now using Jam++ exe. Updated Jamfile, to cope with C++ flags. |
||
//guest/bob_summerwill/jam/src/command.c | |||||
#1 | 1106 | bob_summerwill | Integrated Jam from "public" to "guest/bob_summerwill". | ||
//guest/perforce_software/jam/src/command.c | |||||
#3 | 486 | Perforce staff |
Jam 2.3. See RELNOTES for a list of changes from 2.2.x. Just about every source file was touched when jam got ANSI-fied. |
||
#2 | 76 | Laura Wingerd |
Integrate command-block-too-long fix, plus minor doc updates. Jam/MR release level is now 2.2.5. (change 72, change 73, change 74, change 75) |
||
#1 | 2 | laura | Add Jam/MR 2.2 source |