-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtranslate_csharp.h
26 lines (23 loc) · 933 Bytes
/
translate_csharp.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
#pragma once
#include "SyntaxAnalisator.h"
class Translate_csharp : public SyntaxAnalisator
{
public:
Translate_csharp();
protected:
void transalteToCSharp(std::string from_file_RPN, std::string to_file_CSharp);
~Translate_csharp();
private:
std::string nameArrayForReturn = "", nameFunctionReturnArray = "";
std::stack<std::string> stack;
std::string reverseExpression(std::string expression);
std::string declareFunction(std::string line);
std::string declareCondition(std::string line, std::string nameCondition);
std::string declareFunctionExpression(std::string line,int countArg);
std::string strArray(std::string line);
std::string correctCycleFor(std::string for_line);
std::string replaceCodeToName(std::string line, char const& name);
std::string replaceCodeToName(std::string line);
std::string replaceMalloc(std::string const& line);
void replaceTypeToTypeArrayFunction(std::string& block_function);
};