Fix indentation in GPL headers
[hcoop/domtool2.git] / src / env.sig
index 795129a..d239e14 100644 (file)
  * You should have received a copy of the GNU General Public License
  * along with this program; if not, write to the Free Software
  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
-*)
+ *)
 
 (* Domtool type-checking and reduction environments *)
 
 signature ENV = sig
 
-    val registerType : string * (Ast.exp -> bool) -> unit
-    val typeRule : string -> (Ast.exp -> bool) option
+    type typeRule = Ast.exp -> bool
+    val registerType : string * typeRule -> unit
+    val typeRule : string -> typeRule option
+
+    type env_vars = Ast.exp Ast.StringMap.map
+    type action = env_vars * Ast.exp list -> env_vars
+    val registerAction : string * action -> unit
+    val action : string -> action option
+
+    val registerContainer : string * action * (unit -> unit) -> unit
+    val container : string -> (action * (unit -> unit)) option
+
+    val badArgs : string -> 'a
 
     type env
     val empty : env