source: dev/BasicCompiler_Common/include/Smoothie.h@ 92

Last change on this file since 92 was 92, checked in by dai_9181, 17 years ago

列挙型クラスの自動生成コードを修正した(派生クラスでのToStringメソッドを廃止し、サイズを軽減した)。

File size: 951 bytes
Line 
1#pragma once
2
3#include "Source.h"
4#include "../TypeDef.h"
5
6class Smoothie{
7public:
8
9 class Logger{
10 static string log;
11 public:
12 static void Initialize(){
13#ifdef _DEBUG
14 log = "";
15
16 ofstream ofs( ( (string)BasicSystemDir + "compile.log" ).c_str(), ios_base::trunc );
17 ofs.close();
18#endif
19 }
20 static void Put( const string &text ){
21#ifdef _DEBUG
22 log += text + "\r\n";
23
24 {
25 ofstream ofs( ( (string)BasicSystemDir + "compile.log" ).c_str(), ios_base::app );
26 ofs << text << endl;
27 ofs.close();
28 }
29#endif
30 }
31 static void PutFile( const string &fileName, const string &buffer ){
32 ofstream ofs( ( (string)BasicSystemDir + fileName ).c_str() );
33 ofs << buffer << endl;
34 ofs.close();
35 }
36 };
37
38 class Lexical{
39 public:
40 static BasicSource source;
41 };
42
43 class Meta{
44 public:
45 // TypeDef
46 static TypeDefCollection typeDefs;
47 static vector<ProcPointer *> procPointers;
48 };
49};
Note: See TracBrowser for help on using the repository browser.