浏览代码

Minor tweak

Yentl Van Tendeloo 9 年之前
父节点
当前提交
7d5c0f21b7
共有 2 个文件被更改,包括 4 次插入6 次删除
  1. 1 1
      bootstrap/bootstrap.py
  2. 3 5
      bootstrap/constructors.alc

+ 1 - 1
bootstrap/bootstrap.py

@@ -159,9 +159,9 @@ include "io.alh"
 include "primitives.alc"
 include "compilation_manager.alc"
 include "constructors.alc"
-include "conformance_scd.alc"
 include "object_operations.alc"
 include "library.alc"
+include "conformance_scd.alc"
 include "modelling.alc"
 
 Void function __main():

+ 3 - 5
bootstrap/constructors.alc

@@ -10,13 +10,13 @@ Action function construct_top():
 	String command
 	command = input()
 	if (command == "global"):
-		return construct_top_global()
+		return construct_global()
 	elif (command == "funcdef"):
 		return construct_top_funcdef()
 	else:
 		log("ERROR: did not understand command " + cast_e2s(command))
 
-Action function construct_top_global():
+Action function construct_global():
 	Action this_element
 	String declared_element
 	String op
@@ -269,19 +269,17 @@ Action function construct_funcdef():
 	Action assign
 	Action resolve
 	Action constant
-	Element formal
 	Action func
 	Element params
 
 	assign = create_value(!assign)
 	resolve = create_value(!resolve)
 	constant = create_value(!constant)
-	formal = input()
 	func = create_node()
 	params = create_node()
 	dict_add(assign, "var", resolve)
 	dict_add(assign, "value", constant)
-	dict_add(resolve, "var", formal)
+	dict_add(resolve, "var", input())
 	dict_add(constant, "node", func)
 	dict_add(func, "params", params)