src: cleanup importations
authorJean Privat <jean@pryen.org>
Wed, 3 Sep 2014 14:19:04 +0000 (10:19 -0400)
committerJean Privat <jean@pryen.org>
Wed, 3 Sep 2014 14:19:04 +0000 (10:19 -0400)
Signed-off-by: Jean Privat <jean@pryen.org>

28 files changed:
src/android_annotations.nit
src/annotation.nit
src/astprinter.nit
src/astvalidation.nit
src/auto_super_init.nit
src/cached.nit
src/check_annotation.nit
src/common_ffi/common_ffi.nit
src/common_ffi/pkgconfig.nit
src/debugger.nit
src/div_by_zero.nit
src/flow.nit
src/literal.nit
src/local_var_init.nit
src/markdown.nit
src/model/model.nit
src/modelbuilder.nit
src/modelize_property.nit
src/naive_interpreter.nit
src/platform.nit
src/rapid_type_analysis.nit
src/scope.nit
src/serialization_phase.nit
src/simple_misc_analysis.nit
src/testing/testing_base.nit
src/testing/testing_suite.nit
src/transform.nit
src/typing.nit

index b3ffcee..6ef4e04 100644 (file)
@@ -18,8 +18,7 @@
 # by calling `ModelBuilder::android_project_for`.
 module android_annotations
 
-import parser_util
-import modelbuilder
+private import parser_util
 import modelize
 import literal
 import semantize
index 8d9ca25..6641280 100644 (file)
@@ -15,9 +15,8 @@
 # Management and utilities on annotations
 module annotation
 
-import parser
 import modelbuilder
-import literal
+private import literal
 import model::mmodule_data
 
 redef class Prod
index a1fd48e..e0aceee 100644 (file)
 # print AST in an human form
 module astprinter
 
-import phase
 import semantize
 intrude import parser
-import literal
+private import literal
 
 private class ASTPrinterVisitor
        super Visitor
index 913ee21..578f931 100644 (file)
@@ -15,7 +15,6 @@
 # Check the consitency of AST
 module astvalidation
 
-private import typing
 intrude import parser
 import astbuilder
 
index 8891df3..19d60f5 100644 (file)
@@ -19,8 +19,7 @@
 module auto_super_init
 
 import typing
-import modelbuilder
-import phase
+private import annotation
 
 redef class ToolContext
        var auto_super_init_phase: Phase = new AutoSuperInitPhase(self, [typing_phase])
index 67d7b98..830ff66 100644 (file)
@@ -18,8 +18,8 @@
 # complex annotation that modify both the model and the AST of a Nit program
 module cached
 
-import parser_util
 import modelize
+private import parser_util
 import simple_misc_analysis
 private import annotation
 
index f91dc55..367ba4d 100644 (file)
@@ -19,7 +19,7 @@
 module check_annotation
 
 import phase
-import annotation
+private import annotation
 
 redef class ToolContext
        var check_annotation_phase: Phase = new CheckAnnotationPhase(self, null)
index 302c472..cb9c244 100644 (file)
@@ -19,7 +19,6 @@
 # to wrap foreign code in Nit methods.
 module common_ffi
 
-import parser
 import modelbuilder
 
 import nitni
index 5306b97..aa9add3 100644 (file)
@@ -20,6 +20,7 @@ module pkgconfig
 
 import c
 private import annotation
+private import literal
 
 redef class ToolContext
        var pkgconfig_phase: Phase = new PkgconfigPhase(self, [literal_phase])
index 24df936..0f211e6 100644 (file)
@@ -23,6 +23,7 @@ import nitx
 intrude import local_var_init
 intrude import scope
 intrude import toolcontext
+private import parser_util
 
 redef class Model
        # Cleans the model to remove a module and what it defines when semantic analysis fails on injected code
index 318b33e..5833009 100644 (file)
@@ -16,7 +16,6 @@
 # This module is only an example of how to implements a simple phase in the nit tools
 module div_by_zero
 
-import phase
 import literal # Because we need the real value of literal in the AST
 import semantize # Because we need the static type of receivers
 
index bbee8bb..4717d9b 100644 (file)
 # Intraprocedural static flow.
 module flow
 
-import parser
-import toolcontext
 import scope
-import phase
 
 redef class ToolContext
        var flow_phase: Phase = new FlowPhase(self, [scope_phase])
index 0395299..ef4851b 100644 (file)
@@ -17,8 +17,6 @@
 # Parsing of literal values in the abstract syntax tree.
 module literal
 
-import parser
-import toolcontext
 import phase
 
 redef class ToolContext
index 4ed1ff8..4b9a4ab 100644 (file)
@@ -18,9 +18,7 @@
 # Require that the scope and the flow analaysis are already performed
 module local_var_init
 
-import scope
 import flow
-import phase
 
 redef class ToolContext
        var local_var_init_phase: Phase = new LocalVarInitPhase(self, [flow_phase])
index 90cb227..01a054c 100644 (file)
@@ -18,6 +18,7 @@ module markdown
 private import parser
 import html
 private import highlight
+private import parser_util
 
 # The class that does the convertion from a `ADoc` to HTML
 private class Doc2Mdwn
index f3c3164..d4d2c1c 100644 (file)
@@ -25,8 +25,6 @@
 # FIXME: better handling of the types
 module model
 
-import poset
-import location
 import mmodule
 import mdoc
 import ordered_tree
index cebbe1b..eac98df 100644 (file)
 # FIXME add missing error checks
 module modelbuilder
 
-import parser
 import model
-import poset
-import opts
-import toolcontext
 import phase
 
 private import more_collections
index 146125b..57e847b 100644 (file)
@@ -18,7 +18,7 @@
 module modelize_property
 
 import modelize_class
-import annotation
+private import annotation
 
 redef class ToolContext
        var modelize_property_phase: Phase = new ModelizePropertyPhase(self, [modelize_class_phase])
index c741f04..291f222 100644 (file)
 module naive_interpreter
 
 import literal
-import typing
-import auto_super_init
-import frontend
 import common_ffi
+import semantize
 private import parser::tables
 
 redef class ToolContext
index 99d67a0..80aab8b 100644 (file)
@@ -16,9 +16,8 @@
 # to the target platform. Also detects conflicts between targetted platforms.
 module platform
 
-import parser_util
-import modelbuilder
 import modelize
+private import parser_util
 private import annotation
 
 redef class ToolContext
index 418bc15..ea0dcaf 100644 (file)
 # It is quite efficient but the type set is global and pollutes each call site.
 module rapid_type_analysis
 
-import model
-import modelbuilder
 import semantize
 
-import csv # for live_types_to_csv
-import ordered_tree # for live_methods_to_tree
+private import csv # for live_types_to_csv
+private import ordered_tree # for live_methods_to_tree
 
 private import more_collections
 
index 2d2c00a..83c5fe4 100644 (file)
@@ -17,8 +17,6 @@
 # Identification and scping of local variables and labels.
 module scope
 
-import parser
-import toolcontext
 import phase
 
 redef class ToolContext
index 1847298..25574e7 100644 (file)
@@ -19,9 +19,9 @@
 # Phase generating methods to serialize Nit objects to different formats
 module serialization_phase
 
-import phase
-import parser_util
+private import parser_util
 import modelize
+private import annotation
 
 redef class ToolContext
        var serialization_phase_pre_model: Phase = new SerializationPhasePreModel(self, null)
index 35fa66c..26d6710 100644 (file)
@@ -21,8 +21,6 @@
 #  * use of "while true" instead of "loop"
 module simple_misc_analysis
 
-import toolcontext
-import parser
 import phase
 
 redef class ToolContext
index ef9e7fe..62cfb08 100644 (file)
@@ -15,8 +15,8 @@
 # Base options for testing tools.
 module testing_base
 
-import parser_util
 import modelize
+private import parser_util
 
 redef class ToolContext
        # opt --full
index acf5650..30cbed5 100644 (file)
@@ -17,6 +17,7 @@ module testing_suite
 
 import testing_base
 import html
+private import annotation
 
 redef class ToolContext
        # -- target-file
index 6829d75..6a209c3 100644 (file)
@@ -17,8 +17,8 @@
 module transform
 
 import astbuilder
-import auto_super_init
 import astvalidation
+import semantize
 
 redef class ToolContext
        var transform_phase: Phase = new TransformPhase(self, [typing_phase, auto_super_init_phase])
index 3dd9024..462fe04 100644 (file)
@@ -18,8 +18,6 @@
 # By OO-services we mean message sending, attribute access, instantiation, etc.
 module typing
 
-import flow
-import phase
 import modelize
 import local_var_init