Skip to content

Commit

Permalink
Merge pull request #1391 from pguyot/w49/remove-unnecessary-argv-check
Browse files Browse the repository at this point in the history
Remove unnecessary argc check

These changes are made under both the "Apache 2.0" and the "GNU Lesser General
Public License 2.1 or later" license terms (dual license).

SPDX-License-Identifier: Apache-2.0 OR LGPL-2.1-or-later
  • Loading branch information
bettio committed Dec 11, 2024
2 parents fc824ad + 549063f commit 9104247
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions src/libAtomVM/nifs.c
Original file line number Diff line number Diff line change
Expand Up @@ -3003,9 +3003,7 @@ static term nif_erlang_binary_to_term(Context *ctx, int argc, term argv[])

static term nif_erlang_term_to_binary(Context *ctx, int argc, term argv[])
{
if (argc != 1) {
RAISE_ERROR(BADARG_ATOM);
}
UNUSED(argc);
term t = argv[0];
term ret = externalterm_to_binary(ctx, t);
if (term_is_invalid_term(ret)) {
Expand Down

0 comments on commit 9104247

Please sign in to comment.