Skip to content

Commit 44ec0c9

Browse files
refactor: rename old_codegen -> codegen (#2595)
Also rename `codegen.parser_utils` to `codegen.core` Co-authored-by: El De-dog-lo <3859395+fubuloubu@users.noreply.github.com>
1 parent ef1e6e4 commit 44ec0c9

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

46 files changed

+168
-167
lines changed

tests/compiler/LLL/test_compile_lll.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
import pytest
22

3+
from vyper.codegen.lll_node import LLLnode
34
from vyper.lll import compile_lll
45
from vyper.lll.s_expressions import parse_s_exp
5-
from vyper.old_codegen.parser import LLLnode
66

77
fail_list = [
88
[-(2 ** 255) - 3],

tests/compiler/LLL/test_optimize_lll.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import pytest
22

3+
from vyper.codegen.lll_node import LLLnode
34
from vyper.lll import optimizer
4-
from vyper.old_codegen.parser import LLLnode
55

66
optimize_list = [
77
(["eq", 1, 0], ["iszero", 1]),

tests/compiler/test_sha3_32.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1+
from vyper.codegen.lll_node import LLLnode
12
from vyper.lll import compile_lll, optimizer
2-
from vyper.old_codegen.parser_utils import LLLnode
33

44

55
def test_sha3_32():

tests/conftest.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,8 @@
99
from web3.providers.eth_tester import EthereumTesterProvider
1010

1111
from vyper import compiler
12+
from vyper.codegen.lll_node import LLLnode
1213
from vyper.lll import compile_lll, optimizer
13-
from vyper.old_codegen.parser_utils import LLLnode
1414

1515
from .base_conftest import VyperContract, _get_contract, zero_gas_price_strategy
1616

tests/fixtures/memorymock.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import pytest
22

3-
from vyper.old_codegen.context import Context
4-
from vyper.old_codegen.types import BaseType
3+
from vyper.codegen.context import Context
4+
from vyper.codegen.types import BaseType
55

66

77
class ContextMock(Context):
@@ -45,5 +45,5 @@ def pytest_collection_modifyitems(items, config):
4545
@pytest.fixture
4646
def memory_mocker(monkeypatch, request):
4747
if request.param:
48-
monkeypatch.setattr("vyper.old_codegen.context.Context", ContextMock)
48+
monkeypatch.setattr("vyper.codegen.context.Context", ContextMock)
4949
ContextMock.set_mock_var_size(request.param)

tests/fuzzing/test_exponents.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
from hypothesis import example, given, settings
33
from hypothesis import strategies as st
44

5-
from vyper.old_codegen.expr import calculate_largest_base, calculate_largest_power
5+
from vyper.codegen.expr import calculate_largest_base, calculate_largest_power
66

77

88
@pytest.mark.fuzzing

tests/parser/types/test_identifier_naming.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
import pytest
22

33
from vyper.builtin_functions import BUILTIN_FUNCTIONS
4+
from vyper.codegen.expr import BUILTIN_CONSTANTS, ENVIRONMENT_VARIABLES
45
from vyper.exceptions import NamespaceCollision, StructureException, SyntaxException
5-
from vyper.old_codegen.expr import BUILTIN_CONSTANTS, ENVIRONMENT_VARIABLES
66
from vyper.semantics.namespace import RESERVED_KEYWORDS
77
from vyper.utils import FUNCTION_WHITELIST
88

tests/parser/types/test_node_types.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
from pytest import raises
22

3-
from vyper.old_codegen.types import (
3+
from vyper.codegen.types import (
44
BaseType,
55
ByteArrayType,
66
MappingType,

vyper/ast/signatures/function_signature.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,9 @@
33
from typing import Optional
44

55
from vyper import ast as vy_ast
6+
from vyper.codegen.lll_node import Encoding
7+
from vyper.codegen.types import NodeType, canonicalize_type, parse_type
68
from vyper.exceptions import StructureException
7-
from vyper.old_codegen.lll_node import Encoding
8-
from vyper.old_codegen.types import NodeType, canonicalize_type, parse_type
99
from vyper.utils import cached_property, mkalphanum
1010

1111

vyper/ast/signatures/interface.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@
66
import vyper.builtin_interfaces
77
from vyper import ast as vy_ast
88
from vyper.ast.signatures.function_signature import FunctionSignature
9+
from vyper.codegen.global_context import GlobalContext
910
from vyper.exceptions import StructureException
10-
from vyper.old_codegen.global_context import GlobalContext
1111

1212

1313
# Populate built-in interfaces.

0 commit comments

Comments
 (0)