Skip to content

Commit

Permalink
Simplify _PyInterpreterConfig_Copy().
Browse files Browse the repository at this point in the history
  • Loading branch information
ericsnowcurrently committed Sep 12, 2022
1 parent 50afb6d commit d664496
Showing 1 changed file with 1 addition and 9 deletions.
10 changes: 1 addition & 9 deletions Python/initconfig.c
Original file line number Diff line number Diff line change
Expand Up @@ -3193,15 +3193,7 @@ PyStatus
_PyInterpreterConfig_Copy(_PyInterpreterConfig *config,
const _PyInterpreterConfig *config2)
{
_PyInterpreterConfig_Clear(config);

#define COPY_ATTR(ATTR) config->ATTR = config2->ATTR

COPY_ATTR(allow_fork);
COPY_ATTR(allow_subprocess);
COPY_ATTR(allow_threading);

#undef COPY_ATTR
*config = *config2;

return _PyStatus_OK();
}

0 comments on commit d664496

Please sign in to comment.