summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: dd188cb)
raw | patch | inline | side by side (parent: dd188cb)
author | DeaDDooMER <deaddoomer@deadsoftware.ru> | |
Wed, 27 Sep 2017 18:03:22 +0000 (21:03 +0300) | ||
committer | DeaDDooMER <deaddoomer@deadsoftware.ru> | |
Wed, 27 Sep 2017 18:03:22 +0000 (21:03 +0300) |
Test.obn | patch | blob | history | |
src/backends/jvm/generator-jvm-basic.c | patch | blob | history | |
tests/Test29.obn | patch | blob | history |
diff --git a/Test.obn b/Test.obn
index da60894a8f758fa1ea09b7ef7f8195caa7367b55..22a2a55a2296d4cb933c58e7bf882acf1207e69e 100644 (file)
--- a/Test.obn
+++ b/Test.obn
MODULE Test;
-PROCEDURE A;
+PROCEDURE A(a : INTEGER);
+ VAR
+ x : INTEGER;
END A;
-PROCEDURE B;
- PROCEDURE A;
+PROCEDURE B(b : SHORTINT);
+ PROCEDURE A(c : LONGINT);
+ VAR
+ y : ARRAY 3 OF INTEGER;
END A;
END B;
index 033b84227d1eebfb4bbda213e94e19e889229f78..2088559c7e7089b6609e4857179125f70cda025e 100644 (file)
{
case OBERON_CLASS_VAR:
return new_string("%s/%s", x -> module -> name, jvm_get_name(x));
+ break;
case OBERON_CLASS_PROC:
return new_string("%s/%s", x -> module -> name, jvm_get_name(x));
+ break;
case OBERON_CLASS_FIELD:
parent = jvm_get_class_full_name(x -> parent_type);
return new_string("%s/%s", parent, jvm_get_name(x));
+ break;
case OBERON_CLASS_MODULE:
return new_string(x -> module -> name);
+ break;
default:
gen_error("jvm_get_field_full_name: wat");
break;
switch(x -> class)
{
case OBERON_CLASS_VAR:
- case OBERON_CLASS_PROC:
return new_string("%s$%s", x -> module -> name, x -> name);
+ break;
+ case OBERON_CLASS_PROC:
+ return new_string("%s$%s", x -> module -> name, jvm_get_name(x));
+ break;
case OBERON_CLASS_FIELD:;
char * rec_name = jvm_get_class_full_name(x -> parent_type);
return new_string("%s$%s", rec_name, x -> name);
+ break;
case OBERON_CLASS_MODULE:
return new_string(x -> module -> name);
+ break;
default:
gen_error("jvm_get_field_full_name: wat");
break;
diff --git a/tests/Test29.obn b/tests/Test29.obn
index ab7e493a971b4bbf43cd7d4527a58fe94a89b601..1df5da2fc7652d110c487223b4bcfcfb991beb7e 100644 (file)
--- a/tests/Test29.obn
+++ b/tests/Test29.obn
MODULE Test29;
-PROCEDURE A;
+PROCEDURE A(a : INTEGER);
+ VAR
+ x : INTEGER;
END A;
-PROCEDURE B;
- PROCEDURE A;
+PROCEDURE B(b : SHORTINT);
+ PROCEDURE A(c : LONGINT);
+ VAR
+ y : ARRAY 3 OF INTEGER;
END A;
END B;