Skip to content

Commit

Permalink
AST definition class implementation source file for DeleteStatement.
Browse files Browse the repository at this point in the history
  • Loading branch information
nthnn committed Dec 23, 2024
1 parent 8ebbef7 commit a00003d
Showing 1 changed file with 26 additions and 0 deletions.
26 changes: 26 additions & 0 deletions src/n8/ast/statement/DeleteStatement.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
/*
* Copyright (c) 2024 - Nathanne Isip
* This file is part of N8.
*
* N8 is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published
* by the Free Software Foundation, either version 3 of the License,
* or (at your option) any later version.
*
* N8 is distributed in the hope that it will be useful, but
* WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with N8. If not, see <https://www.gnu.org/licenses/>.
*/

#include <n8/ast/statement/DeleteStatement.hpp>

DynamicObject DeleteStatement::visit(SymbolTable& symbols) {
for(const auto& variable : this->variables)
symbols.removeSymbol(variable);

return {};
}

0 comments on commit a00003d

Please sign in to comment.