Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 12 additions & 4 deletions JackCompiler/CompilationEngine.cs
Original file line number Diff line number Diff line change
Expand Up @@ -295,7 +295,9 @@ private void CompileStatements()
xw.WriteFullEndElement(); // end statements
}

// Compiles a 'do' statement
/// <summary>
/// Compiles a 'do' statement
/// </summary>
private void CompileDo()
{
xw.WriteStartElement("doStatement");
Expand All @@ -309,7 +311,9 @@ private void CompileDo()
xw.WriteEndElement(); // end doStatement
}

// Compiles a 'let' statement
/// <summary>
/// Compiles a 'let' statement
/// </summary>
private void CompileLet()
{
xw.WriteStartElement("letStatement");
Expand Down Expand Up @@ -356,7 +360,9 @@ private void CompileLet()
xw.WriteEndElement(); // end letStatement
}

// Compiles a 'while' statement
/// <summary>
/// Compiles a 'while' statement
/// </summary>
private void CompileWhile(int count)
{
xw.WriteStartElement("whileStatement");
Expand All @@ -375,7 +381,9 @@ private void CompileWhile(int count)
vw.WriteLabel($"WHILE_END{count}");
}

// Compiles a 'return' statement
/// <summary>
/// Compiles a 'return' statement
/// </summary>
private void CompileReturn()
{
xw.WriteStartElement("returnStatement");
Expand Down