фикс бага. не было учтено отсутствие перевода сообщений в консоли.
This commit is contained in:
4
.idea/workspace.xml
generated
4
.idea/workspace.xml
generated
@@ -7,7 +7,11 @@
|
|||||||
</component>
|
</component>
|
||||||
<component name="ChangeListManager">
|
<component name="ChangeListManager">
|
||||||
<list default="true" id="e42177c3-2328-4b27-8a01-35779b2beb99" name="Default Changelist" comment="">
|
<list default="true" id="e42177c3-2328-4b27-8a01-35779b2beb99" name="Default Changelist" comment="">
|
||||||
|
<change beforePath="$PROJECT_DIR$/.idea/workspace.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/workspace.xml" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/src/Common/Global.java" beforeDir="false" afterPath="$PROJECT_DIR$/src/Common/Global.java" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/src/ProjectData/Messages/Message.java" beforeDir="false" afterPath="$PROJECT_DIR$/src/ProjectData/Messages/Message.java" afterDir="false" />
|
||||||
<change beforePath="$PROJECT_DIR$/src/SapforTestingSystem/PerformSapforTask.java" beforeDir="false" afterPath="$PROJECT_DIR$/src/SapforTestingSystem/PerformSapforTask.java" afterDir="false" />
|
<change beforePath="$PROJECT_DIR$/src/SapforTestingSystem/PerformSapforTask.java" beforeDir="false" afterPath="$PROJECT_DIR$/src/SapforTestingSystem/PerformSapforTask.java" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/src/SapforTestingSystem/SapforTestingPlaner/SapforTestingPlanner.java" beforeDir="false" afterPath="$PROJECT_DIR$/src/SapforTestingSystem/SapforTestingPlaner/SapforTestingPlanner.java" afterDir="false" />
|
||||||
</list>
|
</list>
|
||||||
<option name="SHOW_DIALOG" value="false" />
|
<option name="SHOW_DIALOG" value="false" />
|
||||||
<option name="HIGHLIGHT_CONFLICTS" value="true" />
|
<option name="HIGHLIGHT_CONFLICTS" value="true" />
|
||||||
|
|||||||
@@ -224,6 +224,7 @@ public class Global {
|
|||||||
}
|
}
|
||||||
return (bad_state == 0);
|
return (bad_state == 0);
|
||||||
}
|
}
|
||||||
|
//возможно заменить settings на properties
|
||||||
public static DBSetting getSetting(SettingName settingName) throws Exception {
|
public static DBSetting getSetting(SettingName settingName) throws Exception {
|
||||||
switch (Current.mode) {
|
switch (Current.mode) {
|
||||||
case Normal:
|
case Normal:
|
||||||
|
|||||||
@@ -24,11 +24,12 @@ public class Message extends FileObject {
|
|||||||
file = file_in;
|
file = file_in;
|
||||||
line = line_in;
|
line = line_in;
|
||||||
setGroup(group_in);
|
setGroup(group_in);
|
||||||
value = ((group == parser_group) ||
|
if ((group == parser_group) || (Current.mode != Current.Mode.Normal)) {
|
||||||
!Global.getSetting(SettingName.TRANSLATE_MESSAGES).toBoolean() ?
|
value = value_in;
|
||||||
value_in : decodeRussianMessage(value_in));
|
} else {
|
||||||
|
value = !Global.getSetting(SettingName.TRANSLATE_MESSAGES).toBoolean() ? value_in : decodeRussianMessage(value_in);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// last code - 183
|
// last code - 183
|
||||||
private static String decodeRussianMessage(String coded) throws Exception {
|
private static String decodeRussianMessage(String coded) throws Exception {
|
||||||
if (codedMessages == null) {
|
if (codedMessages == null) {
|
||||||
@@ -267,7 +268,6 @@ public class Message extends FileObject {
|
|||||||
//2018
|
//2018
|
||||||
codedMessages.put("R191", "Приватная переменная '%s' была удалена");
|
codedMessages.put("R191", "Приватная переменная '%s' была удалена");
|
||||||
codedMessages.put("R201", "Приватная переменная '%s' была частично удалена");
|
codedMessages.put("R201", "Приватная переменная '%s' была частично удалена");
|
||||||
|
|
||||||
//2019
|
//2019
|
||||||
codedMessages.put("R192", "Нельзя удалить приватную переменную '%s' - она не имеет фиксированных измерений");
|
codedMessages.put("R192", "Нельзя удалить приватную переменную '%s' - она не имеет фиксированных измерений");
|
||||||
//2020
|
//2020
|
||||||
@@ -281,7 +281,6 @@ public class Message extends FileObject {
|
|||||||
codedMessages.put("R199", "Зависимость по скаляру с типом lastprivate препятствует распараллеливанию данного цикла");
|
codedMessages.put("R199", "Зависимость по скаляру с типом lastprivate препятствует распараллеливанию данного цикла");
|
||||||
codedMessages.put("R200", "Добавлена lastprivate переменная '%s' к циклу на строке %d");
|
codedMessages.put("R200", "Добавлена lastprivate переменная '%s' к циклу на строке %d");
|
||||||
//3002
|
//3002
|
||||||
|
|
||||||
//3001
|
//3001
|
||||||
codedMessages.put("R108", "Добавлена across-зависимость к массиву '%s' в цикле.");
|
codedMessages.put("R108", "Добавлена across-зависимость к массиву '%s' в цикле.");
|
||||||
//3002
|
//3002
|
||||||
|
|||||||
@@ -167,7 +167,7 @@ public class PerformSapforTask extends Pass_2021<SapforTask> {
|
|||||||
res.line = Constants.Nan;
|
res.line = Constants.Nan;
|
||||||
res.value = "";
|
res.value = "";
|
||||||
String line = line_in.substring(9);
|
String line = line_in.substring(9);
|
||||||
System.out.println(line);
|
//System.out.println(line);
|
||||||
int i = 0;
|
int i = 0;
|
||||||
int s = 0;
|
int s = 0;
|
||||||
String lexeme = "";
|
String lexeme = "";
|
||||||
@@ -316,7 +316,7 @@ public class PerformSapforTask extends Pass_2021<SapforTask> {
|
|||||||
if (isTransformation && !messages.isEmpty()) {
|
if (isTransformation && !messages.isEmpty()) {
|
||||||
project.Open();
|
project.Open();
|
||||||
project.db.BeginTransaction();
|
project.db.BeginTransaction();
|
||||||
// System.out.println("messages size=" + messages.size());
|
System.out.println("messages size=" + messages.size());
|
||||||
for (MessageError m : messages) {
|
for (MessageError m : messages) {
|
||||||
if (project.db.files.containsKey(m.file)) {
|
if (project.db.files.containsKey(m.file)) {
|
||||||
DBProjectFile file = project.db.files.Data.get(m.file);
|
DBProjectFile file = project.db.files.Data.get(m.file);
|
||||||
|
|||||||
@@ -59,7 +59,7 @@ public class SapforTestingPlanner extends ThreadsPlanner {
|
|||||||
Utils.jsonToFile(results_json, new File(Global.Home, "results"));
|
Utils.jsonToFile(results_json, new File(Global.Home, "results"));
|
||||||
// System.out.println("Очистка служебных файлов");
|
// System.out.println("Очистка служебных файлов");
|
||||||
//тут же и строить версии.
|
//тут же и строить версии.
|
||||||
// Utils.deleteFilesByExtensions(new File(Global.Home),"proj","dep", "bat");
|
Utils.deleteFilesByExtensions(new File(Global.Home),"proj","dep", "bat","sh"); //Потом txt тоже добавить.
|
||||||
FileUtils.writeStringToFile(new File(Constants.DONE), "");
|
FileUtils.writeStringToFile(new File(Constants.DONE), "");
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
Global.Log.PrintException(e);
|
Global.Log.PrintException(e);
|
||||||
|
|||||||
Reference in New Issue
Block a user