feat: 针对C的代码生成 (#50)
Co-authored-by: Lan_G <2911328695@qq.com> Reviewed-on: PostGuard/Canon#50
This commit is contained in:
@@ -1,4 +1,5 @@
|
||||
using System.Text;
|
||||
using Canon.Core.SemanticParser;
|
||||
|
||||
namespace Canon.Core.CodeGenerators;
|
||||
|
||||
@@ -9,6 +10,11 @@ public class CCodeBuilder
|
||||
{
|
||||
private readonly StringBuilder _builder = new();
|
||||
|
||||
/// <summary>
|
||||
/// 符号表
|
||||
/// </summary>
|
||||
public SymbolTable SymbolTable { get; } = new();
|
||||
|
||||
public void AddString(string code)
|
||||
{
|
||||
_builder.Append(code);
|
||||
|
Reference in New Issue
Block a user