mv javap_*.nit src/
mv javap* gen/
-bin/jwrapper: src/javap_test_parser.nit $(shell ../../bin/nitls -M src/jwrapper.nit) ../../bin/nitc
+src/serial.nit: $(shell ../../bin/nitls -M src/jwrapper.nit)
+ ../../bin/nitserial -o src/serial.nit -d project src/jwrapper.nit
+
+bin/jwrapper: src/javap_test_parser.nit src/serial.nit $(shell ../../bin/nitls -M src/jwrapper.nit) ../../bin/nitc
mkdir -p bin
- ../../bin/nitc src/jwrapper.nit -o bin/jwrapper
+ ../../bin/nitc src/jwrapper.nit -o bin/jwrapper -m src/serial.nit
clean:
rm -f bin/javap_test_parser bin/jwrapper
# See the License for the specific language governing permissions and
# limitations under the License.
-# Contains the java and nit type representation used to convert java to nit code
-module model
+# Model of the parsed Java classes and their corresponding Nit types
+module model is serialize
import more_collections
import opts
import poset
+import binary::serialization
import jtype_converter
end
# Unknown types, not already wrapped and not in this pass
- var unknown_types = new HashMap[JavaType, NitType]
+ var unknown_types = new HashMap[JavaType, NitType] is noserialize
# Wrapped types, or classes analyzed in this pass
- var known_types = new HashMap[JavaType, NitType]
+ var known_types = new HashMap[JavaType, NitType] is noserialize
# Get the `NitType` corresponding to the `JavaType`
#
end
# Specialization hierarchy of `classes`
- var class_hierarchy = new POSet[JavaClass]
+ var class_hierarchy = new POSet[JavaClass] is noserialize
# Fill `class_hierarchy`
fun build_class_hierarchy
var opt_arrays = new OptionInt("Depth of the primitive array for each wrapped class (default: 1)", 1, "-a")
end
-redef class Text
+redef abstract class Text
# Get a copy of `self` where the first letter is capitalized
fun simple_capitalized: String
do