X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=src%2Ftemporary.c;h=840e5d2b4e73941b95242b5b1b65c7087dea974a;hb=9987b8c21548797582808e6cf8c2551876c3e5a1;hp=d82461d1e97626f3d04a7d68922f85e123be4134;hpb=ca1feaeed4961242699d0b7ba61def0c58515ddd;p=pspp diff --git a/src/temporary.c b/src/temporary.c index d82461d1e9..840e5d2b4e 100644 --- a/src/temporary.c +++ b/src/temporary.c @@ -14,16 +14,17 @@ You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software - Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA - 02111-1307, USA. */ + Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA + 02110-1301, USA. */ #include -#include +#include "error.h" #include #include #include "alloc.h" #include "command.h" -#include "do-ifP.h" +#include "dictionary.h" +#include "ctl-stack.h" #include "error.h" #include "hash.h" #include "lexer.h" @@ -31,20 +32,19 @@ #include "value-labels.h" #include "var.h" -#include "debug-print.h" +#include "gettext.h" +#define _(msgid) gettext (msgid) int temporary; struct dictionary *temp_dict; -int temp_trns; +size_t temp_trns; /* Parses the TEMPORARY command. */ int cmd_temporary (void) { - lex_match_id ("TEMPORARY"); - /* TEMPORARY is not allowed inside DO IF or LOOP. */ - if (ctl_stack) + if (!ctl_stack_is_empty ()) { msg (SE, _("This command is not valid inside DO IF or LOOP.")); return CMD_FAILURE; @@ -62,7 +62,6 @@ cmd_temporary (void) temporary = 1; temp_dict = dict_clone (default_dict); temp_trns = n_trns; - debug_printf (("TEMPORARY: temp_trns=%d\n", temp_trns)); return lex_end_of_command (); }