Move entry_block() into Layout.

The single entry block in a function is simply the first block in the layout.

Remove the 'entry' keyword from the textual IL, the lexer and parser.
This commit is contained in:
Jakob Stoklund Olesen
2016-07-22 10:06:51 -07:00
parent 38815dcca3
commit f116f03327
8 changed files with 29 additions and 37 deletions

View File

@@ -10,7 +10,7 @@ pub mod layout;
use ir::types::{FunctionName, Signature};
use entity_map::EntityRef;
use ir::entities::{Ebb, NO_EBB, StackSlot};
use ir::entities::StackSlot;
use ir::dfg::DataFlowGraph;
use ir::layout::Layout;
use std::fmt::{self, Debug, Display, Formatter};
@@ -24,9 +24,6 @@ pub struct Function {
/// Signature of this function.
signature: Signature,
/// The entry block.
pub entry_block: Ebb,
/// Stack slots allocated in this function.
stack_slots: Vec<StackSlotData>,
@@ -43,7 +40,6 @@ impl Function {
Function {
name: name,
signature: sig,
entry_block: NO_EBB,
stack_slots: Vec::new(),
dfg: DataFlowGraph::new(),
layout: Layout::new(),